ReferenceEvents and execution

Run states and error categories

The complete enums for routine status, run state, trigger, step kind, and error category.

These enums are shared between the API, the dashboard, and webhook payloads.

Routine status

draft | active | paused | archived
ValueSchedulableRunnable manually
draftNoYes
activeYesYes
pausedNoYes
archivedNoNo

Run state

queued | claimed | running | succeeded | failed | cancelled | timed_out

Terminal states are succeeded, failed, cancelled, and timed_out. Poll for membership of that set.

Run trigger

manual | api | schedule

Only a successful manual run satisfies the activation requirement.

Step kind

model | tool_call | tool_result | error

Error category

authentication | configuration | gateway_rate_limit | gateway_timeout |
gateway_error | invalid_model | mcp_discovery | mcp_transport | tool_denied |
tool_error | step_limit | timeout | cancelled | internal
CategoryRetryable
authenticationNo
configurationNo
gateway_rate_limitYes
gateway_timeoutYes
gateway_errorYes
invalid_modelNo
mcp_discoveryNo
mcp_transportYes
tool_deniedNo
tool_errorNo
step_limitNo
timeoutYes
cancelledNo
internalNo

Retryability is reported on webhook payloads as run.error.retryable. See Troubleshooting for what to change in each case.

Run usage

{
  inputTokens: number; // integer, ≥ 0
  outputTokens: number; // integer, ≥ 0
  totalTokens: number; // integer, ≥ 0
  costUsd: number | null; // null when the gateway does not report cost
}

Usage appears on each model step and aggregated on the run.

On this page

Edit this page on GitHub