Invoices

Invoices represent a receivable — an amount already known, owed by a specific customer. Use this when you need line items, taxes, discounts, or payment terms rather than a simple one-off charge.


Endpoints

MethodPathPurpose
POST/organization/invoicesCreate an invoice
GET/organization/invoicesList invoices
GET/organization/invoices/:idGet invoice details
PATCH/organization/invoices/:idUpdate a draft invoice
POST/organization/invoices/:id/sendSend an invoice to the customer
DELETE/organization/invoices/:idDelete a draft invoice
GET/public/invoices/:numberResolve invoice details publicly
POST/public/invoices/:number/sessionCreate a checkout session for the invoice

Create an invoice

curl --request POST \
  --url $baseUrl/organization/invoices \
  --header 'x-api-key: YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
    "customerId": "customer-uuid",
    "number": "INV-001",
    "issueDate": "2026-04-24T00:00:00.000Z",
    "dueDate": "2026-05-24T00:00:00.000Z",
    "currency": "USD",
    "items": [
      { "description": "Web Design", "quantity": 2, "unitPrice": 500 }
    ],
    "taxRate": 8.25,
    "taxName": "Sales Tax",
    "settlementAccountId": "wallet-uuid",
    "paymentMethods": ["bank_transfer", "crypto"],
    "sendNow": false
  }'
FieldRequiredDescription
customerIdYesMust reference an existing customer
numberYesInvoice number
issueDate, dueDateYes
currencyYes
itemsYesArray of { description, quantity, unitPrice }
settlementAccountIdYesWallet the payment lands in
paymentMethodsYese.g. ["bank_transfer", "crypto"]
taxRate, taxNameNo
discountValue, discountTypeNodiscountType: PERCENTAGE or fixed
allowPartialPaymentNo
sendNowNoIf true, transitions to SENT immediately and emails the customer
scheduledAtNoSchedule the send for later instead

Response:

{
  "success": true,
  "statusCode": 201,
  "message": "Invoice created successfully",
  "data": {
    "id": "inv_abc123",
    "invoiceNumber": "INV-0001",
    "customerId": "cus_abc123",
    "total": 150000,
    "currency": "NGN",
    "status": "DRAFT",
    "dueDate": "2026-02-01T00:00:00Z",
    "createdAt": "2026-01-01T00:00:00Z"
  }
}

Best practices

  • Create the invoice first as a DRAFT, then send it once ready
  • Only DRAFT invoices can be updated or deleted
  • Use the invoice number as your customer-facing reference
  • Only create a checkout session when the customer is actually ready to pay

Call this next

  • Send the invoice via the send endpoint
  • Customer opens /public/invoices/:number and creates a session to pay


Did this page help you?