Copy invoice
copy_invoiceCopies a document of a company (its customer, items, bank account and texts) to a new invoice draft dated today, or to a new open proforma (e.g. "the same as last month"). An invoice draft gets no number and nothing is issued or sent; a proforma is numbered at once. A proforma is always copied to a proforma.
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": {
"company_id": "<company_id>",
"invoice_id": "<invoice_id>"
},
"name": "copy_invoice"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| proforma | No | true: copy to an open proforma; otherwise an invoice is copied to an invoice draft. | |
| company_id | Yes | The id of the company, from list_companies. | |
| invoice_id | Yes | The id of the document to copy, from list_invoices. |