fetch_invoices
Fetch a paginated list of invoices for the account, with optional filters by status and date range. Requires the Invoices module enabled on the account — on a 403 "module is not enabled" error, do NOT retry; tell the user to contact Sweeppea support. The Summary block (totals and counts) covers the ENTIRE filtered set, not just the current page. IsOverdue is derived at read time (stored status stays "pending"). Archived invoices are included with Archived: true. For full details of one invoice (line items, notes, QR) use get_invoice. DISPLAY RULE: never show InvoiceToken/PublicToken UUIDs — present InvoiceNumber, recipient, dates, totals and status instead.
fetch_invoices
When to use
Fetch a paginated list of invoices for the account, with optional filters by status and date range. Requires the Invoices module enabled on the account — on a 403 "module is not enabled" error, do NOT retry; tell the user to contact Sweeppea support. The Summary block (totals and counts) covers the ENTIRE filtered set, not just the current page. IsOverdue is derived at read time (stored status stays "pending"). Archived invoices are included with Archived: true. For full details of one invoice (line items, notes, QR) use get_invoice. DISPLAY RULE: never show InvoiceToken/PublicToken UUIDs — present InvoiceNumber, recipient, dates, totals and status instead.
Parameters to validate before calling
status(string, optional) — one of:draft,pending,paid,cancelled— Filter by invoice status (optional)from_date(string, optional) — Inclusive start date in ISO format YYYY-MM-DD (optional)to_date(string, optional) — Inclusive end date in ISO format YYYY-MM-DD (optional)page(number, optional) — range: 1–+∞ — Page number (optional, default 1)limit(number, optional) — range: 1–200 — Results per page (optional, default 50, max 200)
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| page | No | Page number (optional, default 1) | |
| limit | No | Results per page (optional, default 50, max 200) | |
| status | No | Filter by invoice status (optional) | |
| to_date | No | Inclusive end date in ISO format YYYY-MM-DD (optional) | |
| from_date | No | Inclusive start date in ISO format YYYY-MM-DD (optional) |