Skip to navigation

Answer an end-user approval gate

Session-authenticated approval for browser client-token sessions. Answers a paused approval whose gate the agent authored with tools.approval.approver: 'end-user', then streams the continued run over Server-Sent Events in the same shape as /v1/client/resume. The decision is bound to the session that started the turn, single-use, and bound to the exact reviewed tool parameters; visitors cannot create persistent “always allow” grants. A gate with the default owner approver is refused with 403 APPROVAL_APPROVER_NOT_END_USER; answer those with POST /v1/dispatch/approve. Does not count against execution limits.

Request

This endpoint expects an object.
approvalIdstringRequired>=1 character

The approvalId from the approval_start event this decision answers.

decisionenumRequired
Allowed values:
executionIdstringRequired>=1 character
sessionIdstringRequired>=1 character
streamResponsefalseRequired
assistantMessageIdstringOptional<=128 characters

Id for the assistant message this resumed leg produces, so a re-send deduplicates by id. Optional; same contract as /v1/client/resume.

reasonstringOptional<=2000 characters
The visitor's own note on the decision, recorded with it. Optional.

Response

eventslist of objects
executionIdstring
statusenum
Allowed values:
successboolean
agentTargetResolutionenumOptional

How the run selected its definition: alias or version for a request that named a selector, legacy-live-row for a run that read the mutable agent row. Matches GET /v1/executions/{executionId}/status.

Allowed values:
agentVersionIdstringOptional

The agent version recorded for the run. When agentTargetResolution is legacy-live-row, this is the version the agent row pointed at, and the run read the mutable row rather than that version. Absent when neither exists.

aliasstringOptional

The release alias (for example live) the version was resolved through, when one was.

blockReasonstringOptional
codestringOptional
errorstringOptional
pausedReasonobjectOptional
upgradeUrlstringOptional

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
409
Conflict Error
500
Internal Server Error
503
Service Unavailable Error