Approvals

Approve or deny a pending request

Console sessions only. A credential must not be able to approve its own writes — that would make the gate a formality the agent walks through by itself.

POST
/approvals/{approvalId}/decision

Console sessions only. A credential must not be able to approve its own writes — that would make the gate a formality the agent walks through by itself.

Authorization

ApiKeyAuth
AGENTBOX-API-KEY<token>

In: header

Path Parameters

approvalId*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

curl -X POST "https://approvals/string/decision" \  -H "Content-Type: application/json" \  -d '{    "decision": "approve"  }'
{  "id": "string",  "principal": {    "team": "string",    "user": "string",    "keyId": "string"  },  "sessionId": "string",  "operation": "string",  "onceOnly": true,  "method": "string",  "path": "string",  "summary": "string",  "createdAt": "2019-08-24T14:15:22Z",  "expiresAt": "2019-08-24T14:15:22Z",  "status": "pending",  "scope": "once",  "decidedBy": "string",  "decidedAt": "2019-08-24T14:15:22Z"}
{  "error": "string",  "errorCode": "APPROVAL_REQUIRED",  "detail": null}
{  "error": "string",  "errorCode": "APPROVAL_REQUIRED",  "detail": null}
{  "error": "string",  "errorCode": "APPROVAL_REQUIRED",  "detail": null}