POST /v1/quote
Get the best swap route across all major DEXes.
Request
http
POST /v1/quote
Content-Type: application/json
X-API-Key: YOUR_API_KEYBody
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
inputMint | string | Yes | — | Base58 mint or token symbol (e.g. "SOL", "USDC") |
outputMint | string | Yes | — | Base58 mint or token symbol |
amount | string | Yes | — | Amount in smallest units (e.g. lamports) |
slippageBps | number | No | 100 | Slippage tolerance (1-5000 bps) |
Example
json
{
"inputMint": "SOL",
"outputMint": "USDC",
"amount": "1000000000",
"slippageBps": 100
}Response
200 OK
json
{
"routes": [
{
"dex": "orca-whirlpool",
"poolAddress": "HJPjoWUrhoZzkNfRpHuieeFk9AnbVjTk9Gc5SJRqsQTK",
"outputAmount": "134520000",
"priceImpactBps": 1,
"feeBps": 4
},
{
"dex": "raydium-clmm",
"poolAddress": "2QdhepnKRTLjjSqPL1PtKNwqrUkoLee2FyZ9b6b4Pmu3",
"outputAmount": "134480000",
"priceImpactBps": 2,
"feeBps": 5
}
],
"bestRoute": {
"dex": "orca-whirlpool",
"poolAddress": "HJPjoWUrhoZzkNfRpHuieeFk9AnbVjTk9Gc5SJRqsQTK",
"outputAmount": "134520000",
"priceImpactBps": 1,
"feeBps": 4
},
"inputMint": "So11111111111111111111111111111111111111112",
"outputMint": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
"amount": "1000000000",
"slippageBps": 100,
"poolsScanned": 7
}Route Object
| Field | Type | Description |
|---|---|---|
dex | string | DEX identifier (orca-whirlpool, raydium-clmm, etc.) |
poolAddress | string | Base58 pool account address |
outputAmount | string | Expected output in smallest units |
priceImpactBps | number | Estimated price impact in basis points |
feeBps | number | Pool fee in basis points |
Errors
| Status | Description |
|---|---|
400 | Invalid request body |
401 | Missing or invalid API key |
404 | No pools found for this pair |
429 | Rate limit exceeded |
Rate Limit
60 requests per minute per API key.
