The Easiest Way to Get LME Lead (LME-LEAD) Historical Rates Using Public APIs
The Easiest Way to Get LME Lead (LME-LEAD) Historical Rates Using Public APIs
In today's fast-paced digital landscape, accessing real-time data is crucial for developers and businesses alike. One area where this is particularly important is in the metals market, where fluctuations in prices can significantly impact financial decisions. If you're looking to obtain historical prices for Lead (symbol: XLE) using public APIs, the Metals-API is a powerful tool that can help you achieve this with ease. This blog post will guide you through the process of retrieving historical rates for Lead, including example endpoints, parameters, and data formats.
About Lead (XLE)
Lead is a versatile metal used in various industries, including construction, batteries, and radiation shielding. As the world moves towards digital transformation, the metal markets are also evolving. Technological innovations and advancements in data analytics are enabling businesses to make informed decisions based on real-time data. The integration of smart technology in the metals market is paving the way for future trends, such as automated trading and predictive analytics.
With the rise of data-driven decision-making, having access to accurate historical data is essential. The Metals-API provides developers with the tools needed to access this information seamlessly. By leveraging the API's capabilities, you can gain insights into market trends, analyze price fluctuations, and make informed decisions based on historical data.
API Description
The Metals-API is a comprehensive solution for accessing metals prices and currency conversion data. It empowers developers to build next-generation applications that require real-time and historical data. With a user-friendly interface and extensive documentation, the Metals-API allows you to integrate metals data into your applications effortlessly.
For more information, you can visit the Metals-API Website or check out the Metals-API Documentation for detailed guidance on using the API.
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: Depending on your subscription plan, this endpoint provides real-time exchange rate data updated every 60 minutes or every 10 minutes. This is particularly useful for applications that require up-to-the-minute pricing information.
- Historical Rates Endpoint: Access historical rates for most metals dating back to 2019. You can query the API for historical rates by appending a specific date to the endpoint.
- Bid and Ask Endpoint: This powerful feature enables you to retrieve real-time bid and ask prices, allowing for more informed trading decisions.
- Convert Endpoint: Use this endpoint to convert any amount from one metal to another or to/from USD, making it easy to handle transactions across different currencies.
- Time-Series Endpoint: Query the API for daily historical rates between two dates of your choice, providing a comprehensive view of price movements over time.
- Fluctuation Endpoint: Retrieve information about how metals fluctuate on a day-to-day basis, which is essential for understanding market volatility.
- Lowest/Highest Price Endpoint: This endpoint allows you to query the API to get the lowest and highest price for a specified date.
- Open/High/Low/Close (OHLC) Price Endpoint: Get detailed OHLC data for a specific time period, which is crucial for technical analysis.
- Historical LME Endpoint: Access historical rates for LME symbols dating back to 2008, providing a long-term view of price trends.
- API Key: Your unique API key is required to access the API, ensuring secure and authorized usage.
- API Response: The API delivers exchange rates relative to USD, with all data returned in a structured JSON format.
- Supported Symbols Endpoint: This endpoint returns all available currencies, allowing you to stay updated on the latest symbols.
- News Endpoint: Retrieve the latest news articles related to various metals, keeping you 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
To give you a clearer understanding of how to use the Metals-API, here are some example endpoints and their corresponding JSON responses:
Latest Rates Endpoint
Get real-time exchange rates for all available metals.
{
"success": true,
"timestamp": 1764313262,
"base": "USD",
"date": "2025-11-28",
"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"
}
Historical Rates Endpoint
Access historical exchange rates for any date since 1999.
{
"success": true,
"timestamp": 1764226862,
"base": "USD",
"date": "2025-11-27",
"rates": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915,
"XPD": 0.000748
},
"unit": "per troy ounce"
}
Time-series Endpoint
Get exchange rates for a specific time period.
{
"success": true,
"timeseries": true,
"start_date": "2025-11-21",
"end_date": "2025-11-28",
"base": "USD",
"rates": {
"2025-11-21": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915
},
"2025-11-23": {
"XAU": 0.000483,
"XAG": 0.0382,
"XPT": 0.000913
},
"2025-11-28": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912
}
},
"unit": "per troy ounce"
}
Convert Endpoint
Convert any amount from one metal to another or to/from USD.
{
"success": true,
"query": {
"from": "USD",
"to": "XAU",
"amount": 1000
},
"info": {
"timestamp": 1764313262,
"rate": 0.000482
},
"result": 0.482,
"unit": "troy ounces"
}
Fluctuation Endpoint
Track rate fluctuations between two dates.
{
"success": true,
"fluctuation": true,
"start_date": "2025-11-21",
"end_date": "2025-11-28",
"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"
}
OHLC (Open/High/Low/Close) Endpoint
Get OHLC data for a specific time period.
{
"success": true,
"timestamp": 1764313262,
"base": "USD",
"date": "2025-11-28",
"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"
}
Bid/Ask Endpoint
Get current bid and ask prices for metals.
{
"success": true,
"timestamp": 1764313262,
"base": "USD",
"date": "2025-11-28",
"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"
}
Conclusion
Accessing historical rates for Lead (XLE) using the Metals-API is a straightforward process that can empower developers to create innovative applications in the metals market. By utilizing the various endpoints offered by the API, you can gain valuable insights into price trends, fluctuations, and market dynamics. Whether you're building a trading platform, conducting market analysis, or simply seeking to understand the metals market better, the Metals-API provides the tools you need.
For further exploration, refer to the Metals-API Documentation for detailed guidance on implementation and usage. Additionally, the Metals-API Supported Symbols page offers a comprehensive list of available symbols to enhance your data retrieval capabilities.
In a world where data is king, leveraging APIs like Metals-API can provide a significant competitive advantage. Embrace the future of data-driven decision-making in the metals market and unlock the potential of real-time insights.