stream to
choose the response shape.
POST /v1/sessions/{session_id}/messages -
POST /{org}/{agent}/v1/sessions/{session_id}/messages
Request
The message to send.
The sending participant; messages are
attributed to it.
human or ai.Surface extended-thinking /
reasoning events.true -> Server-Sent Events. false -> a single accumulated JSON response.Unary response (stream: false)
Streaming response (stream: true)
text,
tool_use, reasoning, step_start, step_finish, input_required,
error, done. A turn may pause with input_required to request approval -
resolve it via Inputs.
Status codes
Want to drive an agent with an existing OpenAI or Anthropic client instead of
this native shape? Use a consumer adapter
- same turn, re-framed into those wire formats.

