Billing
6 endpoints under /v1/billing.
Get Credit Balance
/v1/billing/balanceRead the current credit balance.
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Entitlements
/v1/billing/entitlementsRead the org's resolved entitlements (features + numeric limits).
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Invoices
/v1/billing/invoicesList invoices with cursor-based pagination. Returns an empty list, not 404, when the org has no Stripe customer.
Query parameters
limitintegeroptionalstarting_afterstringoptional
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Subscription
/v1/billing/subscriptionRead the org's current subscription (tier, status, period window).
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
List Credit Transactions
/v1/billing/transactionsList credit-transaction history with offset pagination.
Each row carries balance_after, so the running balance can be
reconstructed without another query. transaction_type must be a
TransactionType value; anything else yields an invalid_request
error.
Query parameters
limitintegeroptionaloffsetintegeroptionaltransaction_typestringoptional
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.
Get Usage Summary
/v1/billing/usageRead the usage summary for the current billing period.
Headers
X-Organization-IDstringoptional
Failures return the error envelope; branch on error_code.