API ReferenceInvoices
List all invoices
Returns invoices for the authenticated user. Filter by status or client to narrow results. Results are ordered by creation date descending.
Authorization
apiKey AuthorizationBearer <token>
API key issued from your AgentInvoice account settings.
In: header
Query Parameters
status?string
Filter by invoice status
Value in
"draft" | "finalized" | "sent" | "paid" | "overdue" | "void" | "outstanding"clientId?integer
Filter by client ID
limit?integer
Maximum number of results to return
Default
100Range
1 <= value <= 200offset?integer
Number of results to skip for pagination
Default
0Range
0 <= valueResponse Body
application/json
curl -X GET "https://app.agentinvoice.co/api/invoices"[
{
"id": 101,
"clientId": 42,
"invoiceNumber": "INV-0042",
"status": "draft",
"currency": "USD",
"subtotal": "1500.00",
"taxTotal": "150.00",
"total": "1650.00",
"amountPaid": "0.00",
"notes": "string",
"terms": "string",
"dueDate": "2019-08-24T14:15:22Z",
"issueDate": "2019-08-24T14:15:22Z",
"sentAt": "2019-08-24T14:15:22Z",
"paidAt": "2019-08-24T14:15:22Z",
"publicToken": "string",
"clientName": "string",
"clientEmail": "string",
"stripePaymentLink": "string",
"stripeCheckoutSessionId": "string",
"spiffyPaymentLink": "string",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z"
}
]Get invoice statistics
Returns aggregated invoice statistics including total outstanding, paid this month, and counts by status. Includes period-over-period change metrics.
Mark invoice as paid
Records a manual payment against the invoice. Status changes to 'paid'. Use when payment was collected outside of Stripe (cash, check, bank transfer, etc.).