Errors and Downloads
Error shape, retries, and how files are served.
{ "error": { "code": "DOCUMENT_PREPARING", "message": "This PDF is still being prepared.", "retryAfterMs": 5000 } }Retry
| Response | When to retry |
|---|---|
409 DOCUMENT_PREPARING | After retryAfterMs |
409 AUDIOBOOK_BUILDING | Once the file is ready |
429 | After the Retry-After header, in seconds |
503 | The worker or a voice provider can't be reached. After Retry-After when the response has one |
503 AUDIOBOOK_BUSY | Another request for the same document's audiobooks is still running |
Ownership
IDs and operation streams are checked against the caller. Identical document content does not grant access to another user's uploads, events or audiobooks.
Files
Files are always sent as attachments, with a content type chosen from the file name, so a document cannot run as a page on the instance's origin.
| Storage mode | Documents | Audiobooks |
|---|---|---|
| Proxy | File bytes | File bytes |
| Presigned | 307 to a short-lived URL | 303 to a short-lived URL |
Follow redirects, and keep the resource URL rather than the signed destination. See Object storage.