{"uid":"cap_JEWImEFQbJGSG4ANCPExw","slug":"base-dex-best-execution-router-1cec2576","name":"Base DEX Best Execution Router","description":"Cheapest venue to buy and richest to sell ONE pair on Base across BaseSwap, SushiSwap and Uniswap v3. Returns buyAt and sellAt (venue, price, tvlUsd), midSpreadBps, grossSpreadBps, optimalInput, venuesConsidered. Requires ?pair=SYM/SYM (e.g. WETH/USDC). Errors: 400 bad_pair, 404 not_routable, 502 upstream_read_failed. Ranks venues for one pair; to rank EVERY pair use /scan. Execution at a size is /slippage. Chain-pinned; bare /route = BSC.","url":"https://x402.donnyautomation.com/base/route","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":["pair"],"properties":{"pair":{"type":"string","description":"Token pair as SYM/SYM on Base (e.g. WETH/USDC)."}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":{"type":"json","example":{"ts":"2026-07-31T00:00:00.000Z","chainId":8453,"network":"base"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.01","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.01/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.01","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_6h86YlM4yHoPpx5aj6YMS","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.01","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns the best buy and sell venues, cross-exchange spread in bps, fee-adjusted arbitrage spread, and optimal trade size for a token pair across BaseSwap, SushiSwap, and Uniswap v3 on Base L2.","exampleAgentPrompt":"Which DEX on Base gives me the best price to buy WETH with USDC right now — compare BaseSwap, SushiSwap, and Uniswap v3 and tell me the spread and optimal trade size for the WETH/USDC pair.","exampleUseCases":[{"title":"Pre-trade best execution check","prompt":"Before I swap 10 ETH worth of USDC on Base, check which DEX — BaseSwap, SushiSwap, or Uniswap v3 — gives me the best buy price for WETH/USDC and tell me the fee-adjusted spread."},{"title":"Base L2 arbitrage opportunity scanner","prompt":"Is there a meaningful arbitrage spread right now between DEXs on Base for the WETH/USDC pair? Give me the cross-exchange spread in bps and the optimal trade size to capture it."},{"title":"Automated agent execution routing","prompt":"My trading bot needs to sell cbBTC on Base — find the DEX that pays the most for cbBTC/USDC and tell me the best sell venue and how large a trade I can execute before moving the price."}],"resultDescription":"Returns the best buy venue (cheapest DEX), best sell venue (highest price DEX), cross-exchange spread expressed in basis points, fee-adjusted gross arbitrage spread, and an optimal trade size for the requested token pair on Base L2.","failureModes":["Unsupported token pair symbol returns an error or empty result","Token pair with no liquidity on one or more venues may return incomplete venue comparison","Network latency or RPC issues on Base L2 may cause stale or failed price fetches","Malformed pair parameter (wrong format, missing slash) returns a validation error","Very low liquidity pairs may return zero optimal trade size"],"whenToPreferThis":"Use this endpoint when you need real-time best-execution routing specifically on Base L2 across BaseSwap, SushiSwap, and Uniswap v3. Prefer it over generic price feeds when you need venue-level comparison, spread data in bps, and an optimal trade size in a single call. Choose it over single-DEX price APIs when cross-DEX arbitrage or smart order routing is the goal. If you need the same analysis on Arbitrum One or BSC, use the sibling endpoints for those chains.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T18:45:53.327Z","isFirstParty":false}