> The index of all pages is at https://docs.afffast.com/llms.txt.

# rate_limit_exceeded

Too many requests. Wait and try again.

HTTP status: **429**. Error type: `rate_limit_error`.

Too many requests. Wait and try again.

## Example

```json
{
  "error": {
    "type": "rate_limit_error",
    "code": "rate_limit_exceeded",
    "message": "Too many requests. Wait and try again.",
    "doc_url": "https://docs.afffast.com/errors/rate-limit-exceeded",
    "request_id": "req_3kQ9x7WmZpL2vNd8TfYb4A"
  }
}
```

## Causes

- The key sent more requests than its limit in the time window.

## How to fix

- Wait for the number of seconds in the header `Retry-After`, and then try again.
- Read the headers `RateLimit-Limit`, `RateLimit-Remaining` and `RateLimit-Reset` to stay below the limit. See [Rate limits](https://docs.afffast.com/docs/rate-limits.md).
