# Rate limiting

## Default limits

This API is rate-limited using the token bucket algorithm.

**Rate:** 5 requests per second

* The 5 requests per second applies to how many requests can be initiated each second; the requests do not need to finish before more can be started at the 5 request per second rate.

**Burst Capacity:** 100 requests

* The burst capacity enables your application to temporarily exceed the 5 RPS limit by using pre-accumulated tokens. This allows for short spikes in traffic to be handled smoothly without triggering throttling, as long as tokens remain available in the burst bucket.
* If you send fewer than 5 requests in a given second, burst tokens accumulate (up to 100), allowing for additional bursts in traffic.

**Total Daily Quota**: 200k requests

* The total number of requests allowed in a 24 hour period.

## **Throttling**

If the request rate is exceeded, a response with HTTP 429 Too Many Requests is sent.

To avoid throttling:

* Keep steady usage at or below 5 requests per second.
* Implement exponential backoff with retry logic to space out retries.

## **Higher Limits**

If your application requires a higher sustained rate, burst capacity, or daily quota, please contact us.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://developer.ballotpedia.org/rate-limiting.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
