429 Too Many Requests and you must wait before retrying. This page explains how to read the rate-limit headers included on every response, how to implement exponential backoff, and how to stay within the default quota for common workloads.
Rate-limit headers
Every API response includes three headers that tell you your current quota status:| Header | Type | Description |
|---|---|---|
X-RateLimit-Limit | integer | Your total allowed requests per 60-second window (default: 60). |
X-RateLimit-Remaining | integer | Requests remaining in the current window. |
X-RateLimit-Reset | Unix timestamp | The time (in seconds since epoch) when the window resets and X-RateLimit-Remaining returns to X-RateLimit-Limit. |
When you exceed the limit
IfX-RateLimit-Remaining reaches 0, the next request returns:
Retry-After header tells you exactly how many seconds to wait before the window resets.
Handling 429s: exponential backoff
Immediately retrying after a429 will only trigger another 429. Use exponential backoff with jitter:
Tips for staying within the limit
Cache responses locally. Market state does not change on every tick. For most read workloads, cachingGET /markets for 5–10 seconds and individual market details for 1–2 seconds dramatically reduces API calls without meaningfully staling your data.
Batch reads with pagination. Rather than making one request per market, use the limit parameter on GET /markets to fetch up to 100 markets in a single call. Then page through with offset as needed.
Use the real-time feed for high-frequency data. If you need market prices at sub-second latency, the x402 feed endpoint (GET /api/v2/x402/feed, $0.001/call) is designed for that use case and does not count against your REST rate limit.
Deduplicate inflight requests. In async or multi-threaded code, use a simple in-memory cache or request-deduplication layer to prevent the same resource from being fetched concurrently by multiple coroutines or threads.
Avoid polling loops with short intervals. A loop that calls GET /markets/:id every second will exhaust your quota in one minute. Use a minimum 5-second poll interval for market state, or switch to the WebSocket broadcaster for real-time updates.
Request a higher rate limit
If your use case requires more than 60 requests per minute — for example, a trading desk pulling tick-level data or an arbitrage bot running across hundreds of markets simultaneously — you can request a higher quota. Email support@blockforecast.io with:- Your wallet address (the one attached to your API key)
- A brief description of your use case
- The approximate request rate you need
x402 pay-per-request endpoints (
/api/v2/x402/*) are not subject to the same per-minute quota. Each call is independently metered by payment, so there is no burst limit — you can make as many calls as you can pay for.