API reference/Client billing
List client invoices
Try itThe invoices you send your own clients (retail), newest number first. Filter by status, client, site or month.
GET
/api/v1/invoicesAuthentication
An API key as Authorization: Bearer or x-api-key. It needs the invoices:read scope — read client invoices, monthly invoice settings and card autopay.
invoices:readRead onlyMCP tool: list_invoices
Parameters
Named placeholders go in the path; the rest in the query string.
statusstringQuery · optional- One of: draft, sent, paid, void
client_idstringQuery · optional- The client's id.1 to 100 characters
site_idstringQuery · optional- The site's id.1 to 100 characters
periodstringQuery · optionallimitintegerQuery · optional- How many to return (1–100).1 to 100Default
50 cursorstringQuery · optional- next_cursor from the previous page.1 to 100 characters
Response
200 with JSON on success (schema on the right). Errors use the standard envelope.
curl -X GET 'https://websites.workflowcorp.com/api/v1/invoices?status=sent&limit=20' \
-H "Authorization: Bearer $WEBSITEBUDDY_API_KEY"{
"status": "sent",
"limit": 20
}{
"type": "object",
"properties": {
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"number": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"label": {
"type": "string",
"description": "\"INV-1001\"."
},
"status": {
"type": "string",
"enum": [
"draft",
"sent",
"paid",
"void"
]
},
"client_id": {
"type": "string"
},
"client_name": {
"type": "string"
},
"site_id": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
]
},
"site_name": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
]
},
"period": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "YYYY-MM the invoice is for, if any."
},
"lines": {
"type": "array",
"items": {
"type": "object",
"properties": {
"description": {
"type": "string"
},
"quantity": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"unit_cents": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"total_cents": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"description",
"quantity",
"unit_cents",
"total_cents"
],
"additionalProperties": false
}
},
"total_cents": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"currency": {
"type": "string"
},
"issued_at": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
]
},
"due_at": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
]
},
"paid_at": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
]
},
"note": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
]
},
"monthly": {
"type": "boolean",
"description": "Made by the monthly run (one per site per month)."
},
"on_autopay": {
"type": "boolean",
"description": "Charged to the client's card on file — it marks itself paid; mark_invoice_paid is refused."
},
"paid_by_card": {
"type": "boolean"
},
"pay_link": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The client's card payment page, while it waits for payment and cards are on."
},
"emailed_at": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
]
},
"is_sample": {
"type": "boolean"
},
"created_at": {
"type": "string"
},
"updated_at": {
"type": "string"
}
},
"required": [
"id",
"number",
"label",
"status",
"client_id",
"client_name",
"site_id",
"site_name",
"period",
"lines",
"total_cents",
"currency",
"issued_at",
"due_at",
"paid_at",
"note",
"monthly",
"on_autopay",
"paid_by_card",
"pay_link",
"emailed_at",
"is_sample",
"created_at",
"updated_at"
],
"additionalProperties": false
}
},
"has_more": {
"type": "boolean"
},
"next_cursor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
]
}
},
"required": [
"data",
"has_more",
"next_cursor"
],
"additionalProperties": false
}