estimate_gas
chainpeek: Estimate the gas of a transaction on Ethereum, Base or Robinhood Chain. For the gas price use get_gas; for a whole transfer check use transfer_preflight. Returns the node's gas estimate (gas) for a transaction from from to to with data and value_wei, plus gas_with_20pct_buffer; omit to...
This record as markdown: /tools/dev-tanod-tanod/estimate-gas.md
What estimate_gas does on Tanod
AI agents use estimate_gas to create or update resources in Tanod, usually the action step of a workflow, after the agent has gathered context. Every call changes real data in your Tanod environment.
| Parameter | Type | Required | Description |
|---|---|---|---|
to | object | — | Recipient. Omit with `data` to estimate a contract creation. |
data | object | — | Calldata, 0x-hex with an even number of digits, at most 8 kB. |
from | object | — | Sender (affects balance and allowance checks). |
chain | string | Yes | ethereum, base or robinhood (Robinhood Chain, chain id 4663). |
value_wei | object | — | Native value in wei, as a decimal or 0x-hex string. |
Parameters from the server's own tool schema.
Why estimate_gas is rated Medium
An AI agent can call estimate_gas faster than any human can review: one bad instruction and it creates or modifies resources in Tanod by the hundred, each call as confident as the last.
Attacks that exploit this kind of access
The rule that runs estimate_gas safely
PolicyLayer is an MCP gateway: it sits between your AI agents and Tanod, and checks every tool call against a rule you set before the call runs. Nothing changes on the server itself. For estimate_gas, this is the rule to start with:
estimate_gas stays usable, but capped: an agent stuck in a loop can't make hundreds of changes a minute. Everything else on the server is denied unless you say otherwise.
The button opens the PolicyLayer dashboard: create your workspace, connect Tanod, apply this rule, and every estimate_gas call is checked against it from then on.
Questions about estimate_gas
chainpeek: Estimate the gas of a transaction on Ethereum, Base or Robinhood Chain. For the gas price use get_gas; for a whole transfer check use transfer_preflight. Returns the node's gas estimate (gas) for a transaction from from to to with data and value_wei, plus gas_with_20pct_buffer; omit to with data to estimate a contract creation. Nothing is signed or sent. Input: chain, to, optional from, data and value_wei; send to or data. Estimated at the latest block against current state, so the real cost can differ. A transaction that would revert is a 422 reverted (not charged). Ethereum, Base and Robinhood only; read-only: nothing is signed or sent. RPC reads are cached up to 30 s. A bad address, hash, hex string, block or range is a 422 before any payment (not charged). Typically under 1 s. Price: USD 0.002. Free: 10 chain reads per IP per UTC day. Docs: https://tanod.dev/learn/ethereum-rpc-reads-api.html. It is categorised as a Write tool in the Tanod MCP Server, which means it can create or modify data. Consider rate limits to prevent runaway writes.
estimate_gas accepts 5 parameters: to, data, from, chain, value_wei. Required: chain. The full parameter table on this page comes from the server's own tool schema.
Register the Tanod MCP server in PolicyLayer and add a rule for estimate_gas: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Tanod. Nothing to install.
estimate_gas is a Write tool with medium risk. Write tools should be rate-limited to prevent accidental bulk modifications.
Yes. Add a rate_limit block to the estimate_gas rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for estimate_gas. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
estimate_gas is provided by the Tanod MCP server (https://tanod.dev/mcp). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
More on Tanod, and thousands of servers like it.
This server
Across the catalogue