
Never lose a cent
Money is exact by construction, so a rounding bug can’t quietly eat your margins. Your books and your customers’ invoices always agree.
Every API call, seat and gigabyte becomes revenue you can count on — metered accurately, priced to the cent and reconciled to the penny, from your first customer to your millionth. And you keep all of it: no revenue cut, no platform to rent, no billing team to hire.


Money is exact by construction, so a rounding bug can’t quietly eat your margins. Your books and your customers’ invoices always agree.

Bill billions of events without ever double-charging someone — even when retries and background workers pile up. Getting bigger stops being a billing risk.

Every charge is recorded so it always balances and can be re-derived years later — the answer ready when finance, an auditor, or a customer asks “why this amount?”

Start on Stripe or Paddle and switch whenever it suits you, with no rewrite. Your billing is never hostage to one vendor’s roadmap or pricing.

Pricing tables, usage meters and checkout drop in with one command and are yours to restyle — no billing team required to go live.

It’s a library you run yourself: no per-transaction cut, no second service to pay for as you grow. The upside stays yours.
Your books balance by construction — so the total is something you can trust, not something you hope is correct.
Record what each customer actually does — every call, seat or gigabyte — without retries or duplicates ever inflating the bill.
Turn that usage into a bill with tiers, overage, trials and proration — exact to the cent, in every currency you sell in.
Settle through your provider and close the period knowing every number ties out to the penny.
import { meter, price, post, accrual } from 'billing-kit';
// idempotent: retries & replays converge, workers never double-bill
await meter(sql, { subject, event: 'api.call', quantity: 1n, key: requestId });
// integer minor units in a bigint — never a float
const amount = price(usage, plan); // Money, exact for any currency
// append-only, balanced at COMMIT by a deferred constraint
await post(sql, accrual(amount, { debit: 'ar', credit: 'revenue' }));Price it however you dream it up — per call, per seat, per tier. Just never wonder whether the total is right.