Update an Invoice
Scopes: invoice:update
OAuth2ClientCredentialsBearer invoice:updateAuthorizationBearer <token>Scope: invoice:update
invoice_id*Invoice IdThe id of the invoice
inv_stringbusiness_id*Business IdThe id of the business
biz_stringx-user-id?|Optional external entity identifier that performed the action
application/json- body
number?|The new number of the invoice
status?|The new status of the invoice
line_changes?|The changes to the lines of the invoice
tags?|Inline tag input to merge into the invoice's tags. Each key is a tag field name that must already exist. A string upserts a single value and replaces all current values for that field. A list of {value, amount} objects replaces all current values for the field with the supplied set. A null (or empty list) removes all of the invoice's values for that field. Fields not mentioned are left untouched. Per-field amounts follow the default rules (single value -> invoice total; N values without amounts -> invoice total / N; mixed is rejected) and the per-field sum must not exceed the invoice total.
Successful Response
application/json- response
data*curl -X PATCH 'https://api.sandbox.getasset.com/v0/business/biz_GA6EG2qFxA97NZHtxeLPUy/invoice/inv_WQMDNUHpBThYSNh4AprDBo' \ -H 'Content-Type: application/json' \ -d '{}'{ "data": { "business_id": "biz_Pk2fNFDd8wj7EFeLWJywc7", "external_id": "inv-2025-01-15-001", "number": "INV-1234567890", "description": "Invoice from Acme Corp", "total_amount": 520.56, "total_paid": 520.56, "source": "manual", "due_at": "2019-08-24T14:15:22Z", "sent_at": "2019-08-24T14:15:22Z", "voided_at": "2019-08-24T14:15:22Z", "status": "paid", "metadata": {}, "id": "inv_GkBo16N66u2teKfFuFMMwf", "lines": [ { "description": "Web development services", "ledger_id": "ldg_ErisumsAc7qgmbTctM7zKK", "amount": 520.56, "metadata": {}, "id": "inl_GkBo16N66u2teKfFuFMMwf", "invoice_id": "inv_WQMDNUHpBThYSNh4AprDBo" } ], "payments": [ { "invoice_id": "inv_GkBo16N66u2teKfFuFMMwf", "transaction_id": "txn_WQMDNUHpBThYSNh4AprDBo", "credit_journal_entry_id": "0ec1143c-fe29-4ebb-b104-371042e6ce1d", "credit_cash_journal_entry_id": "dd3ccf56-811f-41ac-87f8-fa1d01c62729", "credit_memo_id": "3bc646ad-505a-4b36-92e4-42b2df5314e8", "payment_id": "inp_ErisumsAc7qgmbTctM7zKK", "datetime": "2021-01-01T00:00:00Z", "payment_amount": 520.56, "id": "inp_WQMDNUHpBThYSNh4AprDBo", "invoice": {}, "is_write_off": false } ], "customer_id": "cus_WxcM3ypJ5boFxsNQzcqRXe", "currency": "CAD", "tags": { "Job": [ { "amount": "3000.00", "value": "Maple Street Remodel" }, { "amount": "1500.00", "value": "Downtown Office Rewire" } ] } }}