Approve a delivery
curl --request POST \ --url https://example.com/api/v1/delegations/example/approve \ --header 'Authorization: Bearer <token>' \ --header 'Content-Type: application/json' \ --data '{ "expectedRevision": 1, "hours": 1, "orderActivityTypeId": "example", "orderId": "example" }'Approves a delivery in review and records the equivalent hours as a time entry under the agent, approved by the caller. The order must be linked to the project the ticket was delegated from. Pass expectedRevision (the revision of the delivery that was reviewed) to be refused with 409 when the delegation moved past it. Only the accountable member or a manager of the governing project can approve.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Resource identifier (CUID2).
Resource identifier (CUID2).
Request Body
Section titled “Request Body”object
Revision of the delivery that was reviewed; the approval is refused with 409 when the delegation moved past it
Equivalent hours of work to record under the agent
Activity type of that order, required when the workspace asks for one
Order of the governing project that receives the hours
Example generated
{ "expectedRevision": 1, "hours": 1, "orderActivityTypeId": "example", "orderId": "example"}Responses
Section titled “Responses”The approved delegation and the time entry id.
object
The approved delegation and the time entry recorded under the agent.
object
A ticket handed to an AI agent, with the human accountable for it.
object
True when the agent delivers a pull request (a code agent), false when it delivers a report
Example
{ "data": { "delegation": { "state": "Delegated" } }}Validation error. Parse failures include field paths and expectations.
Validation error with safe field paths and expected values; submitted values are never returned.
object
object
Stable machine-readable error code.
object
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Unauthorized.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Forbidden.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Not found.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Conflict.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Invalid input.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Rate limit exceeded. Wait for Retry-After before retrying.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Headers
Section titled “Headers”Maximum requests in the current quota window.
Quota policy in requests and window seconds, for example 60;w=60.
Requests left in this quota window (zero when blocked).
Seconds until the current quota window resets, when available from the rate-limit store.
Seconds until another request may be attempted.
Chelsea is operated by Arepa Labs LLC