Get a document version
GET/documents/:document_id
Returns one version of a document, found by the document identifier alone. Without the version query parameter, the response is the latest version of the document that has not expired, and an expired document returns HTTP 404 unless the request sets include_expired=true. With version, the response is that version, whether or not the version has expired. The status field of the response shows whether processing of the version is complete.
Permissions. Read on the document's pipeline, and a classification allow-list that covers the document's classification.
Documents, versions and fragments describes versions and the processing status.
Request
Responses
- 200
- 400
- 401
- 403
- 404
The version was found. The body is the document version.
The version value lies outside the range of valid timestamps (Invalid version).
The authentication headers are missing or invalid, or the API key is inactive or expired. Errors lists the messages.
The key lacks read permission on the pipeline that contains the document (Unauthorized: read access to Pipeline required, with the pipeline identifier in details.id), or the key's classification allow-list for the pipeline does not cover the document's classification (the same message, with the reason in details.error).
No document with this identifier exists, the document has no version with the given version value, or the latest version has expired and the request does not set include_expired=true (Document not found, with the identifier in details.id).