Discover how to get Delhi Gold (XAU-DELH) prices using this API
Discover how to get Delhi Gold (XAU-DELH) prices using this API
In today's fast-paced financial landscape, the ability to access real-time data is crucial for traders and investors alike. One of the most sought-after commodities in the market is gold, represented by the symbol XAU. Understanding how to retrieve and analyze gold prices, particularly in the context of the Delhi market, can empower developers to create innovative applications that cater to the needs of investors. This blog post will delve into the capabilities of the Metals-API, exploring how it can be utilized to access XAU prices and other valuable insights.
About Gold (XAU)
Gold has long been regarded as a safe-haven asset, especially during times of economic uncertainty. With the digital transformation in precious metals trading, the integration of technology has revolutionized how investors access market data. The use of data analytics and market insights allows traders to make informed decisions based on real-time information. The Metals-API plays a pivotal role in this transformation, offering developers the tools needed to build next-generation applications that can provide innovative solutions for price discovery and trading.
As the demand for digital asset solutions grows, the importance of having accurate and timely data cannot be overstated. The Metals-API provides a comprehensive suite of endpoints that enable users to access the latest gold prices, historical data, and even perform currency conversions. By leveraging these capabilities, developers can create applications that not only track gold prices but also analyze trends and fluctuations, providing users with valuable insights into the market.
API Description
The Metals-API is designed to provide real-time and historical data for various metals, including gold, silver, platinum, and palladium. This API empowers developers to build applications that can access crucial market data, enabling them to create tools for investment analysis, trading strategies, and financial forecasting.
One of the standout features of the Metals-API is its ability to deliver real-time exchange rate data. Depending on the subscription plan, users can receive updates every 60 minutes, every 10 minutes, or even more frequently. This ensures that traders have access to the most current information, allowing them to make timely decisions in a volatile market.
Moreover, the API's historical rates endpoint provides access to data dating back to 2019, enabling users to analyze trends over time. This historical perspective is invaluable for understanding market movements and making predictions about future price behavior.
Key Features and Endpoints
The Metals-API offers a variety of endpoints that cater to different needs. Here are some of the key features:
- Latest Rates Endpoint: This endpoint returns real-time exchange rate data for metals, allowing users to stay updated on the latest prices. The response includes the base currency, date, and rates for various metals, including XAU.
- Historical Rates Endpoint: Users can access historical rates for any date since 2019. This feature is essential for conducting trend analysis and understanding past market behavior.
- Bid And Ask Endpoint: This powerful feature provides real-time bid and ask prices for metals, enabling traders to make informed decisions based on current market conditions.
- Convert Endpoint: The conversion endpoint allows users to convert amounts between different metals or to/from USD, making it easier to understand the value of investments.
- Time-Series Endpoint: This endpoint enables users to query daily historical rates between two specified dates, providing a comprehensive view of price movements over time.
- Fluctuation Endpoint: Users can track how prices fluctuate on a day-to-day basis, which is crucial for understanding market volatility.
- Carat Endpoint: This endpoint provides information about gold rates by carat, allowing users to understand the value of gold in different purities.
- Lowest/Highest Price Endpoint: Users can query the API to get the lowest and highest prices for a specified date, which is useful for identifying market extremes.
- Open/High/Low/Close (OHLC) Price Endpoint: This endpoint provides open, high, low, and close prices for a specific time period, essential for technical analysis.
- Historical LME Endpoint: Access historical rates for LME symbols dating back to 2008, providing a broader context for market analysis.
- API Key: Each user is assigned a unique API key that must be included in requests to authenticate access to the API.
- API Response: The API delivers exchange rates relative to USD by default, ensuring consistency in data interpretation.
- Available Endpoints: The Metals-API offers 14 different endpoints, each designed to provide specific functionalities for users.
- Supported Symbols Endpoint: This endpoint returns a constantly updated list of all available currencies and metals, ensuring users have access to the latest data.
- News Endpoint: Retrieve the latest news articles related to various metals, keeping users informed about market developments.
List of Symbols
The Metals-API provides access to a comprehensive range of metal symbols. For a complete list of all supported symbols and their specifications, refer to the Metals-API Supported Symbols page.
API Endpoint Examples and Responses
Understanding the structure of API responses is crucial for effective integration. Here are some examples of the responses you can expect from various endpoints:
Latest Rates Endpoint
{
"success": true,
"timestamp": 1771891881,
"base": "USD",
"date": "2026-02-24",
"rates": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912,
"XPD": 0.000744,
"XCU": 0.294118,
"XAL": 0.434783,
"XNI": 0.142857,
"XZN": 0.344828
},
"unit": "per troy ounce"
}
This response indicates a successful request, providing the latest exchange rates for various metals, including gold (XAU).
Historical Rates Endpoint
{
"success": true,
"timestamp": 1771805481,
"base": "USD",
"date": "2026-02-23",
"rates": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915,
"XPD": 0.000748
},
"unit": "per troy ounce"
}
This example shows how to access historical rates for a specific date, allowing for trend analysis and historical comparisons.
Time-series Endpoint
{
"success": true,
"timeseries": true,
"start_date": "2026-02-17",
"end_date": "2026-02-24",
"base": "USD",
"rates": {
"2026-02-17": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915
},
"2026-02-19": {
"XAU": 0.000483,
"XAG": 0.0382,
"XPT": 0.000913
},
"2026-02-24": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912
}
},
"unit": "per troy ounce"
}
This response illustrates how to retrieve exchange rates for a specific time period, providing a detailed view of price movements over time.
Convert Endpoint
{
"success": true,
"query": {
"from": "USD",
"to": "XAU",
"amount": 1000
},
"info": {
"timestamp": 1771891881,
"rate": 0.000482
},
"result": 0.482,
"unit": "troy ounces"
}
This example demonstrates how to convert an amount from one metal to another, showcasing the API's versatility in handling different currencies.
Fluctuation Endpoint
{
"success": true,
"fluctuation": true,
"start_date": "2026-02-17",
"end_date": "2026-02-24",
"base": "USD",
"rates": {
"XAU": {
"start_rate": 0.000485,
"end_rate": 0.000482,
"change": -3.0e-6,
"change_pct": -0.62
},
"XAG": {
"start_rate": 0.03825,
"end_rate": 0.03815,
"change": -0.0001,
"change_pct": -0.26
},
"XPT": {
"start_rate": 0.000915,
"end_rate": 0.000912,
"change": -3.0e-6,
"change_pct": -0.33
}
},
"unit": "per troy ounce"
}
This response provides insights into how prices fluctuate over a specified period, which is essential for traders looking to capitalize on market movements.
OHLC (Open/High/Low/Close) Price Endpoint
{
"success": true,
"timestamp": 1771891881,
"base": "USD",
"date": "2026-02-24",
"rates": {
"XAU": {
"open": 0.000485,
"high": 0.000487,
"low": 0.000481,
"close": 0.000482
},
"XAG": {
"open": 0.03825,
"high": 0.0383,
"low": 0.0381,
"close": 0.03815
},
"XPT": {
"open": 0.000915,
"high": 0.000918,
"low": 0.00091,
"close": 0.000912
}
},
"unit": "per troy ounce"
}
This endpoint provides critical data for technical analysis, allowing traders to assess market performance over a specific period.
Bid/Ask Endpoint
{
"success": true,
"timestamp": 1771891881,
"base": "USD",
"date": "2026-02-24",
"rates": {
"XAU": {
"bid": 0.000481,
"ask": 0.000483,
"spread": 2.0e-6
},
"XAG": {
"bid": 0.0381,
"ask": 0.0382,
"spread": 0.0001
},
"XPT": {
"bid": 0.000911,
"ask": 0.000913,
"spread": 2.0e-6
}
},
"unit": "per troy ounce"
}
This response provides current bid and ask prices, which are essential for traders looking to execute orders at optimal prices.
Conclusion
The Metals-API is a powerful tool for developers looking to access real-time and historical data for precious metals like gold. By leveraging its extensive features, including the latest rates, historical data, and conversion capabilities, developers can create applications that provide valuable insights and facilitate informed trading decisions. The integration of technology in the precious metals market is transforming how investors interact with data, and the Metals-API stands at the forefront of this evolution.
For more information on how to implement these features and explore the full capabilities of the API, be sure to check the Metals-API Documentation. Additionally, for a complete list of supported symbols, visit the Metals-API Supported Symbols page. Embrace the future of trading with the Metals-API and unlock the potential of real-time metals data.