Create and wait
input is the task sent to the agent. context carries trusted application
data such as a tenant ID; AIR passes it to tools that declare a context
parameter. webhook_url is optional.
Consume structured output
When the active agent version has an output schema,Run.output is the parsed,
validated object described by that schema:
result.output["text"].
Stream output as it is generated
Usestream() when a UI or CLI should show the model response before the run
finishes:
RunEvent includes seq, type, data, and created_at. If the connection
drops, the SDK reconnects and requests events after the last sequence number,
so missed output is replayed rather than skipped.
Use after_seq when you persist the last processed sequence number yourself:
Run with get() when you need the authoritative
final status, validated structured output, error, or cost.
Read or cancel
Run exposes id, status, output, error, cost_usd, and the
complete response as raw.
Inspect the same run visually
Open Runs in the console to inspect the event sequence, model request and response, token usage, cost, and configuration snapshot.
The console trace for a run created through the same public API used by the SDK.

