Skip to main content
POST
Continue Agent Run

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

agent_id
string
required
run_id
string
required

Body

application/x-www-form-urlencoded
tools
string
default:""

JSON string of tool call results to continue the paused run

input
string | null

Optional new user-message text to append to the run before resuming. Use for continuing a COMPLETED run with a follow-up, or adding context to a RUNNING/ERROR resume.

continue_from
string
default:end

Continuation boundary. Use 'end', 'last_user', or a numeric message index.

fork
boolean
default:false

When true, clone the run with a new run_id before resuming. The original is untouched; the clone becomes a sibling within the same session, with forked_from_run_id set.

regenerate
boolean
default:false

Sugar: regenerate the last response of this run. Auto-computes continue_from='last_user' to land just after the last user message. Pair with additional_instructions to steer the new output. By default the original response is hidden from history (replaced); pass replace_original=false to keep both the original and the regenerated response visible side by side.

replace_original
boolean | null

Only valid with regenerate=true. Controls history visibility of the original response; the original run is always retained in storage. Defaults to true: the original is marked REGENERATED and hidden from history so the new response replaces it. Pass false to keep both the original and regenerated responses visible.

additional_instructions
string | null

Only valid with regenerate=true: extra guidance appended as a user message before re-generation. Friendly alias for input.

session_id
string | null

Session ID for the paused run

user_id
string | null

User identifier for tracking and personalization

stream
boolean
default:true

Enable streaming responses via Server-Sent Events (SSE)

background
boolean
default:false

Run continue in background (survives client disconnect). Requires database. Use /resume to reconnect.

Response

A non-streaming run response or a server-sent event stream. Streaming execution failures are delivered as events after the stream starts.

run_id
string
required

Unique identifier for the run

parent_run_id
string | null

Parent run ID if this is a nested run

agent_id
string | null

Agent ID that executed this run

user_id
string | null

User ID associated with the run

status
string | null

Run status (PENDING, RUNNING, COMPLETED, ERROR, etc.)

run_input
string | null

Input provided to the run

content

Output content from the run

run_response_format
string | null

Format of the response (text/json)

reasoning_content
string | null

Reasoning content if reasoning was enabled

reasoning_steps
Reasoning Steps · object[] | null

List of reasoning steps

metrics
Metrics · object | null

Performance and usage metrics

messages
Messages · object[] | null

Message history for the run

tools
Tools · object[] | null

Tools used in the run

events
Events · object[] | null

Events generated during the run

created_at
string<date-time> | null

Run creation timestamp

references
References · object[] | null

References cited in the run

citations
Citations · object | null

Citations from the model (e.g., from Gemini grounding/search)

reasoning_messages
Reasoning Messages · object[] | null

Reasoning process messages

session_state
Session State · object | null

Session state at the end of the run

images
Images · object[] | null

Images included in the run

videos
Videos · object[] | null

Videos included in the run

audio
Audio · object[] | null

Audio files included in the run

files
Files · object[] | null

Files included in the run

response_audio
Response Audio · object | null

Audio response if generated

input_media
Input Media · object | null

Input media attachments

followups
string[] | null

Followup suggestions generated after the run

forked_from_run_id
string | null

If this run was forked from another run, the source run's ID

forked_from_message_index
integer | null

If this run was forked, the message index at which the source was truncated

forked_from_session_id
string | null

If this run was created via session branch, the source session's ID

regenerated_from
string | null

If this run was produced via regenerate=true, the source run's ID

last_checkpoint_at_message_index
integer | null

Message index of the most recent mid-run checkpoint (checkpoint='tool-batch' runs)