Run the full document agent against an indexed PDF or document. The agent autonomously plans its research strategy and iteratively uses tools (search, read sections, read pages, navigate tree) to produce comprehensive answers with citations. Supports optional structured output via json_schema.
API key must be provided in the Authorization header
Request to deploy an autonomous document agent. The agent researches the document using tools and supports structured output via json_schema.
Data source ID of the indexed document
Question to ask about the document
1 - 10000JSON Schema for structured output. When provided, the agent returns a structured_output field conforming to this schema.
Model to use (claude-opus-4-6-1m, claude-opus-4-6, claude-sonnet-4-5-20250929, etc.)
Enable extended thinking for more thorough analysis
Token budget for thinking (ignored for adaptive models like Opus 4.6)
1000 <= x <= 50000Stream response as SSE events
Successful Response
The agent's comprehensive answer with inline citations
Model used for the response
Citations from the document with page numbers and section paths
Structured data conforming to the provided json_schema (only present when json_schema was provided)
Token usage statistics