Naar de inhoud
GET /v1/estimate

Estimate blood alcohol (Widmark)

Probeer het live

10 gratis calls per dag — geen registratie, geen API-key. Loopt via de oanor-gateway.

Aangepaste headers (optioneel)
api.oanor.com/bac-api

Het werkt. Haal een API-key op en gebruik hem in je project.

Verkrijg een API-sleutel

Codefragmenten

curl "https://api.oanor.com/bac-api/v1/estimate" \
  -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/bac-api/v1/estimate", {
  headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/bac-api/v1/estimate");
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/bac-api/v1/estimate",
    headers={"x-oanor-key": "oanor_test_..."}
)

Voorbeeldrespons

Een echte respons van dit endpoint, vastgelegd bij de laatste health check.

{
    "data": {
        "input": {
            "r": 0.68,
            "sex": "male",
            "hours": 1,
            "weight_kg": 80,
            "alcohol_grams": 42,
            "beta_per_mille_per_hour": 0.15
        },
        "status": "impaired (over many EU limits)",
        "disclaimer": "Rough estimate for education only — never use to decide whether it is safe or legal to drive. When in doubt, do not drive.",
        "peak_permille": 0.772,
        "current_permille": 0.622,
        "peak_bac_percent": 0.0772,
        "current_bac_percent": 0.0622,
        "legal_limit_permille": 0.5,
        "hours_until_under_limit": 0.81,
        "hours_until_sober_from_peak": 5.15
    },
    "meta": {
        "timestamp": "2026-06-03T17:42:00.321Z",
        "request_id": "e2256413-f403-4fe1-b5e5-0c9ee9e1b4fe"
    },
    "status": "ok",
    "message": "Estimate blood alcohol",
    "success": true
}