{"uid":"cap_v0u2iWApnz31-Hmitqfc3","slug":"blockchain-gas-estimation-api-3499d369","name":"Blockchain Gas Estimation API","description":"Use when you need the gas a transaction would consume on Base, Ethereum, Arbitrum, Optimism or Polygon before signing it: pass from, to, optional calldata and value (wei). Returns the estimate and the cost at the current gas price.","url":"https://biosfera.46-62-215-147.sslip.io/o/estimate-gas?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","required":["chain","from","to"],"properties":{"to":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"data":{"type":"string","pattern":"^0x[0-9a-fA-F]{0,1000}$"},"from":{"type":"string","pattern":"^0x[0-9a-fA-F]{40}$"},"chain":{"enum":["base","ethereum","arbitrum","optimism","polygon"],"type":"string"},"value":{"type":"string","pattern":"^[0-9]{1,30}$"}},"additionalProperties":false}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.0015","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.0015/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0015","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.0015","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_XzQaAGH69OY0e8Tdt0OU3","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.0015","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Estimates the gas a transaction would consume and its cost at the current gas price on Base, Ethereum, Arbitrum, Optimism, or Polygon.","exampleAgentPrompt":"Before I sign anything, estimate how much gas the transaction from 0xAbCd...1234 to 0x5678...EfGh will use on Base, and what it'll cost at the current gas price — it's a plain ETH transfer with no calldata.","exampleUseCases":[{"title":"Pre-flight gas check for ETH transfer","prompt":"How much gas will it cost to send ETH from 0xABCD1234abcd1234abcd1234abcd1234abcd1234 to 0x9876fedc9876fedc9876fedc9876fedc9876fedc on Ethereum? No calldata, value is 1000000000000000000 wei."},{"title":"Smart contract call gas preview","prompt":"Estimate the gas needed for a contract call on Arbitrum — from address 0x1111222233334444555566667777888899990000 to 0xDeAdBeEfDeAdBeEfDeAdBeEfDeAdBeEfDeAdBeEf with calldata 0xa9059cbb000000000000000000000000abcdef1234567890abcdef1234567890abcdef12 and value 0."},{"title":"DeFi transaction cost estimation before approval","prompt":"Before I approve and swap on Polygon, can you estimate how much gas the transaction from 0xAAAABBBBCCCCDDDDEEEEFFFF0000111122223333 to 0x0000000022D53366457F9d5E68Ec105046FC4383 would consume, with calldata 0x095ea7b3 and no ETH value?"}],"resultDescription":"Returns the estimated gas units the transaction would consume and the estimated cost in wei (or equivalent native token) at the current gas price on the specified chain.","failureModes":["Invalid Ethereum address format for 'from' or 'to' — must be 0x followed by 40 hex characters","Unsupported chain value — must be one of base, ethereum, arbitrum, optimism, polygon","Malformed or oversized calldata — must be 0x-prefixed hex up to 1000 hex chars","Transaction would revert on-chain — simulation fails and no estimate is returned","RPC node unavailable for the requested chain — upstream connection error","Missing required parameters (chain, from, to) returns a validation error"],"whenToPreferThis":"Choose this endpoint when you need to estimate gas consumption and cost for a specific transaction before broadcasting it, especially when you have the sender address, recipient, optional calldata, and optional value. It covers five major EVM chains in one call. Prefer it over generic gas price endpoints when you need transaction-specific gas units rather than just network gas prices, and when you want to avoid signing a transaction that may fail or be unexpectedly expensive.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-01T12:52:01.803Z","isFirstParty":false,"canonicalSlug":"blockchain-gas-estimation-api-3499d369"}