Retrieve Tin - LME 3-month (TIN3M) Historical Prices using this API

Retrieve Tin - LME 3-month (TIN3M) Historical Prices using this API
In the ever-evolving landscape of metal markets, the demand for accurate and timely data has never been greater. For developers and analysts looking to retrieve historical prices for Tin (symbol: TIN3M), the Metals-API offers a robust solution. This blog post will delve into the intricacies of Tin, explore the capabilities of the Metals-API, and provide a comprehensive guide on how to access historical prices effectively.
About Tin (XSN)
Tin, represented by the symbol XSN, is a vital metal in various industries, including electronics, automotive, and construction. As we witness a digital transformation in metal markets, the integration of technology and data analytics is reshaping how we interact with metal pricing. The advancements in smart technology have enabled real-time tracking of metal prices, allowing businesses to make informed decisions based on accurate data.
Technological innovation has paved the way for new possibilities in the metal market. With the rise of data analytics, stakeholders can gain insights into market trends, price fluctuations, and demand forecasts. This data-driven approach not only enhances operational efficiency but also provides a competitive edge in a rapidly changing environment.
As we look to the future, the integration of smart technologies will continue to influence the metal markets. The potential for automation, machine learning, and predictive analytics will enable businesses to respond swiftly to market changes, ensuring they remain agile and competitive.
API Description
The Metals-API is a powerful tool designed to provide developers with real-time and historical data on metal prices. This API empowers users to build next-generation applications that leverage accurate and timely information. With a focus on innovation and technological advancement, the Metals-API transforms how we access and utilize metals data.
One of the standout features of the Metals-API is its ability to deliver real-time exchange rate data. Depending on your subscription plan, the API can update this information every 60 minutes, every 10 minutes, or even more frequently. This capability is crucial for businesses that rely on up-to-the-minute pricing to make informed decisions.
For those interested in historical data, the Metals-API provides access to historical rates dating back to 2019. By appending a specific date to your query, you can retrieve historical prices for Tin and other metals, allowing for comprehensive analysis and reporting.
To explore the full capabilities of the Metals-API, visit the Metals-API Website and check out the Metals-API Documentation for detailed information on how to implement these features.
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 provides real-time exchange rate data for all available metals. Depending on your subscription plan, you can receive updates every 60 minutes, 10 minutes, or even more frequently. This feature is essential for businesses that require immediate access to current market prices.
- Historical Rates Endpoint: Access historical exchange rates for any date since 2019. This endpoint allows you to analyze price trends over time, which is particularly useful for forecasting and strategic planning.
- Bid And Ask Endpoint: This powerful feature enables you to retrieve real-time bid and ask prices for metals. Understanding the bid-ask spread is crucial for traders and investors looking to make informed decisions.
- Convert Endpoint: The Metals-API includes a currency conversion endpoint, allowing you to convert any amount from one metal to another or to/from USD. This feature simplifies transactions and helps users understand the value of metals in different currencies.
- Time-Series Endpoint: This endpoint allows you to query the API for daily historical rates between two dates of your choice. This is particularly useful for analyzing trends and fluctuations over specific periods.
- Fluctuation Endpoint: Retrieve information about how metal prices fluctuate on a day-to-day basis. This endpoint provides insights into market volatility, helping businesses manage risk effectively.
- Carat Endpoint: This feature allows you to retrieve information about gold rates by carat, which is essential for jewelers and gold traders.
- Lowest/Highest Price Endpoint: Query the API to get the lowest and highest price for a specific metal over a defined period. This information is valuable for understanding market extremes.
- Open/High/Low/Close (OHLC) Price Endpoint: This endpoint provides open, high, low, and close prices for a specific time period, allowing for detailed market analysis.
- Historical LME Endpoint: Access historical rates for LME symbols dating back to 2008. This endpoint is particularly useful for those involved in trading and investment.
- API Key: Your API Key is essential for accessing the Metals-API. It must be included in the API base URL's access_key parameter to authenticate your requests.
- API Response: The exchange rates delivered by the Metals-API are by default relative to USD. All data is returned in a structured JSON format, making it easy to integrate into applications.
- Available Endpoints: The Metals-API provides a comprehensive list of endpoints, each offering different functionalities. For a complete overview, refer to the Metals-API Supported Symbols.
- Gold Price India Endpoint: Retrieve the latest gold price in India using this dedicated endpoint, which is particularly useful for local traders.
- News Endpoint: Stay updated with the latest news articles related to various metals, helping you stay informed about market trends and developments.
API Endpoint Examples and Responses
To illustrate the capabilities of the Metals-API, here are some examples of API responses for various endpoints:
Latest Rates Endpoint
{
"success": true,
"timestamp": 1746162076,
"base": "USD",
"date": "2025-05-02",
"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 that the API successfully retrieved the latest rates for various metals, with the base currency being USD. Each rate is expressed in terms of troy ounces.
Historical Rates Endpoint
{
"success": true,
"timestamp": 1746075676,
"base": "USD",
"date": "2025-05-01",
"rates": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915,
"XPD": 0.000748
},
"unit": "per troy ounce"
}
This example shows a successful retrieval of historical rates for a specific date. Users can analyze these rates to understand price movements over time.
Time-series Endpoint
{
"success": true,
"timeseries": true,
"start_date": "2025-04-25",
"end_date": "2025-05-02",
"base": "USD",
"rates": {
"2025-04-25": {
"XAU": 0.000485,
"XAG": 0.03825,
"XPT": 0.000915
},
"2025-04-27": {
"XAU": 0.000483,
"XAG": 0.0382,
"XPT": 0.000913
},
"2025-05-02": {
"XAU": 0.000482,
"XAG": 0.03815,
"XPT": 0.000912
}
},
"unit": "per troy ounce"
}
The time-series response provides daily rates for a specified period, allowing users to visualize trends and fluctuations in metal prices.
Convert Endpoint
{
"success": true,
"query": {
"from": "USD",
"to": "XAU",
"amount": 1000
},
"info": {
"timestamp": 1746162076,
"rate": 0.000482
},
"result": 0.482,
"unit": "troy ounces"
}
This response illustrates the conversion of an amount from USD to gold (XAU). The result indicates how much gold can be purchased with the specified USD amount.
Fluctuation Endpoint
{
"success": true,
"fluctuation": true,
"start_date": "2025-04-25",
"end_date": "2025-05-02",
"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"
}
The fluctuation endpoint provides insights into how metal prices have changed over a specified period, including both absolute and percentage changes.
OHLC (Open/High/Low/Close) Price Endpoint
{
"success": true,
"timestamp": 1746162076,
"base": "USD",
"date": "2025-05-02",
"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 response provides the open, high, low, and close prices for a specific date, which is essential for traders looking to analyze market performance.
Bid/Ask Endpoint
{
"success": true,
"timestamp": 1746162076,
"base": "USD",
"date": "2025-05-02",
"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"
}
The bid/ask endpoint provides current bid and ask prices for metals, along with the spread, which is crucial for traders making buy or sell decisions.
Conclusion
The Metals-API is an invaluable resource for developers and analysts seeking to retrieve historical prices for Tin and other metals. With its comprehensive set of features, including real-time rates, historical data, and various endpoints, the API empowers users to make informed decisions based on accurate and timely information.
As the metal markets continue to evolve, the integration of technology and data analytics will play a pivotal role in shaping the future of trading and investment. By leveraging the capabilities of the Metals-API, businesses can stay ahead of the curve and capitalize on emerging trends.
For more information on how to implement these features, refer to the Metals-API Documentation and explore the Metals-API Supported Symbols for a complete list of available metals. Visit the Metals-API Website to get started today.