Skip to Content

Invoices API

Create, retrieve, and manage invoices through the Invoices API.

List Invoices

Retrieve all invoices for your organization.

curl https://api.lawnledgercrm.com/api/invoices \ -b cookies.txt

Response:

{ "data": [ { "id": "clx8n2k1p0009wxyz", "invoiceNumber": "INV-0042", "customerId": "clx8n2k1p0001abcd", "status": "sent", "subtotal": 350.00, "tax": 28.00, "total": 378.00, "amountPaid": 0, "balance": 378.00, "invoiceDate": "2025-06-01", "dueDate": "2025-06-15", "createdAt": "2025-06-01T09:00:00Z" } ] }

Query Parameters

ParameterTypeDescription
statusstringFilter by status: draft, sent, paid, overdue, void
customerIdstringFilter by customer ID
startDatestringStart of the issue-date range. A date-only value (2026-06-01) means that whole calendar day, read on your organization’s timezone. Also accepted as dateFrom.
endDatestringEnd of the range, inclusive: a date-only value runs through the end of that day. Also accepted as dateTo; if both are sent, endDate wins.
pagenumberPage number
limitnumberResults per page

Example:

curl "https://api.lawnledgercrm.com/api/invoices?status=overdue&limit=25" \ -b cookies.txt

Get Invoice

Retrieve a single invoice by ID.

curl https://api.lawnledgercrm.com/api/invoices/clx8n2k1p0009wxyz \ -b cookies.txt

Create Invoice

Create a new invoice.

curl -X POST https://api.lawnledgercrm.com/api/invoices \ -H "Content-Type: application/json" \ -b cookies.txt \ -d '{ "customerId": "clx8n2k1p0001abcd", "propertyId": "prop_def456", "invoiceDate": "2025-06-15", "dueDate": "2025-07-15", "lineItems": [ { "description": "Weekly Lawn Mowing", "quantity": 4, "unitPrice": 75.00 }, { "description": "Edge trimming", "quantity": 4, "unitPrice": 25.00 } ], "notes": "Thank you for your business!" }'

Required Fields

FieldTypeDescription
customerIdstringCustomer ID
lineItemsarrayAt least one line item

Line Item Fields

FieldTypeDescription
descriptionstringService or item description
quantitynumberQuantity
unitPricenumberPrice per unit

Update Invoice

Update an existing invoice. Only draft invoices can be fully edited.

curl -X PUT https://api.lawnledgercrm.com/api/invoices/clx8n2k1p0009wxyz \ -H "Content-Type: application/json" \ -b cookies.txt \ -d '{ "dueDate": "2025-07-30", "notes": "Extended payment terms" }'

Record Payment

Record a payment against an invoice.

curl -X POST https://api.lawnledgercrm.com/api/invoices/clx8n2k1p0009wxyz/payments \ -H "Content-Type: application/json" \ -b cookies.txt \ -d '{ "amount": 378.00, "paymentDate": "2025-06-20", "method": "check" }'

The payment is recorded against the invoice in the URL. There is no POST /api/payments - /api/payments handles Stripe payment intents, refunds and reconciliation, not manual entry.

When a payment covers the full invoice balance, the invoice status automatically changes to Paid.

Last updated on