This endpoint returns a rendered PDF preview for a specified document.
The accept
request header MUST be set to application/pdf
. Other values will
give an HTTP 406 error.
This endpoint is optimized for in-browser previews. We reserve the right to adjust the quality and other attributes of the output with this in mind. Please reach out to us if you have a different use case and requirements.
Previews will be rendered if neccessary during the request. Be prepared for the request to take a few seconds to complete.
OK
The response for a failed request.
The response for a failed request.
The response for a failed request.
The response for a failed request.
client.documents.previews.download_document_as_pdf("previews", id=123) content = client.documents.previews.download_document_as_pdf_bytes(id=123)
{- "error": {
- "code": 401,
- "message": "Could not authenticate.",
- "missing": [
- { }
], - "duplicated": [
- { }
]
}
}