/v1/status
Live line status for a mode
Provalo dal vivo
10 chiamate gratuite al giorno — senza registrazione, senza chiave API. Passa dal gateway oanor.
Funziona. Prendi una chiave API e usala nel tuo progetto.
Ottieni una chiave APIFrammenti di codice
curl "https://api.oanor.com/tfl-api/v1/status" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/tfl-api/v1/status", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/tfl-api/v1/status");
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/tfl-api/v1/status",
headers={"x-oanor-key": "oanor_test_..."}
)
Risposta di esempio
Una risposta reale di questo endpoint, acquisita dall'ultimo health check.
{
"data": {
"mode": "tube",
"count": 11,
"lines": [
{
"id": "bakerloo",
"mode": "tube",
"name": "Bakerloo",
"status": [
{
"reason": "BAKERLOO LINE: Saturday 30 and Sunday 31 May, no service between Queens Park and Harrow & Wealdstone. There will also be no LIONESS LINE service between Euston and Watford Junction. A very limited SOUTHERN service will continue to serve Wembley Central early and late on Saturday and on Sunday, and LONDON NORTH WESTERN RAILWAY trains stop at Harrow & Wealdstone. If travelling to Wembley for the Rugby League Challenge Cup Finals on Saturday or the Women's FA Cup Final on Sunday. Special bus service 718 operates.",
"severity": 5,
"description": "Part Closure"
},
{
"reason": "Bakerloo Line: Service will resume later this morning.\r\n ",
"severity": 20,
"description": "Service Closed"
}
],
"disruptions": []
},
{
"id": "central",
"mode": "tube",
"name": "Central",
"status": [
{
"reason": "Central Line: Service will resume later this morning.\r\n ",
"severity": 20,
"description": "Service Closed"
}
],
"disruptions": []
},
{
"id": "circle",
"mode": "tube",
"name": "Circle",
"status": [
{
"reason": "Circle Line: Service will resume later this morning.\r\n ",
"severity": 20,
"description": "Service Closed"
}
],
"disruptions": []
},
{
"id": "district",
"mode": "tube",
"name": "District",
"status": [
{
"reason": "District Line: Service will resume later this morning.\r\n ",
"severity": 20,
"description": "Service Closed"
}
],
"disruptions": []
},
{
"id": "hammersmith-city",
"mode": "tube",
"name": "Hammersmith & City",
"status": [
{
"reason": "Hammersmith and City Line: Service will resume later this morning.\r\n ",
"severity": 20,
"description": "Service Closed"
}
],
…