# Zerion Gas Prices API

> Zerion Gas Prices API is a paid API for AI agents from api.zerion.io, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-02).

Retrieves current gas prices across multiple EVM chains and Solana, filterable by chain and gas type (classic, EIP-1559, optimistic).

## Facts

- Endpoint: GET https://api.zerion.io/v1/gas-prices?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/zerion-gas-prices-api-0242dd9b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_kj_WkBpyYewEBAlhU0Mot

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 zerion-gas-prices-api-0242dd9b
```

Example prompt: What are the current gas prices on Ethereum and Polygon right now — give me both classic and EIP-1559 rates so I can figure out the cheapest time to send my transaction?

## When to prefer this

Use this endpoint when you need real-time gas price data across 40+ EVM chains and Solana with support for classic, EIP-1559, and optimistic gas models. Prefer this over raw RPC calls when you want interpreted, normalized gas price data without managing individual chain RPC connections. Best when your agent needs to compare fees across chains or time transactions optimally.

## Known failure modes

- Invalid chain_id values return empty data or 400 error
- Unsupported gas_types values may return empty results
- Rate limiting or payment failure returns 402 requiring USDC payment
- Network timeout if upstream chain data is unavailable
- Malformed query parameters return 400 Bad Request

## How this service works

Interpreted wallet data for more than 40 chains and Solana: portfolios, DeFi positions, PnL, transactions and NFTs. REST for apps, x402 pay-per-call for agents.

## Output

Returns an array of JSON:API resource objects, each containing a chain ID, resource type, and gas price attributes (e.g. base fee, priority fee, classic gas price) for the requested chains and gas types, plus pagination/self links.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "filter[chain_ids]": {
       "type": "string",
       "description": "Comma-separated chain IDs; omit for all chains"
      },
      "filter[gas_types]": {
       "type": "string",
       "description": "Comma-separated gas types: classic, eip1559, optimistic"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "data"
     ],
     "properties": {
      "data": {
       "type": "array",
       "items": {
        "type": "object",
        "properties": {
         "id": {
          "type": "string",
          "description": "Resource ID."
         },
         "type": {
          "type": "string",
          "description": "Resource type."
         },
         "attributes": {
          "type": "object",
          "description": "Resource attributes; see https://developers.zerion.io"
         }
        }
       },
       "description": "Array of JSON:API resource objects."
      },
      "links": {
       "type": "object",
       "description": "Self and pagination links."
      }
     }
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "data": [
   {
    "id": "<resource id>",
    "type": "<resource type>",
    "attributes": {}
   }
  ],
  "links": {
   "self": "https://api.zerion.io/v1/..."
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/zerion-gas-prices-api-0242dd9b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.zerion.io](https://www.zero.xyz/host/api.zerion.io/llms.txt)
