duplicate-invoice
Copy a sales invoice, in any status, into a new draft in the same company and return the draft with its id. The copy keeps the customer, line items, currency, notes, payment methods and tax-inclusive setting, uses the current customer and company details, and starts with no dates or invoice number. The original is unchanged and nothing is sent. Next set the dates with update-invoice-draft and finalize with submit-invoice. Use create-invoice-draft to start from an empty draft instead.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ID of the invoice to copy, as returned by list-invoices | |
| companyId | Yes | ID of the company that owns the invoice. The copy is always created in that company. |