{"uid":"cap_chacDRTtJAHhD0ylfAlxQ","slug":"skills-onesource-io-1296d0a9","name":"skills.onesource.io Gas Estimator","description":"Estimate the gas a transaction will consume via eth_estimateGas before signing it","url":"https://skills.onesource.io/api/chain/estimate-gas","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"to":{"type":"string","pattern":"^0x[a-fA-F0-9]{40}$"},"data":{"type":"string","pattern":"^0x[a-fA-F0-9]+$"},"from":{"type":"string","pattern":"^0x[a-fA-F0-9]{40}$"},"value":{"type":"string","pattern":"^0x[a-fA-F0-9]+$"}}},"responseSchema":{"type":"object","required":["data","meta"],"properties":{"data":{"type":"object","required":["gas"],"properties":{"gas":{"type":"string"}}},"meta":{"type":"object","required":["endpoint","request_id"],"properties":{"endpoint":{"type":"string"},"request_id":{"type":"string"}}}}},"example":{"request":{"to":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045","from":"0x0000000000000000000000000000000000000001","value":"0x0"},"response":{"data":{"gas":"0x52eb"},"meta":{"endpoint":"/api/chain/estimate-gas","request_id":"c023ea0cafbead8d"}}},"exampleRequest":{"to":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045","from":"0x0000000000000000000000000000000000000001","value":"0x0"},"tags":["x402"],"displayCostAmount":"0.004000","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","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.004000/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.004","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.004","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_EltcKwJaODSJsCByOG1HG","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.004","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Estimates the gas a transaction will consume on Ethereum via eth_estimateGas before it is signed or broadcast","exampleAgentPrompt":"Before I sign this transaction, estimate how much gas it will consume — it's a call to contract 0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48 from my wallet 0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045 with calldata 0xa9059cbb000000000000000000000000d8da6bf26964af9d7eed9e03e53415d37aa9604500000000000000000000000000000000000000000000000000000000000f4240 and value 0x0.","exampleUseCases":null,"resultDescription":"Returns the estimated number of gas units the transaction will consume, computed via eth_estimateGas against the live Ethereum RPC — useful for setting gas limits before signing.","failureModes":["Transaction would revert on-chain: estimateGas returns an error indicating execution failure","Invalid hex address or data format: returns 400 validation error","Missing required 'to' or 'data' fields for contract calls: incomplete response or error","Network or RPC unavailability: returns 5xx or timeout","Insufficient balance for 'from' address causes simulation failure"],"whenToPreferThis":"Use this endpoint when you need a quick, accurate gas estimate for an Ethereum transaction before signing — especially before sending ETH, calling smart contracts, or performing ERC20 transfers. Prefer it over static gas limits when you want to avoid overpaying or out-of-gas failures.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T06:52:03.764Z","isFirstParty":false}