Rate limits
Your spend boundary is a per-customer token cap by model tier class (weekly + monthly). RPM/TPM act as anti-flood burst guards, and token packs add headroom for planned spikes.
Token caps by model tier class
The spend boundary on flat tiers is a hard token cap per model tier class, enforced per customer over a weekly and a monthly window. A model's tier class (budget / mid / premium / ultra) is set by its price. Caps are shared across all keys on an account — N keys draw from one bucket, closing the multi-key gaming exploit older gateways have. Exceed a class's weekly or monthly cap and the request returns 402 token_quota_exceeded. A class with no row for a tier is not available on that tier.
| Tier | Budget (wk / mo) | Mid (wk / mo) | Premium (wk / mo) | Ultra |
|---|---|---|---|---|
| Starter | 8M / 25M | — | — | — |
| Pro | 40M / 120M | 8M / 24M | 1.5M / 4M | — |
| Pay-As-You-Go | No fixed token quota — soft cost-velocity alert + pay-as-you-go terms | |||
| Enterprise | No fixed token quota — soft cost-velocity alert + contract terms |
Tokens count input + output. Starter runs budget models only. Pro adds mid + premium. Ultra-class models are Enterprise / PAYG territory. PAYG and Enterprise have no hard token cap — usage is governed by a soft internal cost-velocity alert plus your commercial terms.
A reserved Free tier (budget only, 1M wk / 3M mo) exists in schema but has no live signups today.
Custom per-customer overrides are available — contact [email protected].
RPM / TPM burst guards + inflight cap
Separate from the token cap (your spend boundary), every tier has RPM and TPM burst guards plus a per-key inflight cap. These are anti-flood limits — they protect upstream providers and your own tail latency, not your monthly budget. Tripping one returns 429 rate_limit_exceeded (or concurrent_limit_exceeded for the inflight cap).
| Tier | RPM | TPM | Max concurrent |
|---|---|---|---|
| Free | 20 | 40,000 | 25 |
| Starter | 30 | 60,000 | 60 |
| Pro | 120 | 500,000 | 150 |
| Pay-As-You-Go | 60 | 200,000 | 125 |
| Enterprise | 30,000 | 100M | 500 |
RPM = requests / minute (rate). TPM = total tokens / minute (input + output). Max concurrent = simultaneous in-flight requests per key — headroom for concurrency, not a throughput cap.
Two different boundaries
402 token_quota_exceeded— you spent your weekly or monthly token cap for a model tier class. The response carriesmodel_tier_classandwindow(weekly|monthly). Retrying won't help until the window rolls over — buy a token pack, upgrade your tier, or move the workload to a class you still have budget in.429 rate_limit_exceeded— you tripped the RPM/TPM burst guard. Transient: back off and retry, respectingRetry-After.
Read these instead of hitting a limit
Every successful response reports your current RPM/TPM burst-guard budgets. Use them to throttle client-side before the guard fires. Token-cap exhaustion surfaces as a 402 token_quota_exceeded, distinct from the 429 rate_limit_exceeded flood guard.
200 — burst-guard headers on every response
402 — token quota exceeded (the spend boundary)
429 — burst guard tripped (RPM/TPM flood)
429 — concurrent (inflight) cap
| Header | Description |
|---|---|
x-anoman-rate-limit-rpm | RPM burst-guard cap for your tier |
x-anoman-rate-remaining-rpm | Requests left in the current minute |
x-anoman-rate-limit-tpm | TPM burst-guard cap for your tier |
x-anoman-rate-remaining-tpm | Tokens left in the current minute |
retry-after | Standard HTTP header — seconds to wait. Only on 429. |
x-anoman-tier | Customer's tier (starter/pro/payg/enterprise) |
x-anoman-inflight-cap | Concurrent-request ceiling (only on 429 from this bucket) |
x-anoman-inflight-current | Current concurrent count (only on 429) |
Respect Retry-After
The OpenAI / Anthropic SDKs retry automatically by default, but they ignore Retry-After in some versions. Here's an explicit pattern that picks server-suggested wait when present, exponential backoff otherwise:
Python — respect Retry-After
TypeScript — same pattern
Concurrent vs rate
The two 429 codes mean different things:
rate_limit_exceeded— you tripped the RPM/TPM burst guard. Retry after the window rolls over.concurrent_limit_exceeded— too many in-flight at the same instant. Drop concurrency or wait for one to complete.
The inflight cap is independent of RPM/TPM. A Pro account at 120 RPM with 150 inflight cap can fire 120 sequential requests per minute or up to 150 simultaneous — but not 150 simultaneous of 5-second calls (that would burst RPM way over 120).
Why both? RPM protects upstream services from total volume. Inflight cap protects your own latency budget — too many in-flight requests waiting on the upstream queue makes everyone slower. Lower inflight = predictable tail latency.
Buy extra tokens when you need headroom
On a flat tier, when a model tier class is close to its token cap, buy a token pack to add temporary headroom to that class for a fixed duration. It's an additive bump to the class's cap — not a change to your RPM/TPM burst guards. Costs are deducted from your prepaid balance.
Python — buy a token pack
PAYG and Enterprise don't need token packs — they have no hard token cap to begin with.
Watch your token caps in real time
The Rate Limits dashboard shows per-class token usage and RPM/TPM burst guards with sparklines.