What you will accomplish
- Read live limit metadata and response headers
- Add exponential backoff with a maximum wait and retry count
- Retry read-only calls differently from order submissions
- Prevent auto-bans and duplicate exposure
Before you begin
- Centralized HTTP client middleware
- Metrics for status codes and latency
- Order and account lookup endpoints
Read current limits dynamically
Use exchangeInfo and response headers. The current exchangeInfo response advertises an ORDERS limit of 900 per minute, but clients should read current metadata rather than hard-code that number.
Back off on 429
Stop sending requests and honor Retry-After. Quote.Trade documentation describes seconds, while robust HTTP clients can also parse an HTTP-date.
Treat 418 as an active IP ban
Do not route around the ban by cycling IPs. Wait for Retry-After and fix the request policy.
Retry safe reads with a limit and jitter
Retry read-only GET requests a small number of times with increasing delays and random jitter. Do not retry malformed requests or permission errors.
Do not retry an order until you know what happened
A timeout or 5xx can leave the order result unknown. Check the order, account, position, and private events before deciding whether another order is safe.
Common problems and fixes
Many workers retry simultaneously
Use a shared limiter or distributed lease and add jitter.
The published and live limits differ
Prefer current exchange metadata and response headers. Contact Quote.Trade support if the discrepancy affects an integration.
The order request timed out
Search by client/order identifiers and inspect private events before resubmitting.