Skip to content
Core resources

Invoices

Create an invoice as a draft, issue it (assign a number, go live), or issue and email the client a pay link — all from one call.

Create an invoice#

POST/v1/invoices
FieldTypeDescription
clientIdreqstringId of an active client in your workspace.
action"draft" | "issue" | "send"What to do on create. Defaults to issue. See below.
dueDatereqstringWhen payment is due (ISO-8601).
lineItemsreqLineItem[]At least one line. Each: description, quantity, rateCents, taxRate?
issuedAtstringOverride the issue date (ISO-8601).
currencystring3-letter code; defaults to USD.
notesstringClient-facing note shown on the invoice.
internalNotesstringPrivate note, not shown to the client.
feesWaivedbooleanWaive the payment fee on this invoice.
matterIdstringLegal module: bill under a matter (must belong to the client).
action controls the lifecycle: draft saves it without a number or email; issue (default) assigns a number and makes it live; send also emails the client a pay link. send requires the client to have an email with consent on file, otherwise it returns 422 validation_failed.

Line item shape:

FieldTypeDescription
descriptionreqstringLine description.
quantityreqnumberPositive quantity.
rateCentsreqintegerPer-unit price in cents (1250 = $12.50).
taxRatenumberDecimal rate, e.g. 0.0825 for 8.25%. Defaults to 0.
Request
curl https://kurepay.com/api/v1/invoices \
  -H "Authorization: Bearer ak_live_your_key" \
  -H "Content-Type: application/json" \
  -d '{
    "clientId": "66f1a2b3c4d5e6f7a8b9c0d1",
    "action": "issue",
    "dueDate": "2026-07-01",
    "lineItems": [
      { "description": "Design retainer", "quantity": 1, "rateCents": 250000 },
      { "description": "Hosting", "quantity": 12, "rateCents": 1500, "taxRate": 0.0825 }
    ]
  }'
201 Created
{
  "object": "invoice",
  "id": "66f2b3c4d5e6f7a8b9c0d1e2",
  "number": "INV-0042",
  "status": "open",
  "clientId": "66f1a2b3c4d5e6f7a8b9c0d1",
  "currency": "USD",
  "lineItems": [
    { "description": "Design retainer", "quantity": 1, "rateCents": 250000, "taxRate": 0, "lineSubtotalCents": 250000, "lineTaxCents": 0 }
  ],
  "subtotalCents": 268000,
  "taxTotalCents": 1485,
  "totalCents": 269485,
  "balanceCents": 269485,
  "paidCents": 0,
  "dueDate": "2026-07-01T00:00:00.000Z",
  "issuedAt": "2026-06-09T17:04:21.000Z",
  "sentAt": null,
  "publicPayUrl": "https://acme.collect.com/pay/invoice/iv_8f2a…",
  "createdAt": "2026-06-09T17:04:21.000Z",
  "updatedAt": "2026-06-09T17:04:21.000Z"
}

The invoice object#

Amounts are integer cents. number and publicPayUrl are null for drafts and populated once issued. balanceCents is what remains due (totalCents + interest − paidCents − write-offs). Each line carries computed lineSubtotalCents and lineTaxCents.

Retrieve an invoice#

GET/v1/invoices/{id}
curl https://kurepay.com/api/v1/invoices/66f2b3c4d5e6f7a8b9c0d1e2 \
  -H "Authorization: Bearer ak_live_your_key"

List invoices#

GET/v1/invoices

Cursor-paginated, newest first. Query params: limit (1–100, default 25), startingAfter (an id), status (draft, open, partially_paid, paid, overdue, void), and clientId to filter to one client.

curl "https://kurepay.com/api/v1/invoices?status=open&clientId=66f1a2b3c4d5e6f7a8b9c0d1" \
  -H "Authorization: Bearer ak_live_your_key"