Update Invoice
update an invoice
Authentication
X-Auth-Tokenstring
### Authentication header
| Header | Argument | Description |
|:-------|:---------|:------------|
| `X-Auth-Token` | `access_token` | For more about API accounts that generate `access_token`s, see our [Guide to API Accounts](/developer/docs/overview/api-accounts). |
### Further reading
For example requests and more information about authenticating BigCommerce APIs, see [Authentication and Example Requests](/developer/docs/overview/api-accounts#x-auth-token-header-example-requests).
For more about BigCommerce OAuth scopes, see our [Guide to API Accounts](/developer/docs/overview/api-accounts#oauth-scopes).
For a list of API status codes, see [API Status Codes](/developer/api-reference/rest/overview#rest-http-status-codes).
X-Store-Hashstring
### Authentication header
| Header | Argument | Description |
|:-------|:---------|:------------|
| `X-Store-Hash` | `store_hash` | The unique store hash associated with a BigCommerce store that has B2B Edition enabled. |
Path parameters
invoiceId
Request
customerId
B2B Edition Company ID
externalCustomerId
Ext Customer ID
externalId
Ext Invoice ID
invoiceNumber
Invoice Number, must be unique
type
dueDate
Invoice due date
status
invoice status, noted status will be auto set to 2 when open balance is <= 0
purchaseOrderNumber
PO Number
details
Details that will show on the invoice. When updating this field, the new value will completely replace the existing details. To preserve existing details while making updates, retrieve the current details first, and make your edits to that object before submitting the changes.
source
Mark the source of the invoice, 0 for B2B Edition, 1 for external.
originalBalance
Invoice original balance
openBalance
Invoice balance awaiting for payment
createdAt
externalPdfUrl
The URL of an externally hosted PDF file to be associated with this invoice. The file size must not exceed 5 MB. Ensure that the file hosting service supports Cross-Origin Resource Sharing (CORS) to allow our system to access the file. To remove an existing PDF link, use an empty string.
extraFields
Response
OK
code
data
meta