Rate Limits
Rate limits are applied per API key to ensure fair usage across all users.
Limits by Plan
| Plan | Rate Limit | Max API Keys |
|---|---|---|
| Basic | 200 requests/minute | 5 keys |
| Pro | 500 requests/minute | 10 keys |
Rate Limit Headers
All API responses include headers to help you track your rate limit status:
X-RateLimit-Limit: 200
X-RateLimit-Remaining: 195
X-RateLimit-Reset: 1700000060X-RateLimit-Limit- Maximum requests per minuteX-RateLimit-Remaining- Requests remaining in current windowX-RateLimit-Reset- Unix timestamp when limit resets
Handling 429 Errors
When you exceed the rate limit, you'll receive a 429 status code. Implement exponential backoff:
Python Example
import time
import requests
def make_request_with_retry(url, headers, data, max_retries=3):
for attempt in range(max_retries):
response = requests.post(url, headers=headers, json=data)
if response.status_code == 429:
# Get reset time from header or use exponential backoff
reset_time = int(response.headers.get('X-RateLimit-Reset', 0))
wait_time = max(reset_time - time.time(), 2 ** attempt)
time.sleep(wait_time)
continue
return response
raise Exception("Max retries exceeded")Best Practices
Batch requests when possible
Use bulk endpoints to reduce the number of API calls.
Cache responses
Cache market data locally and only refresh when needed.
Use WebSockets for real-time data
WebSocket connections don't count against your rate limit.