estimate_gas
Estimate gas for a 0G transaction using recipient address, value, and optional data. Returns gas cost for mainnet or testnet.
Instructions
Estimate gas for a transaction on 0G network
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"to": "<to>"
},
"name": "estimate_gas"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | Recipient address | |
| data | No | Transaction data (optional) | |
| value | No | Value to send in wei | |
| network | No | Network to query (default: testnet) | testnet |