Skip to Content
Payrudder

Invoices

Read invoices, understand their kinds, lines and status, get them paid, and correct them with credit notes.

An invoice is what a customer owes for a period or an event. Payrudder raises them. You read them (GET /v1/invoices, GET /v1/invoices/{id}), send the customer to pay them, and hear about them by webhook.

An issued invoice is never edited. A correction is a credit note and, where needed, a new invoice.

Kinds

kind is one of:

KindWhat it is
REGULARa billing period's usage and, for a subscription billed in arrears, its fee
FEEa fixed fee invoiced in advance for one period, or what a plan change moved
CORRECTIONa correction of a closed period
LINKmade from an ad-hoc payment link

Lines

Each line has a kind:

LineWhat it is
BASE_FEEthe fixed fee, with the service period it covers (service_from, service_to)
USAGEa meter's quantity for the period, priced by the package version the subscription was on
LATE_USAGEusage that arrived after the period's cutoff and is billed on the next open invoice (Usage metering)
CREDITcredit balance used to pay the invoice (Credits and balances)
CORRECTIONa correction of earlier usage
DISCOUNTa coupon's discount
TAXtax at the account's rate for the customer's country
ITEMone item of a shop's order (a payment link with items), net of VAT; its rate is tax_rate_bps, and the order's TAX lines are one per rate (E-commerce checkout)

Amounts are integers in the currency's minor unit, as strings (total_minor).

The total is never negative. Lines that come to less than zero (late-usage corrections larger than everything else on the invoice) leave the invoice at 0, and the rest becomes credit balance (credit_surplus_minor).

Status

status is one of:

StatusWebhook
draft
openinvoice.finalized when it gets its number
paidinvoice.paid
uncollectibleinvoice.uncollectible
voidinvoice.voided

A number is given when the invoice is finalized: INV-2026-000123 is the year, then a sequence without gaps for each year. A sandbox account's numbers are prefixed SBX-. See Webhooks for the payloads.

An invoice whose payment is declined is retried on a schedule before it is given up: Failed payments and retries.

Getting paid

Credit notes

A credit note (CN-2026-000007) corrects a paid invoice. Its amount goes either:

  • to the customer's credit balance, which pays their next invoices, or
  • back to the card through the provider that took the payment.

The notes of an invoice never add up to more than the invoice. Issue one with POST /v1/invoices/{id}/credit-notes (to the credit balance, or refund_to_card through the provider that took the payment) and read them with GET /v1/credit-notes and GET /v1/credit-notes/{id}, with disposition and, for a refund, refund_state.

Tax is added by the account's configured rates and nothing else; Payrudder is not a tax engine (Tax and e-invoices).

Next steps