/v1/between
Duration between two instants
Live testen
10 freie Calls pro Tag — keine Anmeldung, kein API-Key. Geht durchs oanor-Gateway.
Funktioniert. Hol dir einen API-Key und nutze sie in deinem Projekt.
API-Key holenCode-Snippets
curl "https://api.oanor.com/duration-api/v1/between" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/duration-api/v1/between", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/duration-api/v1/between");
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/duration-api/v1/between",
headers={"x-oanor-key": "oanor_test_..."}
)
Beispiel-Response
Echte Antwort dieses Endpoints, erfasst beim letzten Health-Check.
{
"data": {
"end": "2026-01-02T03:04:05.000Z",
"start": "2026-01-01T00:00:00.000Z",
"iso8601": "P1DT3H4M5S",
"direction": "end after start",
"humanized": "1 day, 3 hours, 4 minutes and 5 seconds",
"components": {
"days": 1,
"hours": 3,
"weeks": 0,
"years": 0,
"months": 0,
"minutes": 4,
"seconds": 5
},
"total_seconds": 97445,
"total_milliseconds": 97445000
},
"meta": {
"timestamp": "2026-06-02T16:51:50.004Z",
"request_id": "d61a2d5d-14cb-4610-813d-ff77c7b9d490"
},
"status": "ok",
"message": "Duration between two instants",
"success": true
}