Reseller Usage Metering API
For platforms reselling Orbit to their own customers — agencies, MSPs, vertical SaaS. Send a batch of your end customers’ usage events with a custom meter definition, and get back a rated, per-subaccount rollup plus the wallet-ledger and invoice draft you would bill each subaccount with. This is a programmatic partner endpoint: you already hold your end customers’ usage events in your own system, so you POST them here and get the rated result back. It is stateless — nothing is persisted and no wallet or invoice is charged. Use it to rate a billing period, preview the numbers, and (optionally) render the branded invoice you hand your customer. Base path:/api/v1/usage/meters
Authentication: Organization session JWT or an owner/admin API key. You only ever rate your own payload.
Rate a batch
Rollup usage events
POST /api/v1/usage/meters/rollup
Rate a batch of metered events against a custom meter and return the rollup. Each event names the subaccount that incurred it and a quantity; the meter defines the included quantity and the graduated overage tiers used to price the overflow.
Meter definition
Request body
Invoice metadata
Supply the optionalinvoice block to also receive a branded, standalone HTML invoice (billing.invoice.rendered_html) for the marked-up draft — the document you hand your end customer.
All amounts are in minor currency units (cents). The
billing block is a preview of the write descriptors — the wallet-ledger debits and the invoice draft you would charge each subaccount with. This endpoint does not commit them; persisting the ledger and invoice writes is a separate step in your own billing flow.Issue a credit note
Credit a prior charge
POST /api/v1/usage/meters/credit-note
Issue a credit note (credit memo) or a manual invoice adjustment against a charge you already billed a downstream customer. A credit note reduces what the customer owes on their invoice — use it for an overbilled line, a goodwill credit, a negotiated discount, or a billing-error correction. Unlike a Stripe refund it moves no money on a card; it produces the finance document you hand your customer.
Like the rollup endpoint it is stateless — nothing is persisted. It returns the credited totals and, when you supply a credit_note block, a branded, standalone HTML credit note (credit_note.rendered_html).
Request body
Credit-note metadata
Amounts are in minor currency units (cents), and the totals are the credited (owed-back) figures. This endpoint does not persist the credit note or apply it to a wallet — record it and apply it against the invoice in your own billing flow.