Credits and balances

Draft. Written from the repository's documents and code; not yet reviewed by the owner.

Two different things are called credit. They never mix.

A credit balance in money

When an invoice has to be reduced without refunding a card, the amount goes to the customer's credit balance, in the invoice's currency, and pays their next invoices: a credit note (Invoices), the unused part of a fee when a subscription ends with credit_unused=true or moves to a cheaper price, and late-usage corrections that come to more than the invoice. It is applied automatically when the next invoice is finalized, as a CREDIT line. You see it in GET /v1/customers/{external_id}/upcoming-invoice (credit_minor is what the invoice would use, credit_surplus_minor what would be added). Giving money back to a card is a different act: a credit note with refund_to_card (Invoices).

Prepaid credits

Credits are a currency of your own: a customer buys or is given a number of them and your app spends them (generated pages, API calls, anything you count in whole units). They are separate from meters and invoices.

In the console this is Credits: a customer's balance, the packs you sell and the low-balance alert.