duplicateInvoice
Duplicate an invoice into a new draft for the same customer and location, with the same lines, quantities and unit prices but without their discounts. Returns the new draft, which can then be edited and issued. An invoice of a subscription cannot be duplicated. Get invoiceId from getInvoices. The route is not idempotent: after a failure or timeout, check the result with the list tool before calling again, or a second record is created. Never invent UUIDs; only use values from prior tool responses.
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": {
"invoiceId": "<invoiceId>"
},
"name": "duplicateInvoice"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| invoiceId | Yes | The id of the invoice. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| invoice | Yes |