Invoices
Create, manage, and track invoices through the API.
Overview
Invoices are the core billing documents in Corebill. They support line items, taxes, discounts, and payment tracking. Invoice numbers are auto-generated using your company's configured prefix.
Create an Invoice
Invoice Numbers
Numbers are generated automatically: {PREFIX}-{YEAR}-{COUNTER}
Example: INV-2026-000001
The prefix is configurable per company (default: INV).
Statuses
| Status | Description |
|---|---|
draft | Initial state, fully editable |
sent | Sent to the customer |
viewed | Customer has viewed the invoice |
in_review | Under review |
partial | Partially paid |
paid | Fully paid |
overdue | Past due date, unpaid |
cancelled | Cancelled |
refunded | Fully or partially refunded |
Calculations
Totals are calculated automatically when creating an invoice with items:
Amounts
All monetary amounts are in the major unit of the currency with 2 decimals (major unit, 2 decimals). $1,234.56 is represented as 1234.56, never as cents (123456).
Send an Invoice
Record a Payment
The invoice status transitions automatically: partial when partially paid, paid when fully paid.
Cancel an Invoice
Refund an Invoice
If amount is omitted, the full paid amount is refunded.
Editing Restrictions
- Draft invoices: All fields can be updated
- Non-draft invoices: Only
notes,payment_terms, andstatuscan be updated
Deleting Invoices
Invoices with status paid cannot be deleted. You must cancel them first.