Aller au contenu
GET /v1/index

Live value of the Tunindex 20 index

Essayez-le en direct

10 appels gratuits par jour — sans inscription, sans clé API. Passe par la passerelle oanor.

En-têtes personnalisés (facultatif)
api.oanor.com/tunisia-stock-api

Ça marche. Récupérez une clé API et utilisez-la dans votre projet.

Obtenez une clé API

Extraits de code

curl "https://api.oanor.com/tunisia-stock-api/v1/index" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/tunisia-stock-api/v1/index", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/tunisia-stock-api/v1/index");
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/tunisia-stock-api/v1/index",
    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": {
        "low": 8139.07,
        "high": 8207.93,
        "name": "Tunindex 20",
        "note": "The live value of the Tunindex 20 (the Tunis Stock Exchange blue-chip index) — current level, change, and the day's open/high/low. Pass name (TUN20; default TUN20).",
        "open": 8166.98,
        "index": "TUN20",
        "value": 8180.69,
        "change": 15.319999999999709,
        "source": "Tunis Stock Exchange / BVMT (TradingView)",
        "change_percent": 0.19
    },
    "meta": {
        "timestamp": "2026-06-15T02:10:23.603Z",
        "request_id": "bedcee7f-16d1-41f8-a392-8d4d4468ff9f"
    },
    "status": "ok",
    "message": "Index retrieved successfully",
    "success": true
}