> ## Documentation Index
> Fetch the complete documentation index at: https://grailx.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Rate Limits

> Request rate limits for the SQR API.

The API enforces per-key and per-IP rate limits to ensure fair usage.

## Limits

| Client type                        | Limit                |
| ---------------------------------- | -------------------- |
| Authenticated (API key or JWT)     | 60 requests / minute |
| Unauthenticated (public endpoints) | 20 requests / minute |

## Rate limit headers

When you approach the limit, responses include:

```
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 12
X-RateLimit-Reset: 1717600000
```

## 429 response

When the limit is exceeded:

```json theme={null}
{
  "error": "Rate limit exceeded"
}
```

The response includes a `Retry-After` header (in seconds) indicating when you can resume.

## Tips

* Cache template and record lookups on your side to reduce request volume
* Use the `/api/records/sync` endpoint with a `since` timestamp for incremental updates instead of polling the full list
* If you need higher limits, contact us
