Commodities Data API
Access real-time commodity futures market data with Infoway API. Get live prices, candlestick, trade ticks, and order book data for 30+ futures including precious metals.
Overview
The Infoway Commodity Futures Real-Time Market Data API provides comprehensive data for more than 30 commodity and precious metal futures. The API supports real-time and historical candlestick data, latest trade, and order book depth, helping users track the movements of major futures markets such as gold, silver, oil, and various commodity indices.
1. Retrieving the Commodity Futures List
Infoway’s futures API covers 30 major futures products (including commodity indices). You can obtain the list of available futures products using one of the following methods:
Option 1 — Download from the Web Portal
Log in to your Infoway account and download the latest stock excel list file from the Downloads section at the right side of the dashboard.
Option 2 — Query via API
You can also retrieve the list programmatically through the HTTP Symbol List API. Refer to the GET /symbol-list documentation for usage details.
2. Query Methods
Infoway Commodity Futures API offers two primary data-access methods, optimized for different use cases:
HTTP API
Scheduled or batch queries
Suitable for regular polling or historical data retrieval. Supports requests for fundamentals, historical candlestick data, real-time snapshots, and order book depth.
WebSocket Streaming
Low-latency, continuous updates
Best for low-latency updates and live data feeds. Allows continuous streaming of FX quotes, trades, and depth updates.
3. Market Data Schemas
The Infoway Commodity Futures Real-Time Market Data API supports several types of data queries to help users monitor and analyze market activity.
3.1 Real-Time Candlestick (OHLCV) Data
Access real-time candlestick data for commodity futures, including the open, high, low, close prices, as well as volume and turnover. This data is vital for charting and analyzing price trends over different time intervals.
You can access this data via:
HTTP Request: see GET /candlestick
WebSocket Subscription: see WebSocket /candlestick topic
Example Response
{
"s": "XAGUSD",
"respList": [
{
"t": "1752868800",
"h": "38.22500",
"o": "38.12555",
"l": "38.11850",
"c": "38.16500",
"v": "1003.0",
"vw": "38292.383500",
"pc": "0.12%",
"pca": "0.04450"
}
]
}3.2 Real-Time Trade Ticks
Retrieve the most recent trade details for commodity futures, including price, volume, and transaction direction. This data is essential for tracking individual market transactions and executing high-frequency trading strategies.
Access methods:
HTTP API: GET /trades
WebSocket: Subscribe to /trades
Example Response
{
"s": "XAGUSD",
"t": 1752872345319,
"p": "38.165",
"v": "1.0",
"vw": "38.1650",
"td": 0
}3.3 Real-Time Order Book Depth
Provides the best bid and ask prices along with the available volumes at each price level for commodity futures.
Access methods:
HTTP API: GET /market-depth
WebSocket: Subscribe to /Depth
Example Response
{
"s": "XAGUSD",
"t": 1752975504045,
"a": [
[
"38.18"
],
[
"1"
]
],
"b": [
[
"38.15"
],
[
"1"
]
]
}Last updated
