mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-26 18:31:34 +01:00
test: cover delegation API contracts
Paperclip-Task: PAP-17797
This commit is contained in:
1 parent
f5e1ecc059
commit
3ae042330e
2 files changed
+20
No files matched your search
@@ -198,6 +198,7 @@ import {
|
||||
createToolApplicationSchema,
|
||||
updateToolApplicationSchema,
|
||||
createToolConnectionSchema,
|
||||
createConnectionGrantDelegationSchema,
|
||||
connectionTokenRequestSchema,
|
||||
startConnectionAuthorizationSchema,
|
||||
createToolStdioCommandTemplateSchema,
|
||||
@@ -877,6 +878,8 @@ const BOARD_ONLY_OPERATIONS = new Set([
|
||||
"GET /api/tool-connections/{connectionId}",
|
||||
"GET /api/tool-connections/{connectionId}/grants",
|
||||
"POST /api/tool-connections/{connectionId}/grants/installations",
|
||||
"POST /api/tool-connections/{connectionId}/grants/{grantId}/delegations",
|
||||
"DELETE /api/tool-connections/{connectionId}/grants/{grantId}/delegations/{delegationId}",
|
||||
"DELETE /api/tool-connections/{connectionId}/grants/{grantId}",
|
||||
"GET /api/tool-connections/{connectionId}/usage",
|
||||
"PATCH /api/tool-connections/{connectionId}",
|
||||
@@ -7214,6 +7217,22 @@ registerCurrentRoute({
|
||||
responses: { 201: r.ok(), 400: r.badRequest, 401: r.unauthorized, 403: r.forbidden, 404: r.notFound },
|
||||
});
|
||||
|
||||
registerCurrentRoute({
|
||||
method: "post",
|
||||
path: "/api/tool-connections/{connectionId}/grants/{grantId}/delegations",
|
||||
tags: ["tool-access"],
|
||||
summary: "Delegate a personal tool connection grant to an agent",
|
||||
body: createConnectionGrantDelegationSchema,
|
||||
responses: { 201: r.ok(), 400: r.badRequest, 401: r.unauthorized, 403: r.forbidden, 404: r.notFound },
|
||||
});
|
||||
|
||||
registerCurrentRoute({
|
||||
method: "delete",
|
||||
path: "/api/tool-connections/{connectionId}/grants/{grantId}/delegations/{delegationId}",
|
||||
tags: ["tool-access"],
|
||||
summary: "Revoke a personal tool connection grant delegation",
|
||||
});
|
||||
|
||||
registerCurrentRoute({
|
||||
method: "delete",
|
||||
path: "/api/tool-connections/{connectionId}/grants/{grantId}",
|
||||
|
||||
@@ -28,6 +28,7 @@ describe("attention feed resolver audience", () => {
|
||||
effectiveResolverPolicySource: "requested",
|
||||
resolverPolicyProvenance: "inherited",
|
||||
addresseeAgentId: null,
|
||||
addresseeUserId: null,
|
||||
addresseeName: null,
|
||||
createdByAgentId: "agent-watchdog",
|
||||
createdByAgentName: "Watchdog",
|
||||
|
||||
Reference in new issue
Block a user