v1

latestOpenAPI 3.0.12026-07-24310590875.6 KB
invoices

Restore an archived invoice

Restore an archived invoice. In the response, the archived field is set as false.

You can perform any valid BILL operation on restored invoices. There is no change when you restore a restored invoice.

post/v3/invoices/{invoiceId}/restore

Path parameters

invoiceIdstring required

BILL-generated ID of the invoice. The value begins with 00e.

Example:{{invoice_id}}

Headers

sessionIdstring nullable

API session ID generated with /v3/login

Example:{{session_id}}
devKeystring nullable

Developer key generated with your BILL developer account

Example:{{developer_key}}

Response

Restore an archived invoice response

idstring

BILL-generated ID of the invoice. The value begins with 00e.

archivedboolean

Set as true if the invoice is archived

recordStatus'ACTIVE' | 'INACTIVE' | 'DRAFT' | 'UNDEFINED'

Invoice record status.

When recordStatus is ACTIVE, archived is set as false. For any other recordStatus value, archived is set as true.

invoiceNumberstring

User-generated invoice number. This value can be your chosen number scheme.

If you do not set this field, invoiceNumber is auto-generated.

invoiceDatestring date

Invoice creation date. This value is in the yyyy-MM-dd format.

If you do not set this field, invoiceDate is set as the date when the invoice is created.

dueDatestring date

Invoice due date. The value is in the yyyy-MM-dd format.

If you do not set this field, dueDate is set as the date when the invoice is created.

paymentTermIdstring
customerIdstring

BILL-generated ID of the customer. The value begins with 0cu.

totalAmountnumber

Invoice total amount

dueAmountnumber

Invoice due amount. The value is calculated by subtracting any applied credits (creditAmount), scheduled payment (scheduledAmount), and cleared payment from totalAmount.

scheduledAmountnumber

Invoice scheduled amount. The value is set as the customer payment amount that is pending clearance.

creditAmountnumber

Credit amount applied to the invoice.

When a credit amount is applied to an invoice, the invoice status is set as PARTIAL_PAYMENT or PAID_IN_FULL depending on the invoice totalAmount.

status'PAID_IN_FULL' | 'OPEN' | 'PARTIAL_PAYMENT' | 'SCHEDULED' | 'UNDEFINED'

Invoice status.

exchangeRatenumber

Invoice exchange rate

createdBystring

BILL-generated ID of the user that created the invoice. The value begins with 006.

createdTimestring date-time

Invoice created time

updatedTimestring date-time

Invoice updated time

payToChartOfAccountIdstring

BILL-generated ID of the chart of accounts for the invoice payment. The value begins with 0ca.

salesTaxItemIdstring

BILL-generated ID of the SALES_TAX item. The value begins with 0ii. The tax rate is applied to all the invoice line items set as taxable.

salesTaxTotalnumber

Invoice sales tax amount. The value is set based on salesTaxItemId.

salesTaxPercentagenumber

Invoice sales tax percentage. The value is set based on salesTaxItemId.

enableCardPaymentboolean

Set as true if the card payment option is enabled for the invoice

invoicePdfIdstring

BILL-generated ID of the invoice PDF. The value begins with att.

The invoice PDF is sent as an email attachment when you send an invoice to a customer. The invoice PDF also appears when the customer clicks the invoice payment link to complete the invoice payment.