List invoices

The organization's invoices, newest first, read from the billing provider at the time of the call.

GET/v1/billing/invoices

The organization's invoices, newest first, read from the billing provider at the time of the call. Amounts are the billing provider's, in the currency's minor unit; usage itself stays seconds and bytes (GET /v1/usage). With billing off, or before the billing provider has the organization's customer, the list is empty. The billing provider not answering is upstream.

For people only: a signed-in person's token makes this call. An API key is refused with person_required. The person's role must be one that may read billing.

Request

curl "https://api.pod.mapier.ai/v1/billing/invoices" \
  -H "Authorization: Bearer $POD_PERSON_TOKEN"

Parameters

NameInTypeRequiredWhat it is
limitqueryintegerNo
cursorquerystringNoThe next_cursor of the page before. Valid for 24 hours.

Answer

200. A page of invoices, newest first.

200
{
  "data": [
    {
      "id": "example",
      "number": "example",
      "issued_on": "example",
      "due_on": null,
      "status": "draft",
      "payment_status": "pending",
      "overdue": false,
      "currency": "example",
      "total_cents": 1,
      "file_url": null
    }
  ],
  "next_cursor": null
}
FieldTypeAlwaysWhat it is
dataInvoice[]Yes
next_cursorstring | nullYes

Errors

The refusals this call is known for: invalid, person_required, upstream. Any call can also answer unauthorized, rate_limited, unavailable or internal; the error list says what each means and when to send the call again.

In the SDKs

ClientCall
TypeScriptpod.billing.invoices()
Pythonpod.billing.invoices()