# Rate limits

Two limits apply to every authenticated `/v1` request. Both use 1-minute windows and
hold across all of Talksign's servers.

| Limit | Value | Applies to |
|---|---|---|
| Per-key limit | **60 requests/min** by default; set your own (1–**600**) under **Usage limits** in the portal | Each API key |
| Test keys | **10 requests/min** (or your setting, if lower) | Each `sk-test-` key |
| Global guard | 100 requests/min | Each key, always |

The values are also published (generated from configuration) in
`x-talksign-rate-limits` of `GET /v1/openapi.json`.

Some endpoints have their own extra limits:

- `POST /v1/avatars/validate`: 3 per minute and 20 per day per account.
- `POST /v1/avatars`: at most 5 failed creations per 24 h (`429 avatar_quality_retry_limit`).

## Headers

Per-key window:

| Header | Meaning |
|---|---|
| `X-RateLimit-Limit` | Requests allowed per minute for this key. |
| `X-RateLimit-Remaining` | Requests left in the current window. |
| `X-RateLimit-Reset` | Seconds until the window resets. |

Global guard (IETF draft standard headers):

| Header | Meaning |
|---|---|
| `RateLimit-Limit` | Requests allowed in the window. |
| `RateLimit-Remaining` | Requests left. |
| `RateLimit-Reset` | Seconds until reset. |
| `RateLimit-Policy` | The policy, e.g. `100;w=60`. |

## When you hit a limit

You get `429 rate_limit_exceeded` with a `Retry-After` header (seconds). Wait that long,
then retry; nothing was charged. Spread bursts out, keep a client-side queue, and send
the same `Idempotency-Key` when you retry a paid call.

Need more than 600 requests per minute per key? Use several keys or contact us.
