Bulk edit documents
bulk_edit_documentsApply a single operation to many documents in one call, updating metadata, tags, permissions, or PDFs without per-document loops.
Instructions
Apply one operation to many documents at once. Far cheaper than looping update_document, and the only way to add or remove individual tags without replacing the whole tag list. Methods: set_correspondent, set_document_type, set_storage_path, add_tag, remove_tag, modify_tags, modify_custom_fields, set_permissions, reprocess, delete, rotate, merge, split, delete_pages, edit_pdf, remove_password. The destructive methods (delete, delete_pages, split/merge with delete_originals) need explicit user confirmation first.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tag | No | For add_tag / remove_tag. | |
| merge | No | For set_permissions: merge with existing permissions instead of replacing. | |
| owner | No | For set_permissions. | |
| pages | No | For split: page groups such as '[1-2,3-4,5]'. For delete_pages: page numbers such as '[2,3,4]'. | |
| method | Yes | ||
| degrees | No | For rotate: clockwise rotation in degrees. | |
| add_tags | No | For modify_tags. | |
| password | No | For remove_password: the PDF's current password. | |
| documents | Yes | IDs of the documents to act on. Always an explicit list — never an unbounded selection. | |
| remove_tags | No | For modify_tags. | |
| storage_path | No | For set_storage_path. | |
| correspondent | No | For set_correspondent. | |
| document_type | No | For set_document_type. | |
| set_permissions | No | For set_permissions. | |
| delete_originals | No | For merge/split: delete the source documents afterwards. Irreversible. | |
| add_custom_fields | No | For modify_custom_fields: {custom_field_id: value}. | |
| metadata_document_id | No | For merge: which source document's metadata the result inherits. | |
| remove_custom_fields | No | For modify_custom_fields. |