attach_file_to_document
Attach a base64-encoded file to a Holded document by specifying document type, ID, and filename, so invoices and related records can include supporting files.
Instructions
Attach a file to a document (Holded API v2). POST ${docBase}/{id}/attachments multipart. Supported for all docTypes except purchaserefund (v2 has no purchase-refund CRUD beyond creation).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"docType": "<docType>",
"documentId": "<documentId>",
"fileBase64": "<fileBase64>",
"filename": "<filename>"
},
"name": "attach_file_to_document"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| docType | Yes | Type of document | |
| filename | Yes | Name of the file | |
| documentId | Yes | Document ID | |
| fileBase64 | Yes | File content as base64 encoded string |