Skip to main content
The DEX Aggregator API enforces a per-key sliding-window rate limit. The default is 120 requests per minute per API key.

How it works

Per-key

The window is keyed off the x-api-key header, not your IP. Each key gets its own bucket.

Sliding 60-second window

Hits are tracked with timestamps. The window is now − 60s..now. There’s no hard reset on the minute boundary; the oldest hits drop off as time passes.

What counts as a request

Every authenticated call counts:
  • POST /quote
  • POST /submit
  • POST /execute
GET /health is public and free.

What you get on overflow

Don’t retry immediately on 429. The window is sliding, so a fast retry just lands at the same spot in the bucket. Wait at least 1 second.

Capacity planning

A few guidelines for sizing your usage: If you expect sustained load above the default 120 req/min, contact the o1 team to discuss a higher tier.

Per-pair caching tips

You can dramatically reduce request count on the client by:
  1. Debouncing user input. Don’t quote on every keystroke; quote 300ms after the last input.
  2. Coalescing identical quotes. If two components need the same (tokenIn, tokenOut, amountIn) quote, share one fetch.
  3. Pausing polling when the tab is hidden. Use document.visibilityState === "hidden" to skip ticks.

What does NOT scale your quota

  • Adding more API keys for the same product. The o1 team can detect related keys and apply combined limits if abuse is suspected.
  • Spreading requests across IPs while reusing one key. The limit is keyed on the key, not the IP.
If you legitimately need more headroom, ask. The defaults exist to protect upstream RPC and pool-data providers, and higher tiers are available.