# Pricing

You pay for input tokens: **$0.042 per million input tokens** (that is $42 per billion). Output is free. This is the same way TypeSafe prices Jev, at the same price. Jepela is for business customers; prices exclude VAT and other taxes, which are added where the law requires.

Input tokens are what the engine read to answer: the state, your questions and their options, and the memory lines it recalled for the subject. `usage.input_tokens` in every answer is the engine's own count, never an estimate, and `usage.output_tokens` is always 0, because Jepela does not generate text.

Memory writes (`remember`, rules) are free; the lines are paid for as input when a decision reads them.

## How it is counted

The engine reads the state once per question, so a request with three questions reads it three times. Measured on 2026-09-24 through `https://api.jepela.com` with `jepela-english`, a 74-character support message:

| Request | `input_tokens` | Cost at $0.042 per million (arithmetic) |
|---|---|---|
| one yes/no question | 47 | $0.000002 |
| three questions (choice, yes/no, score) | 128 | $0.0000054 |
| the same three, with a state four times as long | 245 | $0.0000103 |
| the same three with `"robust": true` | 208 | $0.0000087 |

- `"robust": true` reads each choice once per option order, `"windows": true` reads every window, and a choice with more than 20 options read by the engine (`"method": "engine"`) is read in two rounds; all of that is in the engine's count and billed.
- A matched choice (more than 20 options, the default; see Request options) is billed for the tokens it read: the state and its memory lines, not the options, and at most 512 a question, which is all the matching model reads (its search prefix and two special tokens included); its `reading` says what it read. Measured on a 77-option choice (600 bank messages, 2026-09-27): 23 tokens matched against 812 read by the engine. Earlier versions billed a matched choice for every token of a state longer than that, though the matching model read only its first 512; such requests now cost less.
- `"memory": {"compare": true}` (the same call without memory), `"memory": {"explain": true}` (one pass per memory line left out) and `"memory": {"placebo": true}` (the neutral pass) are extra passes that are not billed.
- `"quality": "balanced"` or `"best"` (see Request options): the second tier's reading is not billed; `usage.tier2_input_tokens` shows it.
- A cache hit is billed like the first call; `usage.cached` says it cost no engine work.

Every priced request is one line in your tenant's ledger with the time, the route, the key id, the subject id it named, the counts and the cost, and is charged against your prepaid credit at once. Credit that a refund or a dispute takes back (see Credit) is a line of its own, not a request. `GET /v1/usage` returns credited, spent, debited (credit taken back by refunds and disputes), balance (credited less spent and debited), requests, the prices, your rate limit, your key ids, the ledger totals (with `debits` and `debited`) and the last twenty requests; the totals and the balance always agree. A request that fails upstream (502) or in the gateway (500) is not charged.

Fine-tuning is free during the preview; a fine-tuned model's decisions are billed like any other (see Fine-tuning).

## Credit

Jepela adds credit to your tenant after a payment. When the balance is zero or below, priced requests answer 402 until credit is added; `GET` routes still work so you can see the account. Removing data never waits for credit: `POST /v1/memory/forget` (and its preview), `/v1/memory/delete`, `/v1/memory/rules/delete`, `/v1/memory/aliases/delete`, `/v1/golden/delete`, `/v1/decisions/delete` and `/v1/finetune/delete` work at any balance, and also while the account is suspended, as do the `GET` routes, which read your data. A forget or a memory delete is billed by the prices like any request while the balance covers it; when it does not, it is carried out all the same, its ledger line says `cost` 0 and `unbilled` (what it would have cost; `usage.unbilled` in the answer), and the balance never goes below zero for removing data.

## Refunds and disputes

Credit bought by card is taken back when the payment is:

- **refunded:** in full, the credit it added is removed; in part, the same share of that credit as the share of the payment refunded (the payment includes VAT, so a refund of half the amount paid removes half the credit). A payment made in another currency is counted the same way, by the share of what was paid. If a refund fails, the credit is added back.
- **disputed with your bank (a chargeback, or the bank's inquiry before one):** the disputed share of the credit is removed at once. It is added back if the dispute is decided in Jepela's favour or closed without a chargeback, and stays removed if it is decided in your favour (your bank gives you the money back) or settled by refunding you before a chargeback.

Each refund and each dispute is counted once, however often the payment provider reports it, and together they never remove more than the credit that payment added. A payment refunded or disputed before its credit was added is not credited automatically. Credit already used can take the balance below zero; priced requests then answer 402 as at zero until added credit brings it above zero, and removing data still works; every page of the console then says the balance is below zero. The console's Billing page shows each card payment as refunded, partly refunded or disputed, with the credit removed, and the credit history lists what was taken back.

## Rate limits

Each account has a limit of requests per minute, counted over all its keys (default 600; 60 for a tenant made by sign-up). Over it, 429 with `Retry-After`.

## Limits in the console

The console limits what it can be made to send out, against card fraud and unwanted email. An account can open at most 5 card payment pages an hour and 20 a day, pending or approved, and at most 10 payment pages an hour can be opened from one address. Over a limit, the console says how long to wait (429 with `Retry-After`) and opens no payment page.

A bank invoice ("Request an invoice", a top-up request) can be asked for at most 3 times an hour and 10 times a day for an account, and at most 10 times an hour from one address. Over a limit, the console says how long to wait (429 with `Retry-After`) and the request is not sent.

The confirmation email can be sent again ("Send it again") at most 3 times an hour and 10 times a day for an account and its email address, and 10 times an hour from one address, so that nobody can have it sent to someone else's inbox over and over. An email address counts as its inbox: capital letters, a `+tag` (`ana+1@`) and, at Gmail, dots in the name do not make it another address. Over a limit, the console says how long to wait (429 with `Retry-After`) and sends no email.

When you sign up, the confirmation email goes out at most 3 times an hour and 10 times a day to one email address, counted as its inbox in the same way, however many sign-ups use it. Over that, the account is made as usual but no confirmation email is sent; use "Send it again" later.

A password reset email ("Forgot your password?") can be asked for at most 3 times an hour and 10 times a day for one email address, counted as its inbox in the same way, and at most 10 times an hour from one address. Over a limit, the console says how long to wait (429 with `Retry-After`) and sends no email, whether or not an account has that address.

The billing portal ("Invoices and card details", where you see your invoices and change your card and billing address) can be opened at most 10 times an hour for an account, and at most 20 times an hour from one address. Over a limit, the console says how long to wait (429 with `Retry-After`).
