Skip to main content
GET
Fetch invoice status summary

Authorizations

X-API-KEY
string
header
required

API Key Authentication.

Query Parameters

Free-text search over the invoice number, the customer name and the names of the customers whose usage the invoice bills, such as the subsidiaries of an organization.

customerIds[]
string<uuid>[]

Only return invoices billing these customers.

status[]
enum<string>[]

Only return invoices in these statuses. Canceled invoices are controlled by includeCanceled, not by this filter.

Available options:
open,
in_review,
issued,
synced,
pending,
paid,
overdue,
canceled,
failed
includeCanceled
boolean
default:false

When false, canceled invoices are excluded. When true, canceled invoices are added to the statuses selected in status[]; if no status[] is provided, only canceled invoices are returned.

hideZeroAmount
boolean
default:false

When true, invoices with a zero total amount are excluded.

invoiceDate.gte
string<date>

Only return invoices whose invoice date is on or after this date.

invoiceDate.lte
string<date>

Only return invoices whose invoice date is on or before this date.

contractIds[]
string<uuid>[]

Only return the invoices of these contracts.

productIds[]
string<uuid>[]

Only return the invoices with at least one line item of these products.

paymentAccountIds[]
string<uuid>[]

Only return the invoices that bill these payment accounts.

Only return the invoices of these legal entities: an invoice of a contract when its contract names one of them, and an invoice without a contract, such as a one-off invoice, when one of them is the default legal entity of the tenant.

customField
object

Only return the invoices whose records hold these custom field values, keyed by the record and then by the key of the custom field, as in customField[contract][region][]=south. An invoice matches a key when the record holds one of its values, and it matches the filter when it matches every key.

Response

The number of the invoices that match the filters and the sum of their total amounts, for each invoice status and in total.

byStatus
object[]
required

One item for each invoice status that the settings of the tenant list, in their order, with zeros for a status that no selected invoice holds.

totalCount
number
required

The number of selected invoices across the statuses of byStatus.

totalAmount
number
required

The sum of the total amounts of the selected invoices across the statuses of byStatus, in cents.