Zum Inhalt springen
GET /v1/cuts

Pieces per stock length

Live testen

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

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

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

API-Key holen

Code-Snippets

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

Beispiel-Response

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

{
    "data": {
        "note": "Pieces per stock = floor((stock + kerf)/(piece + kerf)); the final cut needs no kerf. The offcut is what's left over on one stock length.",
        "inputs": {
            "kerf": 3,
            "piece_length": 300,
            "stock_length": 2400
        },
        "kerf_loss": 18,
        "used_length": 2118,
        "offcut_length": 282,
        "waste_percent": 11.75,
        "pieces_per_stock": 7
    },
    "meta": {
        "timestamp": "2026-06-05T19:50:19.313Z",
        "request_id": "77c5b2bb-1d16-4b01-a436-fb8c9f64ac03"
    },
    "status": "ok",
    "message": "Pieces per stock",
    "success": true
}