# Gas Comparator – Base vs Ethereum Gas Price Oracle

> Gas Comparator – Base vs Ethereum Gas Price Oracle is a paid API for AI agents from lab.paidapis.net, paid per call via x402, $0.01/call, status unknown (last checked 2026-09-15).

Fetches and compares current gas prices on Base and Ethereum mainnet, returning the ratio, delta in Gwei, and ETH/USD price at check time.

## Facts

- Endpoint: GET https://lab.paidapis.net/api/gas-comparator
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/gas-comparator-base-vs-ethereum-gas-price-oracle-77b287dc
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_nvXpXWfzWvK8_EwsWu14E

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 gas-comparator-base-vs-ethereum-gas-price-oracle-77b287dc
```

Example prompt: What are the current gas prices on Base versus Ethereum right now — show me the ratio and the difference in Gwei along with the current ETH/USD price?

## When to prefer this

Use this endpoint when you need a quick, single-call comparison of live gas prices across Base and Ethereum mainnet, especially when you also need the ETH/USD spot price bundled in the same response. It is ideal for agents making routing decisions or surfacing fee information to users, and is cheaper than running your own RPC calls to two separate nodes.

## Known failure modes

- Upstream RPC node unavailable — gas data cannot be fetched, returns error
- Stale data if block producer is slow — checkedAt timestamp may lag real time
- Network connectivity issues to Base or Ethereum nodes resulting in partial data
- Payment validation failure via x402 if USDC balance is insufficient

## How this service works

Cross-chain gas comparator: real, current gas price on Ethereum and Base side by side, with the delta and ratio between them, plus the estimated USD cost of a standard 21,000-gas transfer on each chain (using the live ETH/USD price). No advice or 'cheaper chain' verdict — just the numbers.

## Output

A JSON object containing a Base gas data object, an Ethereum gas data object, the ratio of Base to Ethereum gas prices (number), the delta in Gwei (number), the current ETH/USD price (number), and the ISO timestamp of the data fetch.

## Request schema (JSON Schema)

```json
{
 "properties": {
  "input": {
   "properties": {
    "queryParams": {
     "type": "object",
     "required": [],
     "properties": {}
    }
   }
  },
  "output": {
   "properties": {
    "example": {
     "type": "object",
     "properties": {
      "base": {
       "type": "object"
      },
      "ratio": {
       "type": "number"
      },
      "ethereum": {
       "type": "object"
      },
      "checkedAt": {
       "type": "string"
      },
      "deltaGwei": {
       "type": "number"
      },
      "ethUsdPrice": {
       "type": "number"
      }
     }
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/gas-comparator-base-vs-ethereum-gas-price-oracle-77b287dc/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from lab.paidapis.net](https://www.zero.xyz/host/lab.paidapis.net/llms.txt)
