{"uid":"cap_5noRgX1aahlyyg1_p7dR2","slug":"crypto-calldata-decoder-x402-660dbb57","name":"Crypto Calldata Decoder (x402)","description":"Pay-per-call crypto microdata for trading/onchain AI agents via x402 (USDC on Base): Base gas, token risk, balances, multi-venue prices, Hyperliquid book/funding, kimchi premium. No API keys.","url":"https://kr-x402-mvp.kgy5612.workers.dev/api/chain/decode?utm_source=zero.xyz","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","properties":{"to":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$","description":"Optional target contract (token) for symbol/decimals + label"},"data":{"type":"string","pattern":"^0x[0-9a-fA-F]{8,}$","examples":["0x095ea7b3000000000000000000000000000000000022d473030f116ddee9f6b43ac78ba3ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"],"description":"Calldata hex (selector + ABI args). Required unless hash given"},"hash":{"type":"string","pattern":"^0x[0-9a-fA-F]{64}$","description":"Optional Base tx hash: decode its input instead of data"}},"additionalProperties":false}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":{"type":"json","example":{"to":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","args":[{"type":"address","value":"0x000000000022D473030F116dDEE9F6B43aC78BA3"},{"type":"uint256","value":"115792089237316195423570985008687907853269984665640564039457584007913129639935"}],"risk":"medium","chain":"base","flags":["unlimited_approval"],"amount":"unlimited","spender":"0x000000000022D473030F116dDEE9F6B43aC78BA3","summary":"lets Uniswap Permit2 move ALL USDC from the signer","verdict":"CAUTION","function":"approve(address,uint256)","guidance":"Review the decoded args; simulate with /crypto/base-rpc?method=eth_call before signing.","selector":"0x095ea7b3","unlimited":true,"spender_label":"Uniswap Permit2","signature_source":"builtin"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","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.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_3W6TfXkHk6Udfhv8vf7Mc","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Decodes raw EVM calldata or a Base transaction hash into human-readable function name, arguments, risk verdict, and security flags — paid per call via x402 USDC micropayment.","exampleAgentPrompt":"Before I sign this transaction, can you decode this calldata — 0x095ea7b3000000000000000000000000000000000022d473030f116ddee9f6b43ac78ba3ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff — for the USDC contract at 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 and tell me if there are any security risks?","exampleUseCases":[{"title":"Safe approval check before signing","prompt":"I'm about to sign an approve transaction on Base. Can you decode this calldata — 0x095ea7b3000000000000000000000000000000000022d473030f116ddee9f6b43ac78ba3ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff — for the contract 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 and tell me whether it's granting unlimited allowance and to whom?"},{"title":"Investigate suspicious Base transaction","prompt":"I just saw a tx on Base with hash 0x4a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6e7f8a9b0c1d2e3f4a5b6c7d8e9f0a1b — can you decode what it actually did and flag any risky behavior like unlimited approvals or suspicious spenders?"},{"title":"Agent pre-flight calldata validation","prompt":"Before my DeFi bot submits this calldata on Base, decode 0xa9059cbb000000000000000000000000abcdef1234567890abcdef1234567890abcdef12000000000000000000000000000000000000000000000000002386f26fc10000 targeting 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913 and confirm what function it's calling, the recipient, and the amount being transferred."}],"resultDescription":"Returns the decoded function name and selector, typed argument list with values, a risk verdict (e.g. CAUTION/OK/DANGER), security flags (e.g. unlimited_approval), a plain-English summary of what the call does, a spender label if recognized, and guidance on next steps. Also indicates whether the approval is unlimited and identifies the target token symbol/decimals when a contract address is supplied.","failureModes":["Invalid or malformed calldata hex returns a decode error","Unknown function selector not in built-in or 4byte database returns partial decode with unknown function name","Unrecognized Base tx hash returns not-found error","Missing required 'data' or 'hash' parameter returns 400 validation error","Payment failure via x402 (insufficient USDC balance) blocks the call"],"whenToPreferThis":"Use this endpoint when an AI agent or user needs to understand what a raw EVM calldata blob or Base transaction actually does before signing or broadcasting — especially for security screening of token approvals, transfers, and DeFi interactions. Prefer this over generic block explorers when you need structured, machine-readable risk verdicts and labeled spender identification in a pay-per-call, no-API-key flow on Base.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-31T18:42:28.358Z","isFirstParty":false,"canonicalSlug":"crypto-calldata-decoder-x402-660dbb57"}