Skip to main content
POST
Send input to a session

Authorizations

Authorization
string
header
required

A gbr_pat_ access token. Scopes are recorded on the token when it is minted.

Headers

Idempotency-Key
string

Retrying with the same key replays the first answer instead of acting again.

Maximum string length: 255

Body

application/json

One event per request. Batching has no meaning while the vocabulary is this small.

events
object[]
required

Exactly one event. What it does depends on its type — send a message, answer a tool call, approve, steer or cancel.

Required array length: 1 element

Response

Send input to a session: a message, a cancellation, or a tool result.

object
string
required

Always input.accepted. Names the shape, so a value can be identified without knowing which call returned it.

Allowed value: "input.accepted"
session_id
string
required
type
enum<string>
required
Available options:
input.message,
input.cancel,
input.tool_result,
input.steer
outcome
enum<string>

For input.tool_result.

Available options:
accepted,
already_resolved,
not_delivered
queued
boolean

The session was busy; the message is durably queued and will run.

queue_position
integer | null