upload_document_version
Upload a new file version to an existing document, making it the current version while earlier versions remain available. Use for corrected scans, signed copies, or unlocked PDFs.
Instructions
Add a new file version to an EXISTING document instead of creating a new document — e.g. a corrected scan, a signed copy, or an unlocked PDF. The new file becomes the current version: content, search and downloads follow it, and earlier versions stay listed in the document's versions (see get_document). Processing is asynchronous like post_document; set poll=true to wait. To strip a PDF password you don't need to re-upload: use edit_documents_bulk method remove_password with update_document=true.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | The document to add the version to | |
| file | Yes | Base64-encoded file content (the universal method — works for any deployment, since the bytes travel over the wire). Alternatively, an absolute file path (e.g. /tmp/invoice.pdf) that the server reads from its OWN filesystem — this only works when the server runs on the same machine as the file (local/stdio deployments). For a remote server, the path option will fail; use base64 instead. | |
| poll | No | Wait for processing to finish (default false) | |
| filename | Yes | Filename including extension, e.g. 'contract-signed.pdf' | |
| version_label | No | Short label shown in the versions list, e.g. 'signed' | |
| poll_timeout_seconds | No | Max seconds to wait when poll=true (default 30) |