Invoices
Find all Invoices
Retrieve a paginated list of Invoices
get/invoices
Query parameters
sortDirection'ASC' | 'DESC' | 'asc' | 'desc'
Sort direction. Defaults to ASC.
sortBy'id' | 'createdAt' | 'updatedAt' | 'status'
Field to sort by. Defaults to createdAt.
pagenumber
Page number for offset pagination. Defaults to 1.
pageSizenumber
Number of items per page for offset pagination. Defaults to 10.
limitnumber
Opts into cursor pagination and sets the page size. When provided, "page"/"pageSize" are ignored and the response returns a "nextCursor" instead of a total count.
cursorstring
Opaque cursor from a previous cursor-paginated response. Used together with "limit" to fetch the next page.
Response
OK
Example response
{
"pagination": {
"mode": "offset",
"pageSize": 10,
"hasPreviousPage": true,
"page": 2,
"itemCount": 11,
"pageCount": 2
},
"data": [
{
"createdAt": "2024-02-18T12:00:00Z",
"updatedAt": "2024-02-21T12:15:00Z",
"metadata": {
"key1": "value1",
"key2": "value2"
},
"status": "open",
"voidedReason": "Grace period expired",
"comment": "This is a comment for the invoice",
"amount": 999,
"currency": "usd",
"type": "setup",
"number": "2W12-1004",
"customer": {
"createdAt": "2024-02-18T12:00:00Z",
"updatedAt": "2024-02-21T12:15:00Z",
"metadata": {
"key1": "value1",
"key2": "value2"
},
"id": "cus_2QC7PqoUeOxQEWscJJt6B3PkvyL",
"email": "user@gmail.com",
"name": "John Doe",
"phoneNumber": "+1234567890",
"dateOfBirth": "2020-01-01",
"gender": "male",
"restrictReason": "Customer restricted due to suspicious activity",
"isRestricted": true
}
}
]
}Changes
No recorded changes to this endpoint across all 1 revision of this API.