Estimate gas for a built EVM swap
estimate_gasEstimate gas costs for unsigned EVM swap transactions without signing or sending. Uses transaction data from build_swap to provide gas estimates.
Instructions
Estimate the gas cost of an unsigned EVM transaction produced by build_swap. Read-only: nothing is signed or sent.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | Transaction target — the "to" field from build_swap. | |
| data | Yes | Calldata from build_swap. | |
| from | Yes | Address that would send the transaction. | |
| value | No | Native value as a hex quantity. | 0x0 |
| chain_id | Yes | EVM chain id from build_swap. | |
| token_in | Yes | Address of the input token (zero address for native). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| gas_price | Yes | Gas price in wei, decimal string. | |
| estimated_gas | Yes | Gas units, decimal string. | |
| estimated_fee_wei | Yes |