{"uid":"cap_8AHhJJbeDe6b2e5yoTL3i","slug":"intent402-token-swap-intent-resolver-82eb97d0","name":"intent402 Token Swap Intent Resolver","description":"Transaction intent resolution for AI agents: describe what you want, get back unsigned ready-to-sign transactions.","url":"https://intent402.dylan-caponi.workers.dev/intent/swap","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"example":{"type":"string"}}},"responseSchema":{"type":"json","example":{"intent":"swap","transaction":{"to":"0x...","gas":200000,"data":"0x...","value":"0","chainId":8453},"expectedOutput":"0.048 ETH"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02","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.02/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_oDlC8IJSZZVgJ406LS_g0","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Converts a natural-language swap intent into an unsigned, ready-to-sign blockchain transaction on Base (chainId 8453).","exampleAgentPrompt":"I want to swap 50 USDC for ETH on Base — can you give me the unsigned transaction I need to sign to make that happen?","exampleUseCases":[{"title":"Swap stablecoins to ETH on Base","prompt":"I have 100 USDC sitting on Base and I want to swap it for ETH — give me the unsigned transaction so I can review and sign it."},{"title":"DeFi agent building swap pipeline","prompt":"My agent needs to convert ETH to USDC on Base as part of a yield strategy — can you resolve that swap intent into a ready-to-sign transaction object with gas and calldata?"},{"title":"Wallet app swap transaction builder","prompt":"The user wants to swap 0.5 ETH for USDC on Base chainId 8453 — generate the unsigned swap transaction including the expected output amount so I can display it for confirmation."}],"resultDescription":"A JSON object containing the resolved swap transaction: the contract address to call (to), hex-encoded calldata (data), gas limit estimate, value in wei, the chain ID (8453 for Base), and the expected output token amount — everything needed to sign and broadcast the transaction without any additional construction.","failureModes":["Unsupported token pair returns an error or empty transaction","Insufficient liquidity for the requested swap amount","Malformed intent description that cannot be parsed into a valid swap","Invalid or unsupported chain ID","Payment failure (402) if USDC payment of $0.02 is not included","Rate limiting or worker timeout on high-load requests"],"whenToPreferThis":"Choose this endpoint when you need to translate a human-readable token swap intent into a complete unsigned transaction on Base (chainId 8453) without manually constructing ABI calldata, computing gas, or querying DEX routers. It is ideal for AI agents that receive natural language swap requests and need to produce signable transactions quickly, especially within x402 micropayment-enabled workflows. Prefer alternatives if you need multi-chain support beyond Base, require a signed/broadcast transaction, or need order-book trading rather than AMM-style swaps.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-13T18:35:38.670Z","isFirstParty":false}