{"uid":"cap_TZ7yBUhXGC7ShN0clQvX9","slug":"market-intelligence-api-on-chain-dex-quote-9ff03cd0","name":"Market Intelligence API – On-Chain DEX Quote","description":"DEX swap quote and best route ($0.005): how much you get now across Uniswap v2/v3/v4 and Aerodrome (direct or through WETH) on Base, Ethereum, Arbitrum, Optimism or Polygon, with price impact, the minimum to accept at your slippage and alternative routes. Simulated with eth_call; nothing is executed. Use right before an on-chain swap.","url":"https://api.marketintelligenceapi.com/api/v1/intelligence/quote?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input","output"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":["sell","buy","amount"],"properties":{"buy":{"type":"string","description":"Token to buy: ETH, WETH, USDC (USDT on Ethereum) or a 0x token address"},"sell":{"type":"string","description":"Token to sell: ETH, WETH, USDC (USDT on Ethereum) or a 0x token address"},"chain":{"enum":["base","ethereum","arbitrum","optimism","polygon"],"type":"string","default":"base","description":"Chain the swap is quoted on: base, ethereum, arbitrum, optimism or polygon. Not the payment network: payment networks are in x-payment-info.networks."},"amount":{"type":"string","description":"Amount of the sell token in whole units, e.g. 1000 or 0.5"},"slippageBps":{"type":"integer","default":50,"maximum":5000,"minimum":1,"description":"Slippage tolerance for minimumReceived, in basis points"}},"additionalProperties":false}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"description":"Example JSON response returned by this endpoint"}},"additionalProperties":true}},"additionalProperties":false},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_5RhylVbQI_JfOg6yjvtd7","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns a simulated best-route DEX swap quote (amount out, price impact, minimum accepted, alternative routes) across Uniswap v2/v3/v4 and Aerodrome on Base, Ethereum, Arbitrum, Optimism, and Polygon without executing any transaction.","exampleAgentPrompt":"Before I swap 2 ETH for USDC on Base, check what the best route gives me right now — show me the expected output, price impact, and minimum I should accept at 0.5% slippage across Uniswap and Aerodrome.","exampleUseCases":[{"title":"Pre-swap sanity check on Arbitrum","prompt":"I want to swap 500 USDC for ARB on Arbitrum — before I confirm, can you simulate the best DEX route and tell me the expected ARB output, price impact, and minimum I should accept at 1% slippage?"},{"title":"Best route comparison for large ETH trade","prompt":"I'm about to sell 10 ETH for USDC on Ethereum mainnet. Check the best route across Uniswap v2, v3, and v4, and tell me how much USDC I'll get, what the price impact is, and whether going through WETH gives a better rate."},{"title":"Optimism DeFi portfolio rebalancing","prompt":"I need to rebalance by swapping 1000 OP tokens to WETH on Optimism — simulate the best quote for me, show the top routes and what the minimum output is at 0.3% slippage so I know what to set before executing."}],"resultDescription":"Returns the expected output token amount for the best available route, price impact percentage, minimum acceptable output at the specified slippage, the optimal routing path (direct or via WETH), and a list of alternative routes with their respective quotes — all simulated via eth_call with no on-chain execution.","failureModes":["Unsupported token pair returns no route found error","Unsupported network returns invalid chain error","Extremely low liquidity pairs may return high price impact warning or no quote","Invalid token address format causes a validation error","Network RPC congestion may cause eth_call simulation timeout"],"whenToPreferThis":"Choose this endpoint when you need a pre-trade simulation of DEX swap output across multiple venues (Uniswap v2/v3/v4, Aerodrome) on supported EVM chains (Base, Ethereum, Arbitrum, Optimism, Polygon) before executing an on-chain swap. It is specifically valuable for comparing routing paths, assessing price impact, and determining slippage parameters without committing any transaction. Prefer it over generic price feeds when you need execution-realistic quotes, not just spot prices.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-18T18:36:34.959Z","isFirstParty":false,"canonicalSlug":"market-intelligence-api-on-chain-dex-quote-9ff03cd0"}