Get a document
Full ChatAttachment projection for the unified viewer.
att_id is the attachment id from the list route. A missing or cross-tenant id is 404.Authorizations
Organisation API key from Settings → API / /api/keys/. The secret is
shown once. Send Authorization: Bearer sk-abacus-…. One active key
per organisation. Ingest (/api/v2/ingest/*) refuses API keys — that
surface is Auth0-only with ingest:read / ingest:write scopes.
Path Parameters
Response
Full projection of a ChatAttachment for the unified document view.
Extends the list item with the heavy content + extraction surface the
document viewer (tabs: Extracted / Markdown / Translation / Warnings)
needs in one round-trip. extraction_result + extraction_overrides
are returned independently so the client can render the LLM original, the
user override, or both side-by-side without a follow-up call, and
extraction_status carries the quality verdict on that extraction
(AD-520) so a sparse or mismatched result is not indistinguishable from
a clean one.
Lynx processing pipeline status: pending → completed/failed
pending- Pendingcompleted- Completedfailed- Failed
pending, completed, failed Processing completion percentage 0-100
Current processing stage name, or the failure reason on a FAILED attachment
Number of pages in the original document
True when a schema (StructVersion) is pinned for extraction.
StructVersion that produced this attachment's extraction_result. NULL for non-batch attachments or pre-versioning records.
ISO language code for translation target (e.g. 'en', 'ar')
Whether this attachment came from Knowledge Base
Original Knowledge Base file ID if from KB
Lynx document ID after processing (extraction + chunking + indexing)
Cached document summary from Lynx processing
True when schema-guided extraction produced a result.
True when at least one translated version exists.
True when Lynx emitted any processing warnings.
When Lynx processing finished (set on COMPLETED/FAILED transitions).
Translated versions keyed by language, minus internal Lynx ids.
Quality verdict on the extraction, independent of processing_status.
success / partial / schema_mismatch / ocr_failed, or
None when no extraction has run. AD-520: processing_status
answers "did the pipeline finish", this answers "is the extraction any
good" — a refused verdict is processing_status="failed" with every
field the engine DID recover still present in extraction_result,
and the human-readable reason on processing_stage. Same vocabulary
the batch grid publishes, so the two document surfaces describe one
document identically.
Reads the pinned StructVersion — the detail view
select_relateds it, so this costs no extra query.
The raw per-field override map (empty dict when none).
The (slug, version, schema_url) triple for the producing StructVersion.
Returns None when the doc was processed without a schema (free
transcription) or the version reference was orphaned by hard delete.
Mirrors serializers.DocumentDetailSerializer.get_extraction_struct
so both document surfaces emit the same schema-navigation shape.
Per-page Lynx warnings; empty list when the doc processed cleanly.

