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

# Rate Limits

> Per-endpoint rate limits for the Research Desk Demand API

All rate limits apply per credential. Exceeding a limit returns an HTTP `429 Too Many Requests` response.

## Per-Endpoint Limits

| Endpoint          | Method | Rate Limit                        |
| ----------------- | ------ | --------------------------------- |
| `/tokens`         | POST   | 5 requests/hour per email address |
| `/users`          | GET    | 10 requests/second                |
| `/accounts`       | GET    | 10 requests/second                |
| `/definitions`    | GET    | 10 requests/second                |
| `/qualifications` | GET    | 10 requests/second                |
| `/projects`       | GET    | 10 requests/second                |
| `/projects`       | POST   | 10 requests/second                |
| `/projects`       | PATCH  | 10 requests/second                |
| `/surveys`        | GET    | 10 requests/second                |
| `/surveys`        | POST   | 10 requests/second                |
| `/surveys`        | PATCH  | 10 requests/second                |
| `/responses`      | GET    | 6,000 requests/minute             |
| `/responses`      | PATCH  | 6,000 requests/minute             |

## HTTP 429 Response

When you exceed a rate limit, the API returns:

```http theme={null}
HTTP/1.1 429 Too Many Requests
```

```json theme={null}
{
  "message": "Too many requests. Please try again later."
}
```

Implement exponential backoff and retry logic in your integration to handle 429 responses gracefully.

## Best Practices

<CardGroup cols={2}>
  <Card title="Cache tokens" icon="clock">
    Tokens are valid for 12 hours. Store the token and its expiration timestamp — do not re-authenticate on every API call.
  </Card>

  <Card title="Reuse lookup data" icon="database">
    Definitions and Qualifications change infrequently. Cache this data at application startup or on a daily refresh rather than fetching per request.
  </Card>

  <Card title="Batch response polling" icon="layer-group">
    The `/responses` endpoint has a high limit (6,000/min) to support polling workflows. Use `page` and `page_size` parameters to paginate efficiently.
  </Card>

  <Card title="Use staging for load testing" icon="flask">
    Run all performance and load testing against the staging environment (`https://stage-demand.researchdesk.com`) to avoid impacting production limits.
  </Card>
</CardGroup>
