Safeguard Docs
API Platform (Console)

Credits and invoices

How prepaid credit works for the inference API: the credit ledger, credit Safeguard grants, card top-up when it is switched on, and who can add credit.

The inference API is prepaid. Your workspace holds a balance in US dollars, and each request is charged to it when it finishes, at the model's list price with no markup. When the credit runs out, requests are refused until credit is added.

Early access. The inference gateway is deployed but switched off, and Safeguard switches it on per workspace. Card top-up is not switched on yet, so for now Safeguard adds credit for you.

Where to see your credit

Open Usage and scroll to Credits and limits. When a Console error offers Add credit or Open limits, the button leads here.

FigureWhat it means
BalanceYour credit after every charge so far.
ReservedCredit held for requests in flight.
AvailableBalance minus Reserved. New requests draw on this.
Spent this monthWhat requests have cost in the current UTC month, which is shown next to the label. Under it: your workspace's monthly limit and the share used, or No monthly limit.

How a request is charged

  1. Hold. Before the provider is called, the gateway holds the most the request could cost. That is a deliberately high estimate of the input, plus every output token the request allows, at the price of the most expensive model it might use. If the hold does not fit, the request is refused with a 402 and nothing is charged. See Spend controls.
  2. Charge. When the answer is complete, the hold is released and the actual cost is charged: the provider's token counts times the model's list price. The ledger gets a Usage entry.
  3. No answer, no charge. A request that reaches a provider but fails before the provider produces anything costs $0, and appears in the request log with its error code. A request the gateway refuses before calling a provider costs nothing and is not logged.

Costs are worked out to 8 decimal places, so a request that costs a fraction of a cent is charged exactly that.

A hold that is never settled, for example because a request was cut off inside Safeguard, is released after about 30 minutes.

Rarely, a provider reports more input tokens than the gateway estimated. Those tokens were used, so they are charged, and the balance can dip below zero. New requests are then refused until credit is added.

The credit ledger

Credit ledger lists every change to the balance, newest first. Load older entries pages back through all of them. Entries are only ever added, never edited.

ColumnWhat it shows
TimeWhen the entry was recorded.
EntryGrant, Topup or Usage.
AmountPositive for credit added, negative for a charge.
Balance afterThe balance once the entry applied.
NoteThe reason for a grant, or Card top-up for a card payment.
EntryWhat it is
GrantCredit Safeguard added to your workspace.
TopupCredit a tenant admin or super admin bought by card.
UsageOne request's charge. A request that cost $0 has no ledger entry.

Credit granted by Safeguard

While card top-up is off, Safeguard adds credit for you. Contact hi@safeguard.sh to arrange it. Each grant shows in your ledger as a Grant, with the reason Safeguard recorded in the Note column. Safeguard also records which of its staff made the grant.

Card top-up

Card top-up through Stripe is built, but switched off. Once Safeguard switches it on, a tenant admin or super admin buys credit like this:

  1. Open Usage, go to Credits and limits and select Add credit. Everyone else sees "A tenant administrator can add credit." instead of the button.
  2. Enter Credit to add (USD) and select Continue to payment. If the amount is outside the range Safeguard allows, the Console says what the range is.
  3. Pay on Stripe's checkout page. For $25 of credit, the line item reads Safeguard API credit ($25.00, includes $1.06 card processing).
  4. The credit appears in the ledger as Topup once Stripe confirms the payment. Each payment is credited once.

If you leave Stripe's page without paying, nothing is charged and nothing is credited.

Card fees

You pay the card processing fee at cost: 2.9% of the charge plus $0.30. It is added on top, so the credit you receive is exactly the amount you entered. Safeguard keeps no margin on the fee and does not absorb it either.

The charge is the credit plus $0.30, divided by 0.971 (which is 1 minus 2.9%), rounded up to the next cent. For example, $25.00 of credit is charged $26.06, of which $1.06 is the card fee.

Invoices and usage statements

The Console does not issue invoices for inference credit. A card top-up is a one-time payment on Stripe's checkout page, and Stripe emails its own receipt for it. Your record is the credit ledger: every grant, top-up and charge, each with the balance after it. For anything else about billing, contact hi@safeguard.sh.

Usage statements

Where Safeguard has switched on statements for your workspace, Usage lists every month with activity, newest first: requests, input and output tokens, usage cost, top-ups, grants and adjustments. Any member can download a month as CSV:

  • one line per day, model, provider route, key and whether the request ran on your own provider key, with requests, tokens and cost;
  • then the month's top-ups, grants and adjustments from the ledger.

A statement is a record of usage, not a tax invoice. Text cells that start with =, +, - or @ are prefixed with ' so a spreadsheet does not run them as formulas.

What managers and other members see

Everyone who can open the Console sees the same figures and the same ledger. Only the workspace's tenant admins and super admins can change the gateway settings, buy credit or delete stored prompts.

Tenant admins and super adminsOther members
Balance, reserved, available and month spendSeeSee
Credit ledgerSeeSee
Gateway settings: the workspace monthly spend limit, storing prompts, retries and fallbacks, zero data retentionSee and changeSee only. The Console says "A tenant administrator can change these."
Add credit by card, when top-up is onYesNo

Safeguard's billing service makes these checks itself, so they do not depend on the Console's screens, and it records each change in the workspace's audit trail. See Team and access.

On this page