Invoices
Invoices let you send professional billing documents to customers. Each invoice includes a payment link, optional line items, and due date tracking. When the customer pays, the invoice status updates automatically.Create an Invoice
Email address of the invoice recipient.
Customer name displayed on the invoice.
Total invoice amount.
Token to accept:
USDC, USDT, SOL.Invoice description or memo.
Itemized breakdown of the invoice.Each item has:
description(string, required): Item descriptionquantity(number, required): Quantityunit_price(number, required): Price per unit
ISO 8601 date when payment is due.
Arbitrary key-value pairs.
When
true, the payment link generated by Send Invoice will use the PAJ onramp flow (NGN bank transfer → USDC settlement) instead of a direct crypto payment. Ideal for customers who prefer to pay from a Nigerian bank account.Original NGN amount for exact PAJ conversion. Bypasses a live FX re-quote at checkout time. Only relevant when
onramp is true.When
true (and onramp is true), a transparent service charge — max(₦30, ceil(amount_ngn × 2.5%)) — is added on top and billed to the payer rather than absorbed by the merchant.Maximum number of times the generated payment link can be used. Defaults to
1 on send because invoices are targeted at a single customer. Set to a higher value (or omit for unlimited) only if you intentionally want the link reusable.When
true, the checkout page shows an expanded customer-details form (name, phone, company, billing address) before the payment step.Examples
Response
List Invoices
Get an Invoice
Invoice ID (e.g.,
inv_test_abc123).Send an Invoice
draft to sent.
When send is called a payment link is created automatically using the invoice’s settings:
- If
onrampistrueon the invoice, the payment link will use the PAJ onramp flow (NGN bank transfer). max_useson the generated link defaults to1(the invoice’spayment_link_max_usesvalue, or1if not set).mode(test vs live) is inherited from the API key or, for dashboard calls, from the?modequery parameter (default:live).
Dashboard route only (
/api/v1/merchants/me/invoices/:id/send). Pass ?mode=test to generate a devnet payment link instead of a mainnet one.Example
Response
Dashboard Routes
The following routes are available when authenticated via a merchant session (dashboard cookie auth) rather than an API key. They are identical to the API-key routes but scoped under/api/v1/merchants/me/invoices.
| Method | Path | Description |
|---|---|---|
POST | /api/v1/merchants/me/invoices | Create invoice |
GET | /api/v1/merchants/me/invoices | List invoices |
GET | /api/v1/merchants/me/invoices/:id | Get invoice |
POST | /api/v1/merchants/me/invoices/:id/send | Send invoice (?mode=live|test) |
Invoice Status Lifecycle
| Status | Description |
|---|---|
draft | Invoice created but not yet sent |
sent | Invoice emailed to customer; payment link is active |
paid | Customer payment confirmed on-chain |
overdue | Due date passed without payment (auto-updated nightly) |
cancelled | Invoice manually cancelled |
Onramp Invoices — How It Works
When an invoice is created withonramp: true and then sent:
- A payment link is created with
onramp: true,max_uses: 1(or your configured value), and the PAJ metadata (amount_ngn,payer_service_charge). - The payment link URL is included in the invoice email.
- The customer opens the link and sees the Pay with Bank flow — no crypto wallet needed.
- They receive a virtual account number, transfer the NGN amount, and the conversion to USDC is settled to your merchant wallet automatically.
Webhook Events
| Event | When |
|---|---|
InvoiceCreated | Invoice created |
InvoiceSent | Invoice emailed to customer |
InvoicePaid | Invoice payment confirmed |