A rate-limited request returns HTTP
429 with message: "Rate limit exceeded", status_code: "0", and data: null.Handling 429 responses
When you receive a429 response, wait before trying again. Use exponential backoff and cap the number of retries. If repeated retries still return 429, stop and wait longer rather than continuing to send requests.
Best practices
These practices reduce unnecessary requests:- Cache infrequently changing data. Market names, descriptions, and outcomes rarely change. Cache them locally and reserve requests for time-sensitive data.
-
Paginate, don’t dump. Use the
limitquery parameter and thenextCursorcursor to fetch data in manageable pages rather than requesting the largest possible payload in a single call. This keeps individual responses fast and reduces the chance of timeouts. - Poll responsibly. Choose a polling interval that matches your credential limits and freshness requirements.