Skip to main content
GET
Quote an EVM swap
Guide: EVM swaps. Pass the answer unchanged as quoteResponse to POST /evm/swap before its expiresAt. Errors: EVM errors.

Authorizations

x-api-key
string
header
required

Query Parameters

chain
string
required

eth, bsc, base or robinhood (also ethereum, bnb), or the chain id: 1, 56, 8453, 4663. Alias chainId

Example:

"base"

inputMint
string
required

Token you spend: its 0x address (any case), or 0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE or native for the chain's coin. The zero address is refused

Example:

"0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE"

outputMint
string
required

Token you receive, spelled as inputMint. Must differ from it: there are no cycles on EVM

Example:

"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"

amount
string
required

What you spend: a uint256 in the token's smallest unit (wei for the native coin), in decimal digits. No sign, fraction or exponent. 0 is 400 declined zero_amount

Pattern: ^[0-9]+$
Example:

"1000000000000000"

slippageBps
integer
default:50

Tolerance in basis points, 0–10000; above 10000 is 400

Required range: 0 <= x <= 10000
swapMode
enum<string>
default:ExactIn

Only ExactIn (or exactIn): ExactOut is 400

Available options:
ExactIn,
exactIn
maxHops
integer
default:2

Most hops per route: 1 direct only, 2 through at most one intermediate token, 3 two. 0 counts as 1; more than 3 counts as 3

Required range: x >= 0
onlyDirectRoutes
boolean
default:false

true is maxHops=1: a single pool

dexes
string

Only these venues: dex labels (Uniswap V3, PancakeSwap V2, …) or venue ids (base-uniswap-v3) from /evm/venues, matched ignoring case and punctuation; comma-separated or the parameter repeated. Alias includeDex. Unknown labels next to known ones are ignored; only unknown labels (or only another chain's) is 400

Example:

"Uniswap V3"

excludeDexes
string

Never these venues, same format as dexes. Alias excludeDex. Excluding every venue of the chain is 404 no_route

Example:

"Uniswap V2"

platformFeeBps
integer
default:0

Only 0 or absent: there is no platform fee on EVM, and above 0 is 400

Response

The quote (live answers of the public router)

inputMint
string
required

Lower case; the native coin is 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee

inAmount
string
required

What you spend: the amount asked

outputMint
string
required
outAmount
string
required

What the route gives at the quote's block, in base units of outputMint, before any tax the token itself takes

otherAmountThreshold
string
required

The floor the swap will enforce on chain: outAmount × (10000 − slippageBps) / 10000, rounded down (inAmount for a wrap or an unwrap)

swapMode
string
required
Allowed value: "ExactIn"
slippageBps
integer
required
priceImpactPct
string
required

Not computed on EVM: always 0

Allowed value: "0"
routePlan
object[]
required

One step per hop, in order

contextSlot
integer
required

The block number the quote was priced at

timeTaken
number
required

Seconds spent inside the router

quoteId
string<uuid>
required

What POST /evm/swap builds, until expiresAt

chain
enum<string>
required

eth (chain id 1), bsc (56), base (8453), robinhood (4663)

Available options:
eth,
bsc,
base,
robinhood
chainId
integer
required
router
string
required

The contract the swap transaction goes to: the venue's router (also the approvals' spender), or the wrapped token for a wrap or an unwrap

gasEstimate
string
required

Indicative (QuoterV2 on V3, a fixed estimate per hop on V2). The build's simulation gives the real figure

blockHash
string
required

The hash of the block the quote was priced at

expiresAt
string<date-time>
required

Until when the quote can be built: the chain's quoteTtlSecs after quoting (15 s; 30 s on eth)

candidates
integer
required

Routes priced (0 for a wrap or an unwrap)