# EIA Petroleum Prices & Stocks

> EIA Petroleum Prices & Stocks is a paid API for AI agents from payai.agentstools.dev, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-12).

Returns US petroleum market data including retail gasoline/diesel prices by PADD region, WTI/Brent crude spot prices, and weekly crude/gasoline/distillate inventory levels from the EIA.

## Facts

- Endpoint: GET https://payai.agentstools.dev/energy/petroleum?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/eia-petroleum-prices-stocks-7e29cd2f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_coyfDdLnE3yu6TtOUGYIY

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 eia-petroleum-prices-stocks-7e29cd2f
```

Example prompt: What's the latest retail gasoline price on the West Coast, including the last 8 weeks of history and how it compares to the national average?

## When to prefer this

Use this endpoint when you need official US government EIA petroleum data — retail pump prices, crude oil benchmarks, or inventory stocks — with built-in regional breakdowns, period-over-period change, and short historical series in a single call. Prefer over scraping EIA directly or using financial data APIs when you need structured, agent-ready JSON with PADD region spreads included.

## Known failure modes

- Invalid metric enum value returns 422 unprocessable entity
- Invalid region enum value returns 422 unprocessable entity
- History value outside 1-120 range returns 422 validation error
- EIA source data temporarily unavailable may return 503 or stale data
- Payment not provided or insufficient returns 402 Payment Required

## How this service works

US petroleum prices and stocks from the EIA: retail gasoline and diesel by PADD region (weekly), WTI and Brent crude spot (daily), and weekly crude/gasoline/distillate inventories. Returns latest value, change vs prior period, short history, and a region-vs-US spread.

## Output

Returns the latest value for the requested petroleum metric, the change versus the prior period, a short history array of recent data points (up to 120), and for regional metrics a spread versus the US average. Covers retail gas and diesel by PADD region (weekly), WTI and Brent crude spot prices (daily), and crude/gasoline/distillate inventory stocks (weekly).

## 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",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "metric": {
       "enum": [
        "gas_prices",
        "diesel_prices",
        "crude_wti",
        "crude_brent",
        "crude_stocks",
        "gasoline_stocks",
        "distillate_stocks"
       ],
       "type": "string",
       "description": "Which petroleum series to return (default gas_prices)"
      },
      "region": {
       "enum": [
        "us",
        "east_coast",
        "midwest",
        "gulf_coast",
        "rocky_mountain",
        "west_coast"
       ],
       "type": "string",
       "description": "PADD region for retail gasoline/diesel (default us)"
      },
      "history": {
       "type": "integer",
       "maximum": 120,
       "minimum": 1,
       "description": "Number of recent data points to include"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/eia-petroleum-prices-stocks-7e29cd2f/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from payai.agentstools.dev](https://www.zero.xyz/host/payai.agentstools.dev/llms.txt)
