Documentation menu

Agent Runs

15 operations.

MethodEndpointDescription
GET/api/v1/agent-runsList runs
POST/api/v1/agent-runsStart a run
GET/api/v1/agent-runs/{agentRunId}Get a run
GET/api/v1/agent-runs/{agentRunId}/available-modelsRead the Run's selected model and configured alternatives at its pinned deployment
POST/api/v1/agent-runs/{agentRunId}/cancelCancel a live run
GET/api/v1/agent-runs/{agentRunId}/checkpointsList the run's checkpoint metadata
GET/api/v1/agent-runs/{agentRunId}/checkpoints/latestGet the latest checkpoint bundle
POST/api/v1/agent-runs/{agentRunId}/continueContinue a run
GET/api/v1/agent-runs/{agentRunId}/stepsList steps
GET/api/v1/agent-runs/{agentRunId}/steps/{agentStepId}Get a step
GET/api/v1/agent-runs/{agentRunId}/steps/{agentStepId}/checkpoints/{checkpointId}Get checkpoint artifact metadata
HEAD/api/v1/agent-runs/{agentRunId}/steps/{agentStepId}/checkpoints/{checkpointId}Get checkpoint artifact metadata
GET/api/v1/agent-runs/{agentRunId}/streamStream live run telemetry
GET/api/v1/agent-runs/{agentRunId}/transitionsReplay a run's lifecycle journal
GET/api/v1/agent-runs/{agentRunId}/work-memory-readsList the past runs this run recalled

List runs

GET /api/v1/agent-runs

List canonical Agent Runs accessible to the authenticated credential.

Scope

  • Authorization is evaluated against the caller's Organization and Agent scope before pagination.
  • A Project or Environment filter narrows the authorized run collection; it does not widen access.
  • API keys and sessions use the same resource and operation authorization boundary.

Filtering

  • projectId: Optional canonical Project filter.
  • environmentId: Optional canonical Environment filter.
  • agentId: Optional canonical Agent filter.
  • agentRunId: Optional exact Agent Run filter; combined with the other filters, it returns the run only when every filter matches.
  • agentJobId: Optional scheduled Agent Job firing filter.
  • createdBy: Optional creator identity filter.
  • states: Optional lifecycle-state filter (comma-separated list or array).

Sorting

  • sort: createdAt or updatedAt.
  • order: asc or desc.

Pagination

  • limit: Number of Agent Runs to return (1–100, default 20).
  • cursor: Opaque cursor returned in pagination.nextCursor; reuse it only with the same filters and ordering.

Response

  • Returns agentRuns with canonical run ID, Agent and Agent Revision identity, actor, lifecycle state, digests, timestamps, runtime version, and content size.
  • Returns pagination with the next opaque cursor when another page is available; no separate total-count field is returned.

Authentication

  • Requires a valid session or API key in the Authorization header.

Parameters

query

NameTypeRequiredDescription
sort"createdAt" | "updatedAt"optionalSelects the resource field used to order results. Applies to List runs.
order"asc" | "desc"optionalSelects ascending or descending order for the requested sort field. Applies to List runs.
limitintegeroptionalSets the maximum number of resources returned in this page. Applies to List runs.
cursorstringoptionalOpaque cursor returned by the previous page; omit it to read the first page. Applies to List runs.
projectIdstringoptionalFilters results to the specified Project. Applies to List runs.
environmentIdstringoptionalSelects the active Project environment coordinate. Applies to List runs.
agentIdstringoptionalSelects the Project Agent by its stable identifier. Applies to List runs.
agentRunIdstringoptionalFilters runs to the single Agent Run with this identifier. Applies to List runs.
agentJobIdstringoptionalFilters runs to those created by this scheduled agent job. Applies to List runs.
createdBystringoptionalFilters runs to the specified creator identity. Applies to List runs.
statesarray<"queued" | "acquiring" | "starting" | "running" | "awaitingToolResult" | "awaitingDelegateResult" | "canceling" | "completed" | "failed" | "canceled" | "expired">optionalFilters runs to the supplied set of lifecycle states. Applies to List runs.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — agentRuns: array<AgentRun> (required); pagination: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Start a run

POST /api/v1/agent-runs

Start a new Agent Run for a Project Agent or System Agent.

Ownership

  • Requires agentId; Project Agents may also specify environmentId.

Agent Resolution

  • The target Agent and its active revision are resolved server-side.

Provider selection

  • Project Agents require a configured Project model policy. Omit provider and model to use that policy's default; explicit selections must be allowed by the policy and eligible for the immutable Environment configuration.
  • Credentials come from the configuration's pinned Organization binding or the deployment-managed provider route. Selecting a provider does not select a credential source. Unavailable bindings are rejected without fallback.
  • System Agents use the deployment's default provider/model and credentials.

Execution

  • AgentRun admission persists the run and queues asynchronous dispatch to a dedicated runner; runner execution does not block the response.
  • Dispatch capacity and idempotency leases can produce 503/429 responses with Retry-After. A request may already have durable admission state, so use an Idempotency-Key when retrying and inspect the AgentRun state.
  • After admission the run is handed to the runner; progress is journaled as lifecycle transitions (see GET /agent-runs/:agentRunId/transitions) and can be monitored via the checkpoints endpoint.
  • JSON requests may provide canonical contents; multipart requests may repeat files (UTF-8 text, supported images, or PDF). Files are validated and converted to inline message parts before dispatch.

Authentication

  • Requires a valid session or API key in the Authorization header.

Parameters

header

NameTypeRequiredDescription
Idempotency-Keystringoptional

Request body

Required — Request body for: Start a run.

application/json

NameTypeRequiredDescription
agentIdstringrequiredProject or System Agent ID for the new agent run
environmentIdstringoptional
fdaWorkIdstringoptional
querystringoptional
contentsarray<one of 3 types>optional
provider"anthropic" | "google" | "openai" | "deepseek" | "azure-openai" | "amazon-bedrock" | "google-vertex" | "fireworks"optional
modelstringoptional
reasoningBudgetone of 2 typesoptional
maxRetriesnumberoptional
subjectUserIdstringoptional

multipart/form-data

NameTypeRequiredDescription
agentIdstringrequired
environmentIdstringoptional
fdaWorkIdstringoptional
querystringoptional
provider"anthropic" | "google" | "openai" | "deepseek" | "azure-openai" | "amazon-bedrock" | "google-vertex" | "fireworks"optional
modelstringoptional
reasoningBudgetone of 2 typesoptional
maxRetriesnumberoptional
subjectUserIdstringoptional
filesarray<file>requiredRepeat files for UTF-8 text, supported images, or PDF; each <=5 MiB, total <=10 MiB.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
402Payment required. The organization has exhausted its billing-period minute budget. Upgrade the plan or wait for the period to roll over.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Rate limited by the execution backend during admission or dispatch. The response carries a Retry-After header; use an Idempotency-Key when retrying and inspect the AgentRun state.application/json — PublicApiError — error: object (required)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable while admitting or dispatching the run. Durable admission may already exist; the response carries a Retry-After header. Use an Idempotency-Key when retrying and inspect the AgentRun state.application/json — PublicApiError — error: object (required)

Get a run

GET /api/v1/agent-runs/{agentRunId}

Retrieve one canonical Agent Run by its opaque run_ ID.

Ownership

  • The run is resolved by its canonical ID and must be authorized in the caller's Organization and Agent scope.
  • A run retains the Agent and immutable Agent Revision identity selected at admission; it is not rebound to a newer revision.

Response

  • Returns the public Agent Run record, including Agent and Agent Revision identity, actor references, lifecycle state, digests, timestamps, runtime version, and content size.
  • The response does not expose internal execution tables, provider details, token statistics, or a separate step collection.

AgentRun Lifecycle States

  • queued: Accepted; no live attempt
  • acquiring: Attempt opened; machine lease in progress
  • starting: Machine leased; runner handoff and runtime boot
  • running: Runtime executing
  • awaitingToolResult: Paused for an interactive tool result
  • awaitingDelegateResult: Paused for an external delegate result
  • canceling: Cancel requested; runtime winding down
  • completed / failed / canceled / expired: Terminal

Authentication

  • Requires a valid session or API key in the Authorization header.
  • The credential must be authorized for the run's Agent Run operation and resource scope.

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Get a run.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Read the Run's selected model and configured alternatives at its pinned deployment

GET /api/v1/agent-runs/{agentRunId}/available-models

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Read the Run's selected model and configured alternatives at its pinned deployment.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Cancel a live run

POST /api/v1/agent-runs/{agentRunId}/cancel

Cancel a run. The outcome depends on the run's lifecycle state:

  • running: the run transitions to canceling and the execution worker is signaled to stop after the current step; its final report settles the run as canceled.
  • queued, acquiring, starting, awaitingToolResult, awaitingDelegateResult: the run transitions straight to canceled and any held machine is released.
  • canceling: retry-safe; the execution worker is signaled again and the current run is returned.
  • canceled: already satisfied; the current run is returned.
  • completed, failed, or expired: 409 Conflict; the message carries the run's current state.

Authentication

  • Requires a valid API key supplied in the Authorization header.
  • The caller must be authorized for the run's Project and Environment operation scope. No tenant ID is accepted; the run is resolved server-side by its canonical ID.

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Cancel a live run.

header

NameTypeRequiredDescription
Idempotency-Keystringoptional

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Conflict. The run has reached a terminal state that cannot be canceled. The message carries the run's current state.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

List the run's checkpoint metadata

GET /api/v1/agent-runs/{agentRunId}/checkpoints

Returns one row per persisted checkpoint artifact for the run.

Use the returned identifiers to fetch any checkpoint resources needed by the client.

Authentication

  • Requires session or API key with operation agent-runs:checkpoints:list
  • The caller must be authorized for this operation within the run's owning organization and its persisted Project, Environment, or Agent scope

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to List the run's checkpoint metadata.

query

NameTypeRequiredDescription
limitintegeroptionalSets the maximum number of resources returned in this page. Applies to List the run's checkpoint metadata.
cursorstringoptionalOpaque cursor returned by the previous page; omit it to read the first page. Applies to List the run's checkpoint metadata.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — checkpoints: array<object> (required); pagination: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Get the latest checkpoint bundle

GET /api/v1/agent-runs/{agentRunId}/checkpoints/latest

Retrieve the latest persisted checkpoint for an AgentRun together with its runtime checkpoint and step payload. The lookup is scoped to the caller's organization and operation-specific Project, Environment, or Agent access, and uses the same latest selector as run continuation.

Authentication

  • Requires session or API key with operation agent-runs:steps:checkpoints:get
  • Automated-run credentials must be bound to the run's agent revision

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Get the latest checkpoint bundle.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Continue a run

POST /api/v1/agent-runs/{agentRunId}/continue

Continue an agent run in a resumable state in the specified project agent. When a checkpoint exists the run resumes from the latest one; otherwise it starts a fresh attempt with the provided query. Approval decisions are processed by the operation-approval resource and enqueue a durable, server-owned resume. This endpoint accepts only an ordinary authorized continuation query; it cannot carry an approval decision or privileged resume signal.

Ownership

  • The persisted execution target identifies the project agent (or system agent)
  • AgentRun must belong to that persisted target

Use Cases

  • Respond to interactive tool requests.
  • Add the next user message to a completed run (multi-turn chat). Optional contents attach new files to this turn. Original attachment payloads are not replayed as new input.
  • Retry after failure or after a cancel.

State Requirements

  • AgentRun must be in a resumable state: completed, awaitingToolResult, failed, or canceled. expired is dead and rejects with 409; an externally waiting run rejects with 400. A live state (queued/acquiring/starting/running/canceling) rejects with 409 Conflict; the response message carries the run's current state.

Authentication

  • Requires a valid session or API key in the Authorization header
  • The credential must be authorized for the persisted execution target

Provider selection

  • Omit provider and model to keep the Run's last recorded selection. Historical Runs without a record require both provider and model explicitly.
  • Project Agent selections are rechecked against the current Project model policy and the Run's persisted Environment configuration. A removed selection is rejected; it is never silently replaced by the policy default.
  • Credentials are resolved from the pinned binding or deployment route at continuation time. Unavailable credentials are rejected without fallback.

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Continue a run.

header

NameTypeRequiredDescription
Idempotency-Keystringoptional

Request body

Required — Request body for: Continue a run.

application/json

NameTypeRequiredDescription
querystringrequired
contentsarray<one of 3 types>optional
provider"anthropic" | "google" | "openai" | "deepseek" | "azure-openai" | "amazon-bedrock" | "google-vertex" | "fireworks"optional
modelstringoptional
reasoningBudgetone of 2 typesoptional
maxRetriesnumberoptional

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
402Payment required. The organization has exhausted its billing-period minute budget. Upgrade the plan or wait for the period to roll over.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Conflict. The run is not in a resumable state (it is live, expired, or another request queued it first). The message carries the run's current state. The response may include a safe details.conflictReason classification.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Rate limited while starting the run. The run is left in its prior resumable state. Retry-After header set.application/json — PublicApiError — error: object (required)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable. Execution capacity could not secure a runner right now. The run is left in its prior resumable state. Retry-After header set.application/json — PublicApiError — error: object (required)

List steps

GET /api/v1/agent-runs/{agentRunId}/steps

List all agent steps for a specific run.

Sorting

  • sort: Sort by createdAt or updatedAt
  • order: Sort order (asc or desc)

Pagination

  • limit: Number of results to return (1-100, default 20)
  • cursor: Opaque cursor returned in pagination.nextCursor.

Depth

  • depth: Tree depth for nested step responses (0-10, default 0)
  • 0: Flat list of all steps (default)
  • 1: Root steps only (parentAgentStepId is null) with lastCheckpointId and empty childAgentSteps
  • 2+: Root steps with nested childAgentSteps up to the specified depth

Response

  • Returns steps with full details
  • Each step includes agent information and execution context
  • pagination.count is the number of steps in this page

Authentication

  • Requires a valid session or API key in the Authorization header

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to List steps.

query

NameTypeRequiredDescription
sort"createdAt" | "updatedAt"optionalSelects the resource field used to order results. Applies to List steps.
order"asc" | "desc"optionalSelects ascending or descending order for the requested sort field. Applies to List steps.
limitintegeroptionalSets the maximum number of resources returned in this page. Applies to List steps.
cursorstringoptionalOpaque cursor returned by the previous page; omit it to read the first page. Applies to List steps.
depthintegeroptionalLimits step expansion to the requested nesting depth. Applies to List steps.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — agentSteps: array<AgentStepTreeNode> (required); pagination: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Get a step

GET /api/v1/agent-runs/{agentRunId}/steps/{agentStepId}

Retrieve detailed information about a specific step.

Response

  • Returns full step details
  • Includes agent information and execution context

AgentStep Data

  • Step execution details (timing, token usage)
  • Agent information used for the step
  • Status and execution metadata

Authentication

  • Requires a valid session or API key in the Authorization header
  • The caller must have operation-specific access to the run's owning organization and persisted Project, Environment, or Agent scope

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Get a step.
agentStepIdintegerrequiredIdentifies the step within the addressed agent run. Applies to Get a step.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Get checkpoint artifact metadata

GET /api/v1/agent-runs/{agentRunId}/steps/{agentStepId}/checkpoints/{checkpointId}

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Get checkpoint artifact metadata.
agentStepIdintegerrequiredIdentifies the step within the addressed agent run. Applies to Get checkpoint artifact metadata.
checkpointIdintegerrequiredIdentifies the checkpoint within the addressed agent step. Applies to Get checkpoint artifact metadata.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Get checkpoint artifact metadata

HEAD /api/v1/agent-runs/{agentRunId}/steps/{agentStepId}/checkpoints/{checkpointId}

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Get checkpoint artifact metadata.
agentStepIdintegerrequiredIdentifies the step within the addressed agent run. Applies to Get checkpoint artifact metadata.
checkpointIdintegerrequiredIdentifies the checkpoint within the addressed agent step. Applies to Get checkpoint artifact metadata.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required)
204Response for status 204none — none
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Stream live run telemetry

GET /api/v1/agent-runs/{agentRunId}/stream

Stream live runtime telemetry for an agent run via Server-Sent Events (SSE).

  • Runtime PerstackEvent objects are relayed as message events.
  • ping events are transport keepalives only.
  • Lifecycle state is not part of this stream. Use GET /agent-runs/:id for current state, /transitions for lifecycle history, and checkpoints for durable runtime history/replay.
  • The stream is bound to the run attempt it attached to. It closes when that attempt's runtime telemetry ends, or within about two seconds after the run leaves its live state (running / canceling) or the attached attempt ends, whether or not a terminal runtime event was relayed. Read GET /agent-runs/:id for the outcome, and re-attach only when that state is live again.
  • The route performs auth/resource/state/runner-attach preflight before the SSE body starts. Non-live states return HTTP status: 409 when no live runtime stream exists, 503 + Retry-After when the run is not ready or runner attachment is temporarily unavailable.

Authentication

  • Requires a valid session or API key in the Authorization header

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Stream live run telemetry.

Responses

StatusDescriptionBody
200SSE stream (text/event-stream)text/event-stream — string
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

Replay a run's lifecycle journal

GET /api/v1/agent-runs/{agentRunId}/transitions

Return the run's full transition journal in seq order. Every lifecycle change (queued→acquiring, …, terminal) is one journal entry carrying the acting component, the attempt it belongs to, and an optional reason.

Authentication

  • Requires a valid session or API key in the Authorization header
  • The credential must be authorized for the canonical Agent Run operation and its Organization/Project/Environment/Agent resource scope

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to Replay a run's lifecycle journal.

query

NameTypeRequiredDescription
limitintegeroptionalSets the maximum number of resources returned in this page. Applies to Replay a run's lifecycle journal.
cursorstringoptionalOpaque cursor returned by the previous page; omit it to read the first page. Applies to Replay a run's lifecycle journal.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — data: object (required); pagination: object (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)

List the past runs this run recalled

GET /api/v1/agent-runs/{agentRunId}/work-memory-reads

Returns every long-term memory read the run's work-memory delegate performed, oldest first: which past run it read and whether it saw an excerpt, the summary, or the transcript.

Parameters

path

NameTypeRequiredDescription
agentRunIdstringrequiredIdentifies the agent run whose state or history is addressed. Applies to List the past runs this run recalled.

Responses

StatusDescriptionBody
200Response for status 200application/json — object — reads: array<object> (required)
400The request is malformed or cannot be processed.application/json — PublicApiError — error: object (required)
401Authentication failed. The Authorization header is missing, or the credential is invalid or expired.application/json — PublicApiError — error: object (required)
403Access denied. The authenticated user does not have permission to perform this action.application/json — PublicApiError — error: object (required)
404Resource not found.application/json — PublicApiError — error: object (required)
409Request conflicts with current state of the resource, including safe deployment conflict classifications.application/json — PublicApiError — error: object (required)
422Request validation failed. Check the request body, query parameters, or path parameters.application/json — PublicApiError — error: object (required)
429Too 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)
500The server could not complete the request.application/json — PublicApiError — error: object (required)
503Service temporarily unavailable (e.g. execution capacity exhausted). The response carries a Retry-After header; retry with backoff.application/json — PublicApiError — error: object (required)