Payments

Payment objects describe invoices, credit notes (credit memos), charges and credit allocations. They might contain information about any external links the invoice has.

You can retrieve individual invoices/credit notes as well as query all the items.

Here is the list of all properties the payment object has:

Payment

PropertyTypeRequiredDescription
numberstringtrueThe document number for the invoice / credit memo.
documentTypeenumfalseThe type of the document. It could be either invoice or creditNote. If omitted, invoice is assumed.
datedatetrueThe issue date of the document.
dueDatedatetrueThe due date of the document.
teamidfalseA reference to the company the invoice is issued for.
memberidfalseA reference to the member or individual the invoice is issued for.
officeidtrueA reference to the location the invoiced is issued by.
referencestringfalseAdditional data describing the invoice. It could be any string value.
taxTypeenumtrueThe type of the tax calculation for the invoice. It could be excluded, included or noTax.
allocationsarrayreadonlyA list of credit allocations. Each allocation has amount and target.
invoiceLinesarrayreadonlyA list of invoice line items.
vatAmountsarrayreadonlyA list of invoice vat amounts.
subtotalnumberreadonlyThe total of the invoice / credit note before tax.
amountnumberreadonlyThe total of the invoice / credit note after tax and discount.
payableAmountnumberreadonlyTotal amount due for this invoice. Voided and paid invoices has payableAmount of 0.
createdAtdatereadonlyThe date when the payment has been created at.
createdByidreadonlyThe user that created the payment.
modifiedAtdatereadonlyThe date when the payment has been modified for the last time. Before the first modification, this field equals to the createdAt field. Note that adding/removing charges and credit allocations are considered modifications to both the invoice and the credit note/overpayment.
modifiedByidreadonlyThe user that did the last modification to the payment. Before the first modification, this field equals to the createdBy field.

Credit Allocation

PropertyTypeRequiredDescription
targetidtrueIf payment is an invoice, a reference to the credit note, sourcing the credit. If payment is a credit note, a reference to the invoice the credit is allocated to.
amountnumbertrueThe allocated amount.

Line Item

PropertyTypeRequiredDescription
descriptionstringtrueDescription of the line item.
accountidtrueA reference to the account the line item is allocated to.
vatPercentnumbertrueThe tax percent applied to the line item.
vatAmountnumbertrueThe tax amount applied to the line item.
quantitynumbertrueThe quantity of items described by the line item.
unitPricenumbertrueThe unit price as described in the system.
discountAmountnumbertrueThe calculated discount amount based on the discount set in the invoice.
baseUnitPricenumbertrueThe calculated unit price without tax.
baseTotalnumbertrueThe total without tax.
totalnumbertrueThe total for the line item (including tax).

Vat Amount

PropertyTypeRequiredDescription
percentnumbertrueThe tax percent for the group.
totalnumbertrueThe tax total for the group.
taxRateidtrueA reference to the taxRate the group is for.