Ask the agent a question
Adds a turn to the session and queues the agent run.
More details
More details
Authorizations
API key for authentication
Headers
Required opaque key (max 255 chars, UUIDv4 recommended) making this request idempotent for 24h: a retry with the same key and body replays the original response with Idempotent-Replayed: true. Omitting it is a 400; reusing a key with a different body is a 422; retrying while the first request is still in flight is a 409.
Path Parameters
Session to add the turn to.
Body
The question to ask.
30000"Which invoices from Acme are still unpaid?"
Restrict this turn to these files. Their documents are resolved for you. Omit to inherit the session's own scope.
100Restrict this turn to these documents. Takes precedence over file_ids.
100Restrict this turn to a directory.
"665f1c2e8a1b4c0012ab34cd"
Search the workspace's processed documents instead of a fixed list. Overrides file_ids and document_ids.
Bounded: the 100 most recently created processed documents are considered, newest first. A workspace larger than that is NOT searched in full — name the documents you care about with document_ids or file_ids when coverage matters.
Model hint for this turn. Defaults to the workspace-configured model.
"auto"
Allow the agent to search the public internet.
Allow the agent to run structured queries over your data as a sub-agent.
Opaque reference of your own, echoed back on the job and on the settlement webhook so you can correlate them with your own records.
255"order-4417"
BCP-47 language tag the agent should answer in.
"en"
Response
Turn accepted and queued.
Job handle for this turn. Poll it for the answer.
"sajob_9f2c1a4b7e8d4c1fa0b3"
Always QUEUED here. The job moves to RUNNING, then to COMPLETED, FAILED or STOPPED.
QUEUED "QUEUED"
The session this turn belongs to.
"665f1c2e8a1b4c0012ab34cd"
URL of GET /v1/jobs/{job_id}.