← Field notes

Billing

Read the usage ledger after an API request

Understand the difference between an estimate, a settled charge and a reservation still awaiting usage.

Before a completion runs

The gateway reserves an estimated maximum charge from your balance and applicable key budget. That reservation is based on request size and the maximum output tokens allowed for the request.

After the provider responds

A complete request settles against provider-reported usage. For a provider rejection classified as failed, the reservation can be released. Timeouts or missing usage can leave a reservation awaiting reconciliation.

Before sending it again

Check the latest usage entry and its status. A transport timeout alone cannot tell you whether a completion ran upstream. Include the approximate time and model ID if you need help reconciling an entry.

Errors and recovery ↗