Runs
10 endpoints under /v1/runs.
List Runs
/v1/runsQuery parameters
ownerenumoptionalmeorgstatusstringoptional'open', 'terminal', or one run status.
kindenumoptionalarthurtask_workoutlineplacesubmissioncomposeroot_run_idstring (uuid)optional
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Run
/v1/runs/{run_id}Path parameters
run_idstring (uuid)required
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.
Cancel Run
/v1/runs/{run_id}/cancelStop the run and every open run under it. Race-guarded: a run that finished before the write stays finished.
Path parameters
run_idstring (uuid)required
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Run Context
/v1/runs/{run_id}/contextList every model call the run made, in order, with the newest window block by block.
Follow GET /runs/{run_id}/stream from here: each new call arrives as
a stage="context" frame.
Path parameters
run_idstring (uuid)required
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Run Context Step
/v1/runs/{run_id}/context/{manifest_id}Return one model call's window, with its blocks' text when kept.
Path parameters
run_idstring (uuid)requiredmanifest_idstring (uuid)required
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Run Live Bodies
/v1/runs/{run_id}/live-bodiesReturn what an open run has written so far, per subject.
Follow the run's stream from each body's cursor (attach contract in
:mod:domains.runs.live_body). A closed run has none: its subjects' own
records hold the result.
Path parameters
run_idstring (uuid)required
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.
Resume Run
/v1/runs/{run_id}/resumeAnswer the approval a run paused on (needs_input).
approve starts the work it holds; decline cancels it as
declined. The owner answers, or an org admin for someone else's run.
A run not awaiting approval answers 409 run_not_awaiting_approval.
Path parameters
run_idstring (uuid)required
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Request body
decisionenumrequiredOwner's answer to a run paused on approval (
POST /runs/{id}/resume).approvedecline
Failures return the error envelope; branch on error_code.
Stream Run
/v1/runs/{run_id}/streamStream the run's own detail (an Arthur turn's content parts and tool steps).
The first frame is connected with the run's current card, so a late
client can draw it before any detail arrives. A finished run gets that
frame plus the replay requested, then the stream closes.
Path parameters
run_idstring (uuid)required
Query parameters
sincestringoptionalResume cursor: the last event id seen. '0-0' replays the retained history; '$' (default) is new frames only.
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Run Tree
/v1/runs/{run_id}/treePath parameters
run_idstring (uuid)required
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.
Stream My Runs
/v1/runs/liveStream a stage="run" frame for every lifecycle change of the caller's runs.
Covers every run the caller owns, whatever started it (a view, Arthur,
an API key, a schedule).
Query parameters
sincestringoptionalResume cursor: the last event id seen. '0-0' replays the retained history; '$' (default) is new frames only.
Headers
X-Organization-IDstringoptionalX-Workspace-IDstringoptional
Failures return the error envelope; branch on error_code.