> ## Documentation Index
> Fetch the complete documentation index at: https://docs.financialdatapi.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Energy & commodities

> Official energy market data from the US EIA, covering spot prices, inventories, production and refining, in the same observation model as macro.

Financial Data API carries official **energy and commodity** series from the U.S. Energy Information Administration (EIA): benchmark spot prices, stock levels, production, and refining activity. They sit under the `commodities` category and flow through the same observation envelope, freshness gating, and provenance as macro indicators, so an oil-inventory print joins cleanly against CPI, rates, or positioning.

## What data is available

<CardGroup cols={2}>
  <Card title="energy_spot_price" icon="gas-pump">
    Benchmark energy spot prices — for example WTI and Brent crude, and Henry Hub natural gas.
  </Card>

  <Card title="product_spot_price" icon="droplet">
    Refined product spot prices — for example NY Harbor gasoline and distillate.
  </Card>

  <Card title="energy_inventory" icon="warehouse">
    Stock levels — crude oil, gasoline, distillate, and natural gas inventories.
  </Card>

  <Card title="energy_production" icon="industry">
    Production volumes — for example US crude oil production.
  </Card>

  <Card title="refinery_throughput" icon="gauge-high">
    Refinery inputs / throughput.
  </Card>

  <Card title="refinery_utilization" icon="gauge">
    Refinery capacity utilization.
  </Card>
</CardGroup>

<Info>
  These are global-commodity series, so most carry no `country` (the value is a market benchmark, not a national statistic). The specific product or benchmark is identified in the observation metadata and provenance. The publisher is the U.S. Energy Information Administration.
</Info>

## Query energy data

<CodeGroup>
  ```bash cURL theme={"theme":"css-variables"}
  # Latest reading for a series
  curl "https://api.financialdatapi.com/observations/latest?indicator_id=energy_spot_price" \
    -H "x-api-key: $FINANCIALDATA_API_KEY"

  # Inventory history
  curl "https://api.financialdatapi.com/observations?indicator_id=energy_inventory&limit=20&order=desc" \
    -H "x-api-key: $FINANCIALDATA_API_KEY"
  ```

  ```typescript TypeScript theme={"theme":"css-variables"}
  import { FinancialDataApiClient } from "@financialdatapi/client";

  const client = new FinancialDataApiClient({ apiKey: process.env.FINANCIALDATA_API_KEY });

  const { data } = await client.getLatestObservations({ indicator_id: "energy_spot_price" });
  console.log(data);
  ```
</CodeGroup>

## Response shape

Each row is a standard public observation. The fields most relevant here:

<ResponseField name="indicatorId" type="string">One of the series above, for example `energy_inventory`.</ResponseField>
<ResponseField name="category" type="string">`commodities`.</ResponseField>
<ResponseField name="actual" type="number">The value (price, volume, or percent depending on the series).</ResponseField>
<ResponseField name="unit" type="string">For example dollars per barrel, million barrels, or percent.</ResponseField>
<ResponseField name="provider" type="string">`U.S. Energy Information Administration`.</ResponseField>
<ResponseField name="periodEnd" type="string">The period the reading describes.</ResponseField>

<Tip>
  The exact benchmark or product (WTI vs Brent, gasoline vs distillate, crude vs natural gas) is carried in the observation metadata. Read it from the row, or trace it with `GET /provenance/observations/{observationId}`.
</Tip>

## Related

<Columns cols={3}>
  <Card title="Positioning" icon="layer-group" href="/apis/positioning">
    CFTC futures positioning, including energy contracts.
  </Card>

  <Card title="Provenance" icon="link" href="/concepts/provenance">
    Trace any value to its EIA release.
  </Card>
</Columns>
