# Base Gas Estimate

> Base Gas Estimate is a paid API for AI agents from agent-data-tools.revmesh2074.workers.dev, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-24).

Estimates the gas units and ETH cost a transaction would consume on the Base blockchain using eth_estimateGas at the current gas price

## Facts

- Endpoint: GET https://agent-data-tools.revmesh2074.workers.dev/base/estimate-gas?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-24
- Activations on Zero: 0
- Provider: agent-data-tools.revmesh2074.workers.dev
- Website: https://agent-data-tools.revmesh2074.workers.dev
- Canonical page: https://www.zero.xyz/c/agent-data-tools-revmesh2074-workers-dev-base-gas-estimate-a5f36b0c
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_R3eCaxXmaBv8sEnkVY_3o

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability agent-data-tools-revmesh2074-workers-dev-base-gas-estimate-a5f36b0c
```

Example prompt: Before I send ETH to 0xAbCd1234...5678 on Base, can you estimate how much gas it'll use and what it'll cost in ETH right now?

## When to prefer this

Use this endpoint when you need to estimate the gas cost of a specific transaction on Base before submitting it, especially for contract calls where gas usage depends on calldata and sender state. Prefer this over base_gas (which only returns the current gas price) when you need the full cost estimate for a particular transaction. Ideal for pre-flight checks, batch pricing, and detecting reverts before they happen on-chain.

## Known failure modes

- 422 Unprocessable Entity — transaction would revert on-chain; response body contains the revert reason string
- Invalid 'to' address format causes a 400 or validation error
- Malformed calldata in 'data' field may cause a revert or parsing error
- Network congestion or RPC unavailability may cause timeouts
- Missing required 'to' parameter returns an error

## How this service works

Estimate the gas a transaction would use on Base (eth_estimateGas) and what it would cost at the current gas price, in gas units, gwei and ETH. Give to, plus value in ETH and calldata for a contract call, and the sender when the call depends on it. Use before sending a transaction or to price a batch; for the gas price alone use base_gas. A transaction that would revert is 422 with the reason, uncharged.

## Output

Returns an object with the estimated gas units, current gas price in gwei, total transaction cost in ETH, the sender and recipient addresses, the ETH value being sent, the block number at which the estimate was made, and the chain name and ID. If the transaction would revert, returns HTTP 422 with the revert reason (and no charge is applied).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "to"
 ],
 "properties": {
  "to": {
   "type": "string",
   "description": "0x recipient or contract address"
  },
  "data": {
   "type": "string",
   "description": "Optional 0x calldata for a contract call"
  },
  "from": {
   "type": "string",
   "description": "0x sender address (default: an empty address)"
  },
  "value": {
   "type": "string",
   "description": "Amount of ETH to send, in ETH (default 0)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "to": {
   "type": "string"
  },
  "gas": {
   "type": "string"
  },
  "cost": {
   "type": "string"
  },
  "from": {
   "type": "string"
  },
  "block": {
   "type": "number"
  },
  "chain": {
   "type": "string"
  },
  "value": {
   "type": "string"
  },
  "symbol": {
   "type": "string"
  },
  "chainId": {
   "type": "number"
  },
  "gasPriceGwei": {
   "type": "string"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent-data-tools-revmesh2074-workers-dev-base-gas-estimate-a5f36b0c/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent-data-tools.revmesh2074.workers.dev](https://www.zero.xyz/host/agent-data-tools.revmesh2074.workers.dev/llms.txt)
