# FMF Tools EVM Decoder: pay-per-call calldata and log decoder, any chain, no RPC (no API key, MPP) > Pay-per-call EVM decoding for AI agents: decode transaction calldata (including nested multicall/router/Safe calls) and receipt event logs into named, typed arguments; look up 4-byte selectors and event topics; fetch Sourcify-verified ABIs with proxy resolution; encode calldata from a signature. Works for Ethereum, Base, Arbitrum, Optimism, Polygon, BSC, Tempo and any EVM chain. No account or API key: pay per call with MPP on Tempo (USDC.e or pathUSD), from $0.001. Invalid input or upstream failure returns 402 and is not charged. ## Docs (free) - Human docs with copy-paste examples: https://mpp-chain.fmf-x402.workers.dev/docs - OpenAPI 3.1: https://mpp-chain.fmf-x402.workers.dev/openapi.json - This file: https://mpp-chain.fmf-x402.workers.dev/llms.txt - MCP server (Streamable HTTP): https://mpp-chain.fmf-x402.workers.dev/mcp - Health: https://mpp-chain.fmf-x402.workers.dev/health - Attribution counters (no PII): https://mpp-chain.fmf-x402.workers.dev/stats/refs ## How to pay No account and no API key. Unpaid calls receive HTTP 402 with an MPP challenge on Tempo (USDC.e or pathUSD). Official clients pay the challenge and retry automatically. POST JSON (or GET with query params) to any paid route and pay the MPP 402 challenge on Tempo (USDC.e or pathUSD). Bad input or an upstream failure returns 402 with an error and you are not charged. Optional ?ref=channel or header X-FMF-Ref attributes the call for our coverage map (ignored by the tool). ## Quick start mppx CLI (creates/uses a Tempo account in your keychain): ```bash npx mppx https://mpp-chain.fmf-x402.workers.dev/mpp/evm/abi -X POST -H 'content-type: application/json' -d '{"chain_id":1,"address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"}' ``` TypeScript (mppx). After Mppx.create(), global fetch handles 402: ```ts import { Mppx, tempo } from 'mppx/client' import { privateKeyToAccount } from 'viem/accounts' Mppx.create({ methods: [tempo({ account: privateKeyToAccount(process.env.TEMPO_PRIVATE_KEY) })], }) // Global fetch now pays the 402 automatically. const res = await fetch('https://mpp-chain.fmf-x402.workers.dev/mpp/evm/abi', { method: 'POST', headers: { 'content-type': 'application/json', }, body: JSON.stringify({"chain_id":1,"address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"}), }) console.log(await res.json()) ``` Python (pympp): ```python # pip install pympp # Docs: https://mpp.dev/sdk/python import asyncio from mpp.client import Mpp from mpp.methods.tempo import TempoAccount from mpp.methods.tempo import client as tempo account = TempoAccount.from_key("0x...") async def main(): async with Mpp(methods=[tempo.charge(account=account)]) as mpp: response = await mpp.fetch("https://mpp-chain.fmf-x402.workers.dev/mpp/evm/abi", method="POST", json={"chain_id":1,"address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"}) print(await response.json()) asyncio.run(main()) ``` An unpaid curl shows the 402 (you are not charged): ```bash curl -i -X POST https://mpp-chain.fmf-x402.workers.dev/mpp/evm/abi -H 'content-type: application/json' -d '{"chain_id":1,"address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"}' ``` ## MCP Add this to Cursor / Claude Desktop / VS Code MCP settings (Streamable HTTP): ```json { "mcpServers": { "fmf-mpp-chain": { "url": "https://mpp-chain.fmf-x402.workers.dev/mcp" } } } ``` `tools/list` is free. `tools/call` requires an MPP Payment credential in the Authorization header (or just call the HTTP route with mppx). The wrapper does not settle payment on its own and stores nothing. ## Routes - POST https://mpp-chain.fmf-x402.workers.dev/mpp/evm/selector ($0.001) Selector and event-topic lookup (4byte): Look up up to 50 function selectors (4-byte) and/or event topics (32-byte) and get human-readable signatures, verified-contract matches first. Also computes selectors from signatures you pass (e.g. "transfer(address,uint256)"). Drop-in for 4byte / openchain lookups. Example: `npx mppx https://mpp-chain.fmf-x402.workers.dev/mpp/evm/selector -X POST -H 'content-type: application/json' -d '{"function":"0xa9059cbb,0x38ed1739","event":"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef"}'` - POST https://mpp-chain.fmf-x402.workers.dev/mpp/evm/calldata ($0.002) Decode EVM calldata (any chain, no RPC): Decode transaction input data into function name, signature and typed named arguments. Uses your ABI, or the Sourcify-verified ABI for chain_id + address (proxies resolved), or the 4byte signature database with a strict re-encode check. Recursively decodes nested calls (multicall, execute, Safe, routers) up to 2 levels. Example: `npx mppx https://mpp-chain.fmf-x402.workers.dev/mpp/evm/calldata -X POST -H 'content-type: application/json' -d '{"data":"0xa9059cbb000000000000000000000000d8da6bf26964af9d7eed9e03e53415d37aa960450000000000000000000000000000000000000000000000000de0b6b3a7640000"}'` - POST https://mpp-chain.fmf-x402.workers.dev/mpp/evm/logs ($0.002) Decode EVM event logs (any chain, no RPC): Decode up to 50 raw logs ({topics, data, address}) from a receipt into event names and typed arguments. Uses your ABI, a Sourcify-verified ABI (chain_id + address), or the 4byte event database, trying indexed-parameter layouts until one decodes strictly. Example: `npx mppx https://mpp-chain.fmf-x402.workers.dev/mpp/evm/logs -X POST -H 'content-type: application/json' -d '{"logs":[{"address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48","topics":["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef","0x000000000000000000000000d8da6bf26964af9d7eed9e03e53415d37aa96045","0x00000000000000000000000028c6c06298d514db089934071355e5743bf21d60"],"data":"0x00000000000000000000000000000000000000000000000000000000000f4240"}]}'` - POST https://mpp-chain.fmf-x402.workers.dev/mpp/evm/abi ($0.001) Verified contract ABI (Sourcify, any EVM chain): Get the verified ABI, contract name, compiler and match level for a contract on any Sourcify-supported chain, with proxy detection and the implementation ABI merged in. Returns function/event selectors alongside the ABI. Example: `npx mppx https://mpp-chain.fmf-x402.workers.dev/mpp/evm/abi -X POST -H 'content-type: application/json' -d '{"chain_id":1,"address":"0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48"}'` - POST https://mpp-chain.fmf-x402.workers.dev/mpp/evm/encode ($0.001) Encode EVM calldata from a signature: Build 0x calldata from a function signature and arguments (e.g. "transfer(address,uint256)" + ["0x…", "1000000"]). Numbers may be strings; returns selector and calldata ready for eth_call or a transaction. Example: `npx mppx https://mpp-chain.fmf-x402.workers.dev/mpp/evm/encode -X POST -H 'content-type: application/json' -d '{"signature":"transfer(address,uint256)","args":["0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045","1000000000000000000"]}'` ## Sources and licences Sources: Sourcify 4byte signature database (api.4byte.sourcify.dev, open data, successor of openchain.xyz); Sourcify verified contracts (sourcify.dev, open data); decoding by viem (MIT). Responses are cached; nothing you send is stored. ## Sister services - [Doc Tools](https://mpp-docs.fmf-x402.workers.dev/docs?ref=cross-chain): Pay-per-call PDF, Office, OCR, speech-to-text, voice memo and meeting notes - [Web & Data](https://mpp-agent-data.fmf-x402.workers.dev/docs?ref=cross-chain): Pay-per-call scrape, extract, SEC filings, weather and FX - [Utility Tools](https://mpp-tools.fmf-x402.workers.dev/docs?ref=cross-chain): Tempo chain, attestation, QR, DNS, email, IP, geo, timezone, tech detect, math - [AI Tools](https://mpp-ai.fmf-x402.workers.dev/docs?ref=cross-chain): Pay-per-call chat, translation, embeddings and rerank, no API key - [Browser](https://mpp-browser.fmf-x402.workers.dev/docs?ref=cross-chain): Pay-per-call headless Chrome screenshots, JS render and page-to-PDF - [Research](https://mpp-research.fmf-x402.workers.dev/docs?ref=cross-chain): Papers, FDA drug labels, recalls, clinical trials and LEI - [Deepgram-compatible STT](https://mpp-stt.fmf-x402.workers.dev/docs?ref=cross-chain): Drop-in /deepgram/transcribe and /v1/listen speech-to-text at $0.008, no API key - [Compat APIs](https://mpp-compat.fmf-x402.workers.dev/docs?ref=cross-chain): OpenWeather-, Mapbox- and EDGAR-compatible routes at a third of the price (MPP + x402) - [Domain & Web Checks](https://mpp-domain.fmf-x402.workers.dev/docs?ref=cross-chain): RDAP WHOIS, domain age and availability, HTTP status, security headers, SPF/DMARC (MPP + x402) - [Dev & Data Utils](https://mpp-utils.fmf-x402.workers.dev/docs?ref=cross-chain): IBAN, GTIN, ISIN, crypto address, JWT, hash, cron, RRULE, semver, CSV at $0.001 (MPP + x402) - [MTG Sim](https://mtg-sim.fmf-x402.workers.dev/docs?ref=cross-chain): Magic: The Gathering deck check, draw odds, land count and goldfish simulator - [Control-plane](https://controlplane-x402.fmf-x402.workers.dev/docs?ref=cross-chain): Who controls this contract? MPP + x402 snapshots and Tempo token data - [Pokémon TCG Sim](https://pokemon-tcg-sim.fmf-x402.workers.dev/docs?ref=cross-chain): Pokémon TCG simulator: goldfish, prize and draw sims, free Standard/Expanded deck check - [Yu-Gi-Oh Sim](https://yugioh-sim.fmf-x402.workers.dev/docs?ref=cross-chain): Yu-Gi-Oh! simulator: goldfish, combo and hand-trap odds, free TCG/OCG/GOAT banlist deck check - [Crypto Tax Calculator](https://mpp-cryptotax.fmf-x402.workers.dev/docs?ref=cross-chain): Crypto capital gains, cost basis (FIFO/HIFO/ACB), Form 8949 boxes G-L, Canada Schedule 3, tax-loss harvesting - [Business Docs & Data](https://mpp-biz.fmf-x402.workers.dev/docs?ref=cross-chain): Invoice/receipt PDFs with pay-in-crypto QR, payment URIs, phone validation, barcodes - [Lorcana Sim](https://lorcana-sim.fmf-x402.workers.dev/docs?ref=cross-chain): Disney Lorcana simulator: goldfish, ink and draw sims, free Core/Infinity deck check - [One Piece Sim](https://onepiece-sim.fmf-x402.workers.dev/docs?ref=cross-chain): One Piece Card Game simulator: goldfish, DON!! curve, Life and draw odds, free deck check - [Hearthstone Sim](https://hearthstone-sim.fmf-x402.workers.dev/docs?ref=cross-chain): Hearthstone simulator: mulligan odds, curve goldfish, draw odds, free deck check - [Chess Sim](https://chess-sim.fmf-x402.workers.dev/docs?ref=cross-chain): Chess tools: forced-mate finder, best move, legal moves, free opening names and position check - [Dota 2 Sim](https://dota2-sim.fmf-x402.workers.dev/docs?ref=cross-chain): Dota 2 simulator: right-click duel sim, build stats, EHP and DPS calculator - [CS2 Sim](https://cs2-sim.fmf-x402.workers.dev/docs?ref=cross-chain): CS2 economy simulator: loss bonus, buy or eco, half simulation ## Attribution Append `?ref=your-channel` or send header `X-FMF-Ref: your-channel` on any request (including unpaid 402s and /docs). We count hits and paid successes per channel so we can see what actually drives calls. The parameter is ignored by the tool.