Authorization header.
Start a streaming run
RunRequest body as the synchronous endpoint and returns a text/event-stream response. Each event is a JSON-encoded AgentStreamEvent object.
Path parameters
string
required
The unique identifier of the agent to run. Retrieve valid IDs from
GET /api/agents.Request body
string
required
The user’s input or query.
string
A UUID identifying an existing conversation session. Enables multi-turn conversations. Omit to start a fresh session.
string
Associates the run with a specific user for memory scoping and audit logs.
string
Tenant identifier for multi-tenant deployments.
boolean
default:"false"
When
true, the agent appends suggested follow-up questions to the final STOP event payload.object[]
Array of multimodal inputs. Each object has a
type (MIME type string) and data (base64 or URL).object
Optional model overrides (
model, temperature, maxTokens).Response: AgentStreamEvent schema
The response is atext/event-stream. Each line prefixed with data: contains a JSON-encoded AgentStreamEvent:
string
required
The event type discriminator. See the EventType reference below.
string
required
The payload for this event. Its meaning depends on the
event type — a text delta for CONTENT_DELTA, a JSON string for tool events, or an error message for ERROR.number
required
Unix epoch milliseconds at the time the event was emitted by the server.
EventType values
Raw SSE stream example
TypeScript example
Check run status
AgentRun entity, including timestamps and final output.
string
required
The agent that owns the run.
string
required
The run identifier, returned in the
START event’s data payload.AgentRun entity with status (RUNNING, COMPLETED, FAILED, PAUSED, or CANCELLED) and associated timestamps.
Batch status check
404 is returned for missing IDs.
string
required
The agent that owns the runs.
string
required
A comma-separated list of run IDs to check. Maximum 100 IDs per request.
The batch status endpoint significantly reduces polling overhead. For 10 concurrent runs polled every 3 seconds, one batched call replaces 10 individual requests — dropping from ~200 requests/minute to ~20.