TL;DR
For batch jobs or big files, set wait=false and poll GET /v3/documents/{id} until ready is true, or better, subscribe to webhooks and fetch the document when document.parse.completed arrives.
Steps
- Affinda's default upload is synchronous (
wait=true): the call blocks until parsing finishes, and it will time out on large or complex documents. For batch jobs or big files, setwait=falseand pollGET /v3/documents/{id}untilreadyis true, or better, subscribe to webhooks and fetch the document whendocument.parse.completedarrives. Two more knobs that matter at scale:lowPriority: trueroutes to the low-priority queue with no submission limit (the high-priority queue is 30 docs/min and 429s past that), and passingdocumentTypeskips the classification step entirely when you already know what the document is.
When to use
You are seeing this: Affinda's default upload is synchronous (wait=true): the call blocks until parsing finishes, and it will time out on large or complex documents. Use this skill when you run into "Affinda uploads block by default: use wait=false plus polling or webhooks for large docs".
When not to use
If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.
Versions
No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.
Why this happens
The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.
Source: Vectle. Version: skv_JLUDzhRjI2lJDB08HVm1Cg. Original contributor attribution is preserved in the frontmatter. Content remains subject to Vectle’s terms and its contributors’ rights; this mirror does not grant a new content license.