Ir al contenido
GET /v1/loss

Total link loss

Pruébalo en vivo

10 llamadas gratis al día — sin registro, sin clave API. Pasa por el gateway de oanor.

Encabezados personalizados (opcional)
api.oanor.com/opticalbudget-api

Funciona. Consigue una clave API y úsala en tu proyecto.

Obtener una clave API

Fragmentos de código

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

Respuesta de ejemplo

Una respuesta real de este endpoint, capturada en la última comprobación de estado.

{
    "data": {
        "note": "Total link loss = fibre attenuation × length + the connector and splice losses. Single-mode fibre runs ~0.35 dB/km at 1310 nm and ~0.20 dB/km at 1550 nm; each mated connector pair costs ~0.3–0.75 dB and each fusion splice ~0.1 dB. Over long hauls the fibre dominates; on short patch links the connectors do. Compare this total against the power budget — the difference is your margin.",
        "inputs": {
            "splices": 0,
            "length_km": 10,
            "connectors": 2,
            "splice_loss_db": 0.1,
            "attenuation_db_km": 0.35,
            "connector_loss_db": 0.5
        },
        "fiber_loss_db": 3.5,
        "total_loss_db": 4.5,
        "splice_loss_db_total": 0,
        "connector_loss_db_total": 1
    },
    "meta": {
        "timestamp": "2026-06-07T08:18:07.216Z",
        "request_id": "6d4e57ac-b592-48bf-8366-1f5e6095971d"
    },
    "status": "ok",
    "message": "Link loss",
    "success": true
}