{"uid":"cap_NoGqVzoElk696-f4DyMc9","slug":"evm-gas-estimator-d95e1bf3","name":"EVM Gas Estimator","description":"Use when an agent is about to sign a transaction and must know whether it will fail and what it will cost: the gas this exact call needs, the current gas price, the cost in ether, and wouldRevert, which says the transaction would fail before you spend anything finding out. Do not use for the price of a plain transfer (/v1/evm/gas) or for EIP-1559 caps (/v1/evm/fees). No API key, no account.","url":"https://flat-rate-llm.kikoribera03.workers.dev/v1/evm/estimate-gas?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","required":["to"],"properties":{"to":{"type":"string","description":"Destination address."},"data":{"type":"string","description":"Optional 0x calldata."},"from":{"type":"string","description":"Sender address."},"chain":{"type":"string","description":"base | ethereum | polygon | arbitrum | optimism."},"value":{"type":"string","description":"Optional value in wei, as a decimal string."}}},"responseSchema":{"type":"object","properties":{"gas":{"type":"number"},"costEther":{"type":"number"},"gasPriceWei":{"type":"string"},"wouldRevert":{"type":"boolean"}}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","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.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_0PxjAX6chaBMq9pLuiujm","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Estimates the gas units and cost for an EVM transaction before signing, detecting reverts without broadcasting.","exampleAgentPrompt":"Before I sign anything, can you estimate how much gas and ether it would cost to call this contract on Base — sending to 0xAbCd...1234 with calldata 0xa9059cbb...0000 from 0x1111...2222?","exampleUseCases":[{"title":"Pre-flight check before token transfer","prompt":"Estimate the gas cost for transferring 100 USDC on Polygon — the recipient is 0xRecipient...5678, my wallet is 0xMySender...1234, and the calldata is 0xa9059cbb... — I want to know if it'll succeed and what it'll cost in ether before I sign."},{"title":"Detect reverting contract call","prompt":"I want to call a DeFi contract on Arbitrum at 0xDeFiContract...9999 with this calldata: 0xdeadbeef... — can you run a gas estimate from my address 0xMySender...1234 and tell me if it would revert?"},{"title":"Budget gas costs for agent automation","prompt":"How much gas would I need to send 0.5 ETH to 0xPayee...4321 on Ethereum mainnet? Give me the gas units and total cost in ether so I can plan the budget before the transaction goes out."}],"resultDescription":"Returns the estimated gas units needed, the current gas price in wei, and the total cost denominated in ether. Also returns a wouldRevert boolean flag indicating whether the call would fail if broadcast, making it the cheapest way to detect reverts before committing.","failureModes":["Invalid or malformed 'to' address returns an error","Unknown or unsupported chain name causes rejection","Calldata that references non-existent contract functions may cause wouldRevert=true","Network congestion may cause gas price to drift between estimate and actual submission","Missing required 'to' field returns a 400-level error"],"whenToPreferThis":"Choose this endpoint when you need to pre-flight an EVM transaction on Base, Ethereum, Polygon, Arbitrum, or Optimism without broadcasting it. It is ideal for cost estimation before signing, detecting reverts cheaply, and building gas budgets for automated agent workflows. Prefer it over on-chain simulation tools when you want a simple, flat-rate API call with no wallet SDK dependency.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-04T12:36:06.588Z","isFirstParty":false,"canonicalSlug":"evm-gas-estimator-d95e1bf3"}