POST /quote
Price a swap and receive a routePlan you can hand back to /submit. Read-only, no user address required.
POST /quote to fetch a price. The response includes a stable quoteId you echo on /submit when the user is ready to swap.
- Authentication:
x-api-keyheader required. - Rate limit: 120 req/min per key (default). See Rate limits.
Request
- Endpoint
- Body
Body parameters
Response
- 200 OK
- 400 Bad Request
- 429 Rate Limited
Response fields
routePlan.expectedAmountOut— the price you displayroutePlan.minAmountOut— the worst case after slippageroutePlan.routes[].legs[].dex— list of venues used (e.g.UNIV3 → AERODROME_CL)routePlan.feeBps— protocol + integrator fee in bpsroutePlan.gasEstimate.gasUnits— estimated gas for the swap
Caching and freshness
Quotes are cached server-side under theirquoteId for roughly 10 seconds. After expiresAt, calling /submit returns 404 quote not found or expired.
For UIs that show a live price, the recommended pattern is to re-fetch the quote every 5 to 8 seconds while the swap modal is open. See Quote freshness.
Examples
Authorizations
Body
EVM chain id. 8453 for Base (current Phase-1 target).
x >= 120-byte hex address. The sentinel
0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE (or the zero
address) signals the chain's native asset (ETH on Base) and is
recognized in tokenIn/tokenOut.
^0x[a-fA-F0-9]{40}$20-byte hex address. The sentinel
0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE (or the zero
address) signals the chain's native asset (ETH on Base) and is
recognized in tokenIn/tokenOut.
^0x[a-fA-F0-9]{40}$Non-negative integer encoded as a decimal string (wei).
^[0-9]+$0 <= x <= 10000x >= 11UNIV2, UNIV3, UNIV4, AERODROME_V2LIKE, AERODROME_CL, PANCAKE_V2, PANCAKE_V3, PANCAKE_INFINITY_CL, HYDREX, QUICKSWAP_V4, ALIEN_BASE_V3, CURVE, PROPSWAP, TESSERA, ELFOMOFI, LUNARBASE, FELTIR, DODO_V2, WOOFI, GYROSCOPE_ECLP, MAVERICK_V2 Integrator fee in bps, charged out of the output amount.
0 <= x <= 1000020-byte hex address. The sentinel
0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE (or the zero
address) signals the chain's native asset (ETH on Base) and is
recognized in tokenIn/tokenOut.
^0x[a-fA-F0-9]{40}$Per-request override of the optimizer's wall-clock budget. Omit to inherit the engine default.
50 <= x <= 10000