The Easiest Way to Get Illuvium (ILV) Historical Rates via Web Scraping
In the rapidly evolving world of digital finance, having access to accurate and timely data is crucial for making informed decisions. One of the most effective ways to obtain historical prices for metals like Gold (XAU), Silver (XAG), Platinum (XPT), and Palladium (XPD) is through the Metals-API. This blog post will guide you through the easiest way to get historical rates for these metals using web scraping techniques, focusing on the capabilities of the Metals-API.
Understanding Metals-API
The Metals-API is a powerful tool designed to provide real-time and historical data on various metals. It offers a comprehensive suite of endpoints that allow developers to access a wealth of information, including current rates, historical prices, and even fluctuations over time. This API is particularly useful for developers looking to integrate metal price data into their applications, whether for trading, analysis, or reporting purposes.
About Tellurium (TE)
While this blog focuses on metals like Gold and Silver, it's worth noting the broader context of digital transformation in metal markets. The integration of smart technology and data analytics is reshaping how traders and investors interact with metal markets. With the rise of technological innovation, the ability to access real-time data and historical insights has become a game-changer. The Metals-API exemplifies this shift, empowering developers to create applications that leverage data analytics for smarter decision-making.
API Capabilities and Features
The Metals-API provides a variety of endpoints, each serving a unique purpose. Understanding these endpoints is essential for effectively utilizing the API to retrieve historical rates. Here are some of the key features:
- Latest Rates Endpoint: This endpoint provides real-time exchange rate data for metals, updated based on your subscription plan. Depending on your plan, you can receive updates every 60 minutes or even more frequently.
- Historical Rates Endpoint: Access historical rates dating back to 2019 by appending a specific date in the format YYYY-MM-DD. This is particularly useful for analyzing trends over time.
- Bid and Ask Endpoint: Retrieve real-time bid and ask prices, which are crucial for traders looking to make informed buying and selling decisions.
- Convert Endpoint: This feature allows you to convert amounts between different metals or to/from USD, making it easier to handle transactions in various currencies.
- Time-Series Endpoint: Query for daily historical rates between two specified dates, allowing for in-depth analysis of price movements over time.
- Fluctuation Endpoint: Track how metal prices fluctuate on a day-to-day basis, providing insights into market volatility.
- Open/High/Low/Close (OHLC) Price Endpoint: Get detailed OHLC data for specific time periods, which is essential for technical analysis.
- Historical LME Endpoint: Access historical rates for LME symbols dating back to 2008, useful for those interested in long-term trends.
- API Key: Your unique API key is required to authenticate requests, ensuring secure access to the API's features.
- API Response: The API returns exchange rates relative to USD by default, with all data formatted in JSON for easy integration.
- Supported Symbols Endpoint: This endpoint provides a constantly updated list of all available metal symbols, ensuring you have the latest information.
- News Endpoint: Retrieve the latest news articles related to various metals, keeping you informed about market developments.
Getting Started with Metals-API
To begin using the Metals-API, you first need to sign up for an account and obtain your API key. This key is essential for authenticating your requests. Once you have your key, you can start making requests to the various endpoints.
Example Endpoints and Responses
Here are some examples of how to use the Metals-API to retrieve data:
Latest Rates Endpoint
To get real-time exchange rates for all available metals, you can use the following endpoint:
GET https://metals-api.com/api/latest?access_key=YOUR_API_KEY
Example Response:
{
"success": true,
"timestamp": 1774620453,
"base": "USD",
"date": "2026-03-27",
"rates": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912,
"XPD": 0.000744
},
"unit": "per troy ounce"
}
Historical Rates Endpoint
To access historical exchange rates for a specific date, use the following endpoint:
GET https://metals-api.com/api/historical?access_key=YOUR_API_KEY&date=YYYY-MM-DD
Example Response:
{
"success": true,
"timestamp": 1774534053,
"base": "USD",
"date": "2026-03-26",
"rates": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915,
"XPD": 0.000748
},
"unit": "per troy ounce"
}
Time-Series Endpoint
To get exchange rates for a specific time period, use the time-series endpoint:
GET https://metals-api.com/api/timeseries?access_key=YOUR_API_KEY&start_date=YYYY-MM-DD&end_date=YYYY-MM-DD
Example Response:
{
"success": true,
"timeseries": true,
"start_date": "2026-03-20",
"end_date": "2026-03-27",
"base": "USD",
"rates": {
"2026-03-20": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915
},
"2026-03-22": {
"XAU": 0.000483,
"XAG": 0.0382,
"XPT": 0.000913
},
"2026-03-27": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912
}
},
"unit": "per troy ounce"
}
Convert Endpoint
To convert amounts between different metals or to/from USD, use the convert endpoint:
GET https://metals-api.com/api/convert?access_key=YOUR_API_KEY&from=USD&to=XAU&amount=1000
Example Response:
{
"success": true,
"query": {
"from": "USD",
"to": "XAU",
"amount": 1000
},
"info": {
"timestamp": 1774620453,
"rate": 0.000482
},
"result": 0.482,
"unit": "troy ounces"
}
Fluctuation Endpoint
To track rate fluctuations between two dates, use the fluctuation endpoint:
GET https://metals-api.com/api/fluctuation?access_key=YOUR_API_KEY&start_date=YYYY-MM-DD&end_date=YYYY-MM-DD
Example Response:
{
"success": true,
"fluctuation": true,
"start_date": "2026-03-20",
"end_date": "2026-03-27",
"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) Price Endpoint
To get OHLC data for a specific time period, use the following endpoint:
GET https://metals-api.com/api/open-high-low-close?access_key=YOUR_API_KEY&date=YYYY-MM-DD
Example Response:
{
"success": true,
"timestamp": 1774620453,
"base": "USD",
"date": "2026-03-27",
"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
To get current bid and ask prices for metals, use the bid/ask endpoint:
GET https://metals-api.com/api/bid-ask?access_key=YOUR_API_KEY
Example Response:
{
"success": true,
"timestamp": 1774620453,
"base": "USD",
"date": "2026-03-27",
"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
The Metals-API is an invaluable resource for developers seeking to access historical rates and real-time data for various metals. By leveraging the API's extensive features, developers can create applications that provide insights into market trends, facilitate trading, and enhance financial analysis. With endpoints for historical rates, fluctuations, and conversion, the Metals-API empowers users to make data-driven decisions in the ever-changing landscape of metal markets.
For more detailed information, refer to the Metals-API Documentation and explore the Metals-API Supported Symbols for a complete list of available metals. Embrace the future of metal trading with the transformative capabilities of the Metals-API.