Skip to main content
POST
Get a document

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

X-Session-ID
string

Optional client session identifier.

Body

application/json
canonical_url
string<uri>

Canonical URL from a result's canonical_url; lookup alternative to doc_id. Either doc_id or canonical_url is required.

content
object

Controls for returned document content: selection strategy, format, size cap, and continuation range.

debug
object

Reserved for internal evaluation harnesses; ignored for public callers.

doc_id
string<uuid>

Canonical document identifier (UUID) from a search result's doc_id; stable across searches and recrawls. Either doc_id or canonical_url is required.

Example:

"0c944fa8-4c8f-4f48-9b08-0fb2fd3438ec"

include
enum<string>[] | null

Sections to return. Omit it for everything available; otherwise an allowlist of passages, capture_history, and content (document metadata is always returned - send just metadata for a metadata-only read).

Available options:
metadata,
passages,
capture_history,
content
query
string

Query context for passage selection when content.selection is query_relevant.

Response

Document payload.

access
object
required
doc
object
required
request_id
string
required
session_id
string
required
$schema
string<uri>
read-only

A URL to the JSON Schema for this object.

Example:

"https://alpha.api.trycaesar.com/DocumentResponse.json"

capture_history
object[] | null
content
object
passages
object[] | null
provenance
object
usage
object
warnings
object[] | null