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

# Commodity Price API

> Latest, historical, intraday and time-series prices for metals, oil, agricultural and other commodities.

![](https://mintcdn.com/webrouter/Wx0iBZkUGX_VAFTN/logo/data-apis/commoditypriceapi.webp?fit=max\&auto=format\&n=Wx0iBZkUGX_VAFTN\&q=85\&s=8ba5078b4177f6715f9e59f900eb54f6)

[Web Catalog · Finance](https://docs.webrouter.net/data-apis.md?category=finance)

Needs&#x20;

`COMMODITYPRICEAPI_API_KEY`

Endpoints

8

Auth

Key in header

[Vendor docs](https://commoditypriceapi.com/docs)

&#x20;·&#x20;

[Pricing](https://commoditypriceapi.com/pricing)

## Setup

| Variable | | What it is |
| - | - | - |
| `COMMODITYPRICEAPI_API_KEY` | required | a Commodity Price API key (commoditypriceapi.com dashboard) |

Put them in your environment or `.env`; [Data APIs](https://docs.webrouter.net/vendors.md) covers the other ways.

## Notes

* Every 2xx response counts against the monthly quota; 4xx and 5xx do not.
* Symbols are case-insensitive codes (XAU, WTIOIL-FUT, BRENTOIL-SPOT); list them with commoditypriceapi.symbols. Unrecognised symbols come back under 'unresolved' with status 206.
* Each plan caps symbols per request; going over returns 402. Endpoints a plan does not include also return 402.
* The quote currency parameter is ignored on the Basic and legacy Lite plans.

## Endpoints

GET

Get latest commodity prices

Latest prices for one or more commodities.

[Open](#commoditypriceapi-rates-latest)

GET

Get real-time price of one commodity

Per-second price of one of the main metals or oil benchmarks, optionally per gram, tola or carat.

[Open](#commoditypriceapi-rates-latest-symbol)

GET

Get commodity prices on a date

Prices for one or more commodities on a past date (from 1990-01-01).

[Open](#commoditypriceapi-rates-historical)

GET

Get commodity price time series

Daily prices for one or more commodities over a date range of up to 365 days.

[Open](#commoditypriceapi-rates-time-series)

GET

Get commodity price change between dates

Start and end price and change for one or more commodities between two dates.

[Open](#commoditypriceapi-rates-fluctuation)

GET

Get intraday commodity prices

Intraday bars for one commodity on one UTC day.

[Open](#commoditypriceapi-rates-intraday)

GET

List commodity symbols

Supported symbols, optionally filtered by underlying or contract type.

[Open](#commoditypriceapi-symbols)

GET

Get API usage

The key's plan and quota usage.

[Open](#commoditypriceapi-usage)

### Get latest commodity prices

GET

`/rates/latest`

`commoditypriceapi.rates.latest`

Latest prices for one or more commodities.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`symbols` required</td><td>string</td><td>query</td><td>Comma-separated symbols. Example `XAU,WTIOIL-FUT`</td></tr>
    <tr><td>`quote`</td><td>string</td><td>query</td><td>Quote currency; defaults to each commodity's own currency. Example `EUR`</td></tr>

    <tr>
      <td>
        `metadata`
      </td>

      <td>
        boolean
      </td>

      <td>
        query
      </td>

      <td>
        Include metadata; default true.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://commoditypriceapi.com/docs) · Same job: [Alpha Vantage](https://docs.webrouter.net/data-apis/alphavantage.md#alphavantage-quote), [Binance](https://docs.webrouter.net/data-apis/binance.md#binance-ticker-24hr), [Coinbase Exchange](https://docs.webrouter.net/data-apis/coinbase-exchange.md#coinbase-exchange-stats-get), [CoinMarketCap](https://docs.webrouter.net/data-apis/coinmarketcap.md#coinmarketcap-global-metrics-latest), [EODHD](https://docs.webrouter.net/data-apis/eodhd.md#eodhd-live-quote), [Financial Datasets](https://docs.webrouter.net/data-apis/financialdatasets.md#financialdatasets-prices-snapshot)

```python Python theme={null}
router.call_data_api("commoditypriceapi.rates.latest", {'symbols': 'XAU,WTIOIL-FUT', 'quote': 'EUR'})
```

```text MCP theme={null}
call_data_api(endpoint="commoditypriceapi.rates.latest", params={"symbols": "XAU,WTIOIL-FUT", "quote": "EUR"})
```

> [!NOTE]
>
> * Prices may be delayed up to 10 minutes depending on the plan.

### Get real-time price of one commodity

GET

`/rates/latest/{symbol}`

`commoditypriceapi.rates.latest_symbol`

Per-second price of one of the main metals or oil benchmarks, optionally per gram, tola or carat.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`symbol` required</td><td>string</td><td>path</td><td>Commodity symbol. One of `XAU`, `XAG`, `WTIOIL-SPOT`, `WTIOIL-FUT`, `BRENTOIL-SPOT`, `BRENTOIL-FUT`, `XCU-SPOT`, `XCU-FUT`, `XPT`, `XPD` Example `XAU`</td></tr>

    <tr>
      <td>
        `quote`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Quote currency.
      </td>
    </tr>

    <tr>
      <td>
        `include`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Extra units: gram or tola for XAG, XPT, XPD; gram, tola or carat for XAU; none for copper or oil.
      </td>
    </tr>

    <tr>
      <td>
        `metadata`
      </td>

      <td>
        boolean
      </td>

      <td>
        query
      </td>

      <td>
        Include metadata; default true.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://commoditypriceapi.com/docs) · Same job: [Alpha Vantage](https://docs.webrouter.net/data-apis/alphavantage.md#alphavantage-quote), [Binance](https://docs.webrouter.net/data-apis/binance.md#binance-ticker-24hr), [Coinbase Exchange](https://docs.webrouter.net/data-apis/coinbase-exchange.md#coinbase-exchange-stats-get), [CoinMarketCap](https://docs.webrouter.net/data-apis/coinmarketcap.md#coinmarketcap-global-metrics-latest), [EODHD](https://docs.webrouter.net/data-apis/eodhd.md#eodhd-live-quote), [Financial Datasets](https://docs.webrouter.net/data-apis/financialdatasets.md#financialdatasets-prices-snapshot)

```python Python theme={null}
router.call_data_api("commoditypriceapi.rates.latest_symbol", {'symbol': 'XAU'})
```

```text MCP theme={null}
call_data_api(endpoint="commoditypriceapi.rates.latest_symbol", params={"symbol": "XAU"})
```

### Get commodity prices on a date

GET

`/rates/historical`

`commoditypriceapi.rates.historical`

Prices for one or more commodities on a past date (from 1990-01-01).

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`symbols` required</td><td>string</td><td>query</td><td>Comma-separated symbols. Example `XAU`</td></tr>
    <tr><td>`date` required</td><td>string</td><td>query</td><td>Date, YYYY-MM-DD. Example `2024-01-15`</td></tr>
  </tbody>
</table>

[Vendor docs](https://commoditypriceapi.com/docs) · Same job: [Alpha Vantage](https://docs.webrouter.net/data-apis/alphavantage.md#alphavantage-daily), [Bank of Canada](https://docs.webrouter.net/data-apis/bankofcanada.md#bankofcanada-observations-series), [Bank of England](https://docs.webrouter.net/data-apis/bankofengland.md#bankofengland-series-csv), [Binance](https://docs.webrouter.net/data-apis/binance.md#binance-klines), [Coinbase Exchange](https://docs.webrouter.net/data-apis/coinbase-exchange.md#coinbase-exchange-candles-get), [CoinGecko](https://docs.webrouter.net/data-apis/coingecko.md#coingecko-coins-market-chart)

```python Python theme={null}
router.call_data_api("commoditypriceapi.rates.historical", {'symbols': 'XAU', 'date': '2024-01-15'})
```

```text MCP theme={null}
call_data_api(endpoint="commoditypriceapi.rates.historical", params={"symbols": "XAU", "date": "2024-01-15"})
```

> [!NOTE]
>
> * Falls back to the last earlier rate; 404 RATE\_NOT\_FOUND when there is none.

### Get commodity price time series

GET

`/rates/time-series`

`commoditypriceapi.rates.time_series`

Daily prices for one or more commodities over a date range of up to 365 days.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`symbols` required</td><td>string</td><td>query</td><td>Comma-separated symbols. Example `XAU`</td></tr>
    <tr><td>`startDate` required</td><td>string</td><td>query</td><td>Start date, YYYY-MM-DD. Example `2024-01-01`</td></tr>
    <tr><td>`endDate` required</td><td>string</td><td>query</td><td>End date, YYYY-MM-DD; at most 365 days after startDate. Example `2024-03-31`</td></tr>
  </tbody>
</table>

[Vendor docs](https://commoditypriceapi.com/docs) · Same job: [Alpha Vantage](https://docs.webrouter.net/data-apis/alphavantage.md#alphavantage-daily), [Bank of Canada](https://docs.webrouter.net/data-apis/bankofcanada.md#bankofcanada-observations-series), [Bank of England](https://docs.webrouter.net/data-apis/bankofengland.md#bankofengland-series-csv), [Binance](https://docs.webrouter.net/data-apis/binance.md#binance-klines), [Coinbase Exchange](https://docs.webrouter.net/data-apis/coinbase-exchange.md#coinbase-exchange-candles-get), [CoinGecko](https://docs.webrouter.net/data-apis/coingecko.md#coingecko-coins-market-chart)

```python Python theme={null}
router.call_data_api("commoditypriceapi.rates.time_series", {'symbols': 'XAU', 'startDate': '2024-01-01', 'endDate': '2024-03-31'})
```

```text MCP theme={null}
call_data_api(endpoint="commoditypriceapi.rates.time_series", params={"symbols": "XAU", "startDate": "2024-01-01", "endDate": "2024-03-31"})
```

> [!NOTE]
>
> * Standard, Advanced and Enterprise plans only; Basic gets 402.

### Get commodity price change between dates

GET

`/rates/fluctuation`

`commoditypriceapi.rates.fluctuation`

Start and end price and change for one or more commodities between two dates.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`symbols` required</td><td>string</td><td>query</td><td>Comma-separated symbols. Example `XAU`</td></tr>

    <tr>
      <td>
        `startDate`

        required
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Start date, YYYY-MM-DD.
      </td>
    </tr>

    <tr>
      <td>
        `endDate`

        required
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        End date, YYYY-MM-DD.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://commoditypriceapi.com/docs) · Same job: [Alpha Vantage](https://docs.webrouter.net/data-apis/alphavantage.md#alphavantage-daily), [Bank of Canada](https://docs.webrouter.net/data-apis/bankofcanada.md#bankofcanada-observations-series), [Bank of England](https://docs.webrouter.net/data-apis/bankofengland.md#bankofengland-series-csv), [Binance](https://docs.webrouter.net/data-apis/binance.md#binance-klines), [Coinbase Exchange](https://docs.webrouter.net/data-apis/coinbase-exchange.md#coinbase-exchange-candles-get), [CoinGecko](https://docs.webrouter.net/data-apis/coingecko.md#coingecko-coins-market-chart)

> [!NOTE]
>
> * Standard, Advanced and Enterprise plans only; Basic gets 402. No range limit.

### Get intraday commodity prices

GET

`/rates/intraday`

`commoditypriceapi.rates.intraday`

Intraday bars for one commodity on one UTC day.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr><td>`symbols` required</td><td>string</td><td>query</td><td>Exactly one symbol. Example `XAU`</td></tr>
    <tr><td>`interval` required</td><td>string</td><td>query</td><td>Bar interval. One of `1m`, `5m`, `10m`, `15m`, `30m`, `45m`, `1h`, `2h`, `4h`, `8h`, `12h`, `1d` Example `1h`</td></tr>
    <tr><td>`date` required</td><td>string</td><td>query</td><td>UTC date, YYYY-MM-DD, not in the future. Example `2026-11-06`</td></tr>

    <tr>
      <td>
        `startTime`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        HH:mm UTC on an interval mark; default 00:00. Pass the response's nextStartTime to page.
      </td>
    </tr>

    <tr>
      <td>
        `metadata`
      </td>

      <td>
        boolean
      </td>

      <td>
        query
      </td>

      <td>
        Include metadata; default true.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://commoditypriceapi.com/docs) · Same job: [Alpha Vantage](https://docs.webrouter.net/data-apis/alphavantage.md#alphavantage-daily), [Bank of Canada](https://docs.webrouter.net/data-apis/bankofcanada.md#bankofcanada-observations-series), [Bank of England](https://docs.webrouter.net/data-apis/bankofengland.md#bankofengland-series-csv), [Binance](https://docs.webrouter.net/data-apis/binance.md#binance-klines), [Coinbase Exchange](https://docs.webrouter.net/data-apis/coinbase-exchange.md#coinbase-exchange-candles-get), [CoinGecko](https://docs.webrouter.net/data-apis/coingecko.md#coingecko-coins-market-chart)

```python Python theme={null}
router.call_data_api("commoditypriceapi.rates.intraday", {'symbols': 'XAU', 'interval': '1h', 'date': '2026-11-06'})
```

```text MCP theme={null}
call_data_api(endpoint="commoditypriceapi.rates.intraday", params={"symbols": "XAU", "interval": "1h", "date": "2026-11-06"})
```

> [!NOTE]
>
> * Advanced and Enterprise plans only (402 otherwise, not counted).
> * At most 100 points per response; page with nextStartTime.
> * Only for symbols updated every second, minute or 10 minutes; others return 400.

### List commodity symbols

GET

`/symbols`

`commoditypriceapi.symbols`

Supported symbols, optionally filtered by underlying or contract type.

Input

<table>
  <thead>
    <tr>
      <th>
        Name
      </th>

      <th>
        Type
      </th>

      <th>
        In
      </th>

      <th>
        Notes
      </th>
    </tr>
  </thead>

  <tbody>
    <tr>
      <td>
        `underlying`
      </td>

      <td>
        string
      </td>

      <td>
        query
      </td>

      <td>
        Filter by underlying, e.g. WTIOIL-FUT.
      </td>
    </tr>

    <tr><td>`contract`</td><td>string</td><td>query</td><td>Filter by contract type. One of `futures`, `spot`</td></tr>

    <tr>
      <td>
        `includeExpired`
      </td>

      <td>
        boolean
      </td>

      <td>
        query
      </td>

      <td>
        Include expired contracts; default false.
      </td>
    </tr>
  </tbody>
</table>

[Vendor docs](https://commoditypriceapi.com/docs) · Same job: [Binance](https://docs.webrouter.net/data-apis/binance.md#binance-exchange-info), [Coinbase Exchange](https://docs.webrouter.net/data-apis/coinbase-exchange.md#coinbase-exchange-products-list), [CoinMarketCap](https://docs.webrouter.net/data-apis/coinmarketcap.md#coinmarketcap-cryptocurrency-map), [Fixer](https://docs.webrouter.net/data-apis/fixer.md#fixer-symbols), [OANDA](https://docs.webrouter.net/data-apis/oanda.md#oanda-instruments-list), [Open Exchange Rates](https://docs.webrouter.net/data-apis/open-exchange-rates.md#open-exchange-rates-currencies)

```python Python theme={null}
router.call_data_api("commoditypriceapi.symbols")
```

```text MCP theme={null}
call_data_api(endpoint="commoditypriceapi.symbols")
```

### Get API usage

GET

`/usage`

`commoditypriceapi.usage`

The key's plan and quota usage.

Input

No inputs.

[Vendor docs](https://commoditypriceapi.com/docs)

```python Python theme={null}
router.call_data_api("commoditypriceapi.usage")
```

```text MCP theme={null}
call_data_api(endpoint="commoditypriceapi.usage")
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.