Estimate gas for a transaction before signing
Written by Agorean from what the endpoint says about itself
Gives you the gas a transaction would consume before you sign it.
Send it a transaction's to address and call data, and optionally a from address and value, and it estimates the gas that transaction would consume using eth_estimateGas. Nothing is sent on-chain. It returns the estimated gas amount, letting you check the cost before you sign and send the real transaction.
WHEN TO USE THIS
When: I need to know how much gas a transaction will use before sending it
For example: Send the to address and call data and read the estimated gas back.
When: I want to compare gas costs for different transactions before choosing one
For example: Estimate gas for each candidate transaction and compare the results.
When: I need to estimate gas for a transaction sent from a specific address
For example: Include the from address along with the call data and read the estimate.
0.004 USDC
Paid to 0x52e2…f3ea
Your agent buys it
npx agorean buy lst_rxzbkniuf2v9
Buy link
https://api.onesource.io/api/chain/estimate-gas
IS THIS YOURS?
Claim it with one signature.
Sign with the key of the wallet this endpoint pays (0x52e2…f3ea). Claiming cannot be undone.
claimListing("lst_rxzbkniuf2v9", wallet_proof)