Operation Approvals
3 operations.
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/v1/operation-approvals | List operation approvals |
| GET | /api/v1/operation-approvals/{approvalId} | Get an operation approval |
| PATCH | /api/v1/operation-approvals/{approvalId} | Decide an operation approval |
List operation approvals
GET /api/v1/operation-approvals
List operation approvals awaiting or recording a decision.
Parameters
query
| Name | Type | Required | Description |
|---|---|---|---|
projectId | string | optional | Filters results to the specified Project. Applies to List operation approvals. |
environmentId | string | optional | Selects the active Project environment coordinate. Applies to List operation approvals. |
agentId | string | optional | Selects the Project Agent by its stable identifier. Applies to List operation approvals. |
status | "pending" | "approved" | "rejected" | "consumed" | optional | Filters results to the requested status. Applies to List operation approvals. |
limit | integer | optional | Sets the maximum number of resources returned in this page. Applies to List operation approvals. |
cursor | string | optional | Opaque cursor returned by the previous page; omit it to read the first page. Applies to List operation approvals. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Response for status 200 | application/json — object — operationApprovals: array<object> (required); pagination: object (required) |
400 | The request is malformed or cannot be processed. | application/json — PublicApiError — error: object (required) |
401 | Authentication failed. The Authorization header is missing, or the credential is invalid or expired. | application/json — PublicApiError — error: object (required) |
403 | Access denied. The authenticated user does not have permission to perform this action. | application/json — PublicApiError — error: object (required) |
404 | Resource not found. | application/json — PublicApiError — error: object (required) |
409 | Request conflicts with current state of the resource, including safe deployment conflict classifications. | application/json — PublicApiError — error: object (required) |
422 | Request validation failed. Check the request body, query parameters, or path parameters. | application/json — PublicApiError — error: object (required) |
429 | Too many requests. The code foreign_resource_rate_limited means the caller made too many requests for Projects outside its reach: correct the Project id instead of retrying. | application/json — PublicApiError — error: object (required) |
500 | The server could not complete the request. | application/json — PublicApiError — error: object (required) |
503 | Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff. | application/json — PublicApiError — error: object (required) |
Get an operation approval
GET /api/v1/operation-approvals/{approvalId}
Get one operation approval within the caller's Project, Environment and Agent permissions.
Parameters
path
| Name | Type | Required | Description |
|---|---|---|---|
approvalId | string | required | Identifies the operation approval being decided. Applies to Get an operation approval. |
Responses
| Status | Description | Body |
|---|---|---|
200 | Response for status 200 | application/json — object — type: "operationApproval" (required); id: string (required); invocationId: string (required); agentRunId: string | null (required); organizationId: string (required); projectId: string (required); environmentId: string (required); agentId: string (required); definitionId: string (required); definitionRevisionId: string; operationName: string (required); renderedSummary: string | null; requestedByUserId: string | null (required); status: "pending" | "approved" | "rejected" | "consumed" (required); decidedByUserId: string | null (required); decidedAt: string | null (required); consumedAt: string | null (required); requestedAt: string (required); createdAt: string (required); statusVersion: integer (required) |
400 | The request is malformed or cannot be processed. | application/json — PublicApiError — error: object (required) |
401 | Authentication failed. The Authorization header is missing, or the credential is invalid or expired. | application/json — PublicApiError — error: object (required) |
403 | Access denied. The authenticated user does not have permission to perform this action. | application/json — PublicApiError — error: object (required) |
404 | Resource not found. | application/json — PublicApiError — error: object (required) |
409 | Request conflicts with current state of the resource, including safe deployment conflict classifications. | application/json — PublicApiError — error: object (required) |
422 | Request validation failed. Check the request body, query parameters, or path parameters. | application/json — PublicApiError — error: object (required) |
429 | Too many requests. The code foreign_resource_rate_limited means the caller made too many requests for Projects outside its reach: correct the Project id instead of retrying. | application/json — PublicApiError — error: object (required) |
500 | The server could not complete the request. | application/json — PublicApiError — error: object (required) |
503 | Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff. | application/json — PublicApiError — error: object (required) |
Decide an operation approval
PATCH /api/v1/operation-approvals/{approvalId}
Approve or reject a pending operation approval exactly once. For AgentRun approvals, either decision durably schedules the server-owned resume; clients cannot submit a privileged resume signal.
Parameters
path
| Name | Type | Required | Description |
|---|---|---|---|
approvalId | string | required | Identifies the operation approval being decided. Applies to Decide an operation approval. |
Request body
Required — Request body for: Decide an operation approval.
application/json
Alternative 1
| Name | Type | Required | Description |
|---|---|---|---|
status | "approved" | required |
Alternative 2
| Name | Type | Required | Description |
|---|---|---|---|
status | "rejected" | required |
Responses
| Status | Description | Body |
|---|---|---|
200 | Response for status 200 | application/json — object — type: "operationApproval" (required); id: string (required); invocationId: string (required); agentRunId: string | null (required); organizationId: string (required); projectId: string (required); environmentId: string (required); agentId: string (required); definitionId: string (required); definitionRevisionId: string; operationName: string (required); renderedSummary: string | null; requestedByUserId: string | null (required); status: "pending" | "approved" | "rejected" | "consumed" (required); decidedByUserId: string | null (required); decidedAt: string | null (required); consumedAt: string | null (required); requestedAt: string (required); createdAt: string (required); statusVersion: integer (required) |
400 | The request is malformed or cannot be processed. | application/json — PublicApiError — error: object (required) |
401 | Authentication failed. The Authorization header is missing, or the credential is invalid or expired. | application/json — PublicApiError — error: object (required) |
403 | Access denied. The authenticated user does not have permission to perform this action. | application/json — PublicApiError — error: object (required) |
404 | Resource not found. | application/json — PublicApiError — error: object (required) |
409 | Request conflicts with current state of the resource, including safe deployment conflict classifications. | application/json — PublicApiError — error: object (required) |
422 | Request validation failed. Check the request body, query parameters, or path parameters. | application/json — PublicApiError — error: object (required) |
429 | Too many requests. The code foreign_resource_rate_limited means the caller made too many requests for Projects outside its reach: correct the Project id instead of retrying. | application/json — PublicApiError — error: object (required) |
500 | The server could not complete the request. | application/json — PublicApiError — error: object (required) |
503 | Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff. | application/json — PublicApiError — error: object (required) |