v1

latestOpenAPI 3.0.3Apache 2.02026-07-13121230447.8 KB
Invoices

Update an invoice

Update an invoice[Only CUSTOM invoices in DRAFT state support updating of all fields]. Updating status can be done for all invoice.

patch/invoices/{invoice_id}

Path parameters

invoice_idstring required
Example:ACC001

Request body

startDatestring date-time
endDatestring date-time
status'DUE' | 'PAID' | 'VOID' | 'UN_COLLECTIBLE' | 'REFUND_INITIATED'

Status of invoice

autoAdvanceboolean

This property defines the behaviour of status updates of invoices like: Enabling this property to true auto updates the status of invoice to DUE or PAID accordingly But disabling this property of left null does not auto update the custom status

Example request

{
  "startDate": "2020-06-04T12:00:00.000Z",
  "endDate": "2020-07-04T12:00:00.000Z",
  "status": "DUE"
}

Response

Response for Get invoice requests

idstring required

Identifier of invoice

customerIdstring
ownerIdstring
pricePlanIdstring
status'DRAFT' | 'DUE' | 'PAID' | 'VOID' | 'UN_COLLECTIBLE' | 'REFUND_INITIATED' | 'REFUND_COMPLETED' | 'MERGED' | 'PARTIALLY_PAID' required

Status of the invoice

finalizingStatus'FINALIZING' | 'FINALIZED'
invoiceClass'INVOICE' | 'ORDER' | 'BILLABLE' required

Represents the class of entity( INVOICE/ORDER/BILLABLE)

invoiceType'STANDARD' | 'AD_HOC' | 'CUSTOM' | 'COMPOSITE' | 'STANDARD_ADVANCED' | 'ADHOC_ADVANCED' required

Represents the type of entity(STANDARD/AD_HOC/COMPOSITE)

autoAdvanceboolean
startDatestring date-time

Start date of the invoice

endDatestring date-time

End date of the invoice

endDateInclusivestring date-time

Inclusive end date of the invoice

invoiceDatestring date-time required

Invoice date of the invoice

dueDatestring date-time

Due date of the invoice

generatedAtstring date-time
updatedAtstring date-time required
metadataobject
sequenceIdstring

Sequence id of the invoice

pdfUrlstring

Download URL of the pdf file corresponding to the invoice

totalAmountnumber required
paidAmountnumber required
netTermDaysinteger required

Number of days from the invoice date after which an invoice is considered overdue.

Example response

{
  "autoAdvance": true,
  "startDate": "2020-07-04T12:00:00.000Z",
  "endDate": "2020-07-04T12:00:00.000Z",
  "endDateInclusive": "2020-07-03T11:59:59.999Z",
  "invoiceDate": "2020-07-04T12:00:00.000Z",
  "dueDate": "2020-07-04T12:00:00.000Z"
}