Skip to main content
GET
Get document lineage

Authorizations

Authorization
string
header
required

Mixpeek API key, sent as Authorization: Bearer mxp_sk_.... Create one in Studio under Settings → API Keys, or with an admin key via POST /v1/organizations/users/{user_email}/api-keys. A missing header returns 403; an invalid or revoked key returns 401.

X-Namespace
string
header
required

Namespace id (ns_...), not the namespace name. This scopes the request rather than authenticating it, and it is required on every operation marked x-mixpeek-namespace-scoped.

Path Parameters

collection_id
string
required

ID of the collection containing the document

document_id
string
required

ID of the document to trace

Response

Document lineage information

Lineage for one document, or a statement that it has none.

document_id
string
required

Document that was traced.

collection_id
string
required

Collection it was traced in.

lineage
DocumentLineage · object | null

Null when the document carries no lineage, in which case message says why. Null is not an error and the response is still 200.

depth
integer
default:0

ALWAYS 0 TODAY. Reserved for depth in the decomposition tree, pending calculation from lineage_path. Do not read 0 as 'this is a root document'.

total_steps
integer
default:0

ALWAYS 0 TODAY, for the same reason as depth. Do not read 0 as 'no processing happened'.

message
string | null

Present only when lineage is null, explaining the absence. Absent on a successful trace.

Example:

"Document does not have lineage information (created before Phase 2)"