{"uid":"cap_OA4ZJBr96TCpoktoP4bBT","slug":"defi-shield-hazel-vercel-app-55eb1005","name":"DeFi Shield MEV Optimal Route Finder","description":"","url":"https://defi-shield-hazel.vercel.app/api/mev/optimal-route","method":"POST","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","bodyType","body","method"],"properties":{"body":{"properties":{"chain":{"type":"string","description":"Chain (default: base)"},"amount_usd":{"type":"number","description":"Trade amount in USD"},"token_address":{"type":"string","description":"Token address"}}},"type":{"type":"string","const":"http"},"method":{"enum":["POST"],"type":"string"},"bodyType":{"enum":["json","form-data","text"],"type":"string"}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":null,"example":{"request":{"chain":"base","tokenOut":"0x4200000000000000000000000000000000000006","amount_usd":100,"token_address":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","slippageTolerance":0.5},"response":{"chain":"base","routes":[{"dex":"aerodrome","pair":"AERO/USDC","pair_address":"0x6cDcb1C4A4D1C3C6d054b27AC5B77e89eAFb971d","liquidity_usd":22607550.55,"estimated_impact":0.0002,"allocation_percent":77.65,"allocated_amount_usd":77.65},{"dex":"aerodrome","pair":"VELVET/USDC","pair_address":"0x6b0F53cbD9272D8117e9535FE25371dedF39a1bE","liquidity_usd":2822335.39,"estimated_impact":0.0002,"allocation_percent":9.69,"allocated_amount_usd":9.69},{"dex":"aerodrome","pair":"NOCK/USDC","pair_address":"0x85f1Aa3a70fEdd1C52705c15BAEd143e675CD626","liquidity_usd":1264244.71,"estimated_impact":0.0002,"allocation_percent":4.34,"allocated_amount_usd":4.34},{"dex":"uniswap","pair":"USDC/USDbC","pair_address":"0xa0ab20a64f46b5676fe1542cb87b454e5104007689e0eef4212aa0cbe34933a1","liquidity_usd":907467.92,"estimated_impact":0.0002,"allocation_percent":3.12,"allocated_amount_usd":3.12},{"dex":"aerodrome","pair":"CTR/USDC","pair_address":"0x0ab02e160f0df68dc049B012c514857306960Eae","liquidity_usd":571278.27,"estimated_impact":0.0002,"allocation_percent":1.96,"allocated_amount_usd":1.96},{"dex":"aerodrome","pair":"USDC/USDbC","pair_address":"0x98c7A2338336d2d354663246F64676009c7bDa97","liquidity_usd":519676.65,"estimated_impact":0.0002,"allocation_percent":1.78,"allocated_amount_usd":1.78},{"dex":"aerodrome","pair":"SOL/USDC","pair_address":"0x1131DB5977242a03eBeaD1aCD18F80A9A29e5922","liquidity_usd":267678.6,"estimated_impact":0.0002,"allocation_percent":0.92,"allocated_amount_usd":0.92},{"dex":"uniswap","pair":"AERO/USDC","pair_address":"0xE5B5f522E98B5a2baAe212d4dA66b865B781DB97","liquidity_usd":155660.39,"estimated_impact":0.0002,"allocation_percent":0.53,"allocated_amount_usd":0.53}],"data_age":"2026-06-16T01:17:58.430Z","cache_ttl":300,"amount_usd":100,"token_address":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","pools_analyzed":8,"recommendation":"Execute in single transaction via aerodrome. Impact is negligible.","total_liquidity":29115892.480000004,"response_time_ms":34,"single_pool_impact":0.0002,"total_price_impact":0.0002,"recommended_slippage":0.5,"savings_vs_single_pool":0}},"exampleRequest":{"chain":"base","tokenOut":"0x4200000000000000000000000000000000000006","amount_usd":100,"token_address":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","slippageTolerance":0.5},"tags":["x402"],"displayCostAmount":"0.5","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","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.5/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.5","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.5","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_n2KNing1rnAAq47wnSPaO","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.5","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Finds the optimal trading route across DEXs to minimize price impact and MEV (Miner Extractable Value) exposure for a given swap","exampleAgentPrompt":"Find me the optimal trading route to swap 5 ETH for USDC across DEXs — I want to minimize price impact and protect against MEV sandwich attacks as much as possible.","exampleUseCases":null,"resultDescription":"Returns the optimal DEX routing path for the requested swap, including recommended sequence of exchanges, estimated price impact percentage, MEV exposure risk score, and any suggested execution strategies to minimize front-running or sandwich attack risk.","failureModes":["Invalid or unsupported token address — endpoint returns error indicating unrecognized token","Trade size too large for available liquidity — returns warning about insufficient pool depth","Network congestion causing stale route data — may return outdated pricing information","Unsupported token pair with no viable DEX path — returns no-route-found error","Payment of 0.5 USDC not processed — returns 402 payment required"],"whenToPreferThis":"Use this endpoint when an AI agent or user needs to execute a DeFi token swap and wants to minimize both price impact from large trades and MEV exposure (front-running, sandwich attacks). Particularly valuable for trades above a few hundred dollars where routing quality meaningfully affects execution price. Prefer over generic DEX aggregators when MEV protection is an explicit concern.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T12:30:40.624Z","isFirstParty":false}