Zum Inhalt springen
GET /v1/baluster-count

Balusters for a code-safe gap

Live testen

10 freie Calls pro Tag — keine Anmeldung, kein API-Key. Geht durchs oanor-Gateway.

Eigene Header (optional)
api.oanor.com/handrail-api

Funktioniert. Hol dir einen API-Key und nutze sie in deinem Projekt.

API-Key holen

Code-Snippets

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

Beispiel-Response

Echte Antwort dieses Endpoints, erfasst beim letzten Health-Check.

{
    "data": {
        "gaps": 15,
        "note": "Between two posts, n balusters leave n+1 gaps, and the smallest count that keeps every gap within the limit = ceil((length − max gap) ÷ (baluster width + max gap)). The usual guardrail limit is a 100 mm (4-inch) sphere — a child-safety rule — so a 2000 mm rail with 40 mm balusters needs 14 of them, leaving even 96 mm gaps. Always round the count up; one fewer baluster opens the gaps past the limit.",
        "inputs": {
            "max_gap_mm": 100,
            "baluster_width_mm": 40,
            "railing_length_mm": 2000
        },
        "code_ok": true,
        "actual_gap_mm": 96,
        "baluster_count": 14
    },
    "meta": {
        "timestamp": "2026-06-07T08:17:48.027Z",
        "request_id": "81d83dc8-15e3-427b-a515-a7758ddc2935"
    },
    "status": "ok",
    "message": "Baluster count",
    "success": true
}