/v1/commodities
The supported commodity futures and their roots
Essayez-le en direct
10 appels gratuits par jour — sans inscription, sans clé API. Passe par la passerelle oanor.
Ça marche. Récupérez une clé API et utilisez-la dans votre projet.
Obtenez une clé APIExtraits de code
curl "https://api.oanor.com/commoditycurve-api/v1/commodities" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/commoditycurve-api/v1/commodities", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/commoditycurve-api/v1/commodities");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
"https://api.oanor.com/commoditycurve-api/v1/commodities",
headers={"x-oanor-key": "oanor_test_..."}
)
Exemple de réponse
Une réponse réelle de ce endpoint, capturée lors du dernier contrôle de santé.
{
"data": {
"note": "The commodity futures the term-structure curve covers. Pass commodity= to /v1/curve.",
"count": 9,
"source": "Yahoo Finance",
"commodities": [
{
"name": "Crude Oil (WTI)",
"root": "CL",
"unit": "$/bbl",
"exchange": "NYM",
"commodity": "oil"
},
{
"name": "Natural Gas",
"root": "NG",
"unit": "$/MMBtu",
"exchange": "NYM",
"commodity": "natgas"
},
{
"name": "Gasoline RBOB",
"root": "RB",
"unit": "$/gal",
"exchange": "NYM",
"commodity": "gasoline"
},
{
"name": "Gold",
"root": "GC",
"unit": "$/oz",
"exchange": "CMX",
"commodity": "gold"
},
{
"name": "Silver",
"root": "SI",
"unit": "$/oz",
"exchange": "CMX",
"commodity": "silver"
},
{
"name": "Copper",
"root": "HG",
"unit": "$/lb",
"exchange": "CMX",
"commodity": "copper"
},
{
"name": "Corn",
"root": "ZC",
"unit": "cents/bu",
"exchange": "CBT",
"commodity": "corn"
},
{
"name": "Wheat",
"root": "ZW",
"unit": "cents/bu",
"exchange": "CBT",
"commodity": "wheat"
},
{
"name": "Soybeans",
"root": "ZS",
"unit": "cents/bu",
"exchange": "CBT",
"commodity": "soybeans"
}
]
},
"meta": {
"timestamp": "2026-06-12T10:34:34.092Z",
"request_id": "67b1468d-59f4-43dd-87de-6ce5d89cfe82"
},
"status": "ok",
"message": "Commodities retrieved successfully",
"success": true
}