Deny a waiting request
const url = 'https://api.global.stillbox.example/v1/approvals/example/deny';const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: '{"note":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.global.stillbox.example/v1/approvals/example/deny \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "note": "example" }'The note, if any, is passed to the agent as the reason.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Request Body
Section titled “Request Body”object
Example generated
{ "note": "example"}Responses
Section titled “Responses”The decided request
object
permission: unattended mode is off and the agent wants to change something. rule: an approval rule matched.
request: a program in the sandbox asked. policy: a policy marked @approval matched (its name is in rule_name).
The person the agent works for can’t approve it.
What the agent wants to do, e.g. “Run: git push origin main”.
The agent’s tool, e.g. Bash, when an agent asked.
The full command
The person the agent works for.
Whether you may approve or deny it.
Example
{ "kind": "permission", "state": "pending"}The API key is missing or invalid
object
Example
{ "code": "not_found"}Only an owner can do this (owner_only), or the invitation is for another address (not_invited)
object
Example
{ "code": "not_found"}No such sandbox in your organization (or no such file)
object
Example
{ "code": "not_found"}The change would leave the organization without an owner (last_owner), its seats are full (member_limit), or
the person is already a member (already_member)
object
Example
{ "code": "not_found"}