Rate Limiting
Overview
The Covolt API implements rate limiting to ensure system stability and fair usage across all clients. Our rate limiting system helps protect the API from excessive traffic and prevents any single client from consuming disproportionate resources.
Current Limits
The following rate limits apply to all API endpoints:
| Timeframe | Limit | Scope |
|---|---|---|
| 1 minute | 60 requests | Per API token |
| 1 hour | 1,000 requests | Per API token |
Rate Limit Headers
When rate limits are exceeded, the API response will include a Retry-After header indicating the number of seconds to wait before making another request:
Retry-After: 30
This follows Django REST Framework's standard rate limiting implementation, which focuses on providing clear guidance on when to retry rather than detailed tracking of remaining requests.
Exceeding Rate Limits
If you exceed the defined rate limits, the API will respond with:
- Status code:
429 Too Many Requests - Response body: A message indicating that rate limits were exceeded
Retry-Afterheader: Seconds to wait before making another request
Example response when rate limited:
{
"detail": "Request was throttled. Expected available in 30 seconds."
}
Best Practices
To work effectively with our rate limits:
-
Implement retry logic: When you receive a 429 response, use the
Retry-Afterheader to determine how long to wait before retrying. -
Exponential backoff: For robust applications, implement exponential backoff when encountering rate limits.
-
Cache responses: Where appropriate, cache API responses to reduce the number of requests needed.
-
Batch operations: Use bulk endpoints where available instead of making multiple single-item requests.
-
Distribute requests: Space out non-urgent requests evenly over time rather than sending them all at once.
If your use case requires higher rate limits, please contact our support team at development-nl@covolt.eu with details about your specific needs and use case.