Stream run events

streamRunEvents(command: RunsStreamRunEventsCommand!, lastEventId: String): RunsStreamFrame!

Arguments

ArgumentTypeRequired
commandRunsStreamRunEventsCommand!Yes
lastEventIdStringNo

Input fields

command

RunsStreamRunEventsCommand

FieldTypeRequiredDescription
runIdID!YesRun UUID, or the public run id (run_…) that run lists and getRun carry as run_id. Normal callers need access to the run owner and project.runs.read. A bound eval runtime may instead read its authorized direct agent child.
eventRepresentationStringNoUse run-events-v1 to receive Agent Events Protocol CloudEvents, or ag-ui for receipt-backed AG-UI events from Agent runs. Omit it to keep the released run-event row stream contract.

Response

Returns RunsStreamFrame!. Open the type for its fields and nested types.

FieldTypeDescription
eventIdFloatDurable reconnect cursor; null for transient frames.
eventTypeString!Stored event type used for the SSE event name.
payloadJSON!
isErrorBoolean!Error classification from the stored row.
createdAtStringStored timestamp; null when the frame has no stored timestamp.
runIdID
eventClassString
spanIdID

All fields of RunsStreamFrame.

Types marked with ! cannot be null. Lists use [Type] notation. The type index lists all published input and response types.

Example

query.graphql
subscription StreamRunEvents($command: RunsStreamRunEventsCommand!, $lastEventId: String) {  streamRunEvents(command: $command, lastEventId: $lastEventId) {    spanId    runId    createdAt    eventClass    eventId  }}
variables.json
{  "command": {    "runId": "11111111-1111-4111-8111-111111111111"  },  "lastEventId": "12"}