Estimate gas
evm_estimate_gasUse 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. $0.005 per call, paid over x402 (USDC).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | Destination address. | |
| data | No | Optional 0x calldata. | |
| from | No | Sender address. | |
| chain | No | base | ethereum | polygon | arbitrum | optimism. | |
| value | No | Optional value in wei, as a decimal string. |