/v1/commodity
One commodity performance card
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/commoditymovers-api/v1/commodity" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/commoditymovers-api/v1/commodity", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/commoditymovers-api/v1/commodity");
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/commoditymovers-api/v1/commodity",
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": {
"key": "gold",
"name": "Gold",
"note": "One commodity's performance card: change on the day, week and month, day high/low, 52-week high/low and where the price sits in its 52-week range (0 = on the low, 100 = at the high).",
"group": "metals",
"price": 4234.3999,
"source": "Yahoo Finance",
"symbol": "GC=F",
"day_low": 4191.1,
"currency": "USD",
"day_high": 4267.8,
"week52_low": 3273.7,
"week52_high": 5318.3999,
"change_1d_pct": 3.52,
"change_1m_pct": -9.86,
"change_1w_pct": -2.37,
"range_position_52w": 47
},
"meta": {
"timestamp": "2026-06-12T10:35:14.000Z",
"request_id": "fd4ae34a-ecf7-4da4-906b-84d24ffafa61"
},
"status": "ok",
"message": "Commodity retrieved successfully",
"success": true
}