Named sets of links that share physical fate (e.g., same fiber duct). Used by Engineering Mode to model correlated link failures. Scoped per network.

Auth: Engineer, Admin (all endpoints).

List SRLGs

GET /api/v1/srlgs?network_id=<uuid>

Returns all SRLGs for a network, ordered by name. Each entry includes a computed member_count.

Query parameters:

Response: 200 OK

[
  {
    "id": "uuid",
    "network_id": "uuid",
    "name": "Fiber Duct A-B",
    "description": "Links sharing the conduit between sites A and B",
    "member_count": 3,
    "created_at": "2026-03-26T12:00:00Z",
    "updated_at": "2026-03-26T12:00:00Z"
  }
]

Error responses:


List SRLGs for Simulation

GET /api/v1/srlgs/for-simulation?network_id=<uuid>

Lightweight list (id, name, member_count) for the "Load Saved SRLG" dropdown in Engineering Mode. Same response format as List SRLGs.

Query parameters:

Response: 200 OK -- Array of SRLG objects (same schema as List SRLGs)


Get SRLG

GET /api/v1/srlgs/{id}

Returns a single SRLG with its member link IDs.

Response: 200 OK

{
  "id": "uuid",
  "network_id": "uuid",
  "name": "Fiber Duct A-B",
  "description": "Links sharing the conduit between sites A and B",
  "member_count": 3,
  "member_link_ids": ["uuid-link-1", "uuid-link-2", "uuid-link-3"],
  "created_at": "2026-03-26T12:00:00Z",
  "updated_at": "2026-03-26T12:00:00Z"
}

Error responses:


Create SRLG

POST /api/v1/srlgs

Request body:

{
  "network_id": "uuid",
  "name": "Fiber Duct A-B",
  "description": "Links sharing the conduit between sites A and B",
  "member_link_ids": ["uuid-link-1", "uuid-link-2"]
}
Field Type Required Description
network_id UUID Yes Network scope
name string Yes 1-100 characters, unique per network
description string No Optional description
member_link_ids string[] No Initial member links

Response: 201 Created -- SRLGWithMembers object

Error responses:


Update SRLG

PUT /api/v1/srlgs/{id}

Request body:

{
  "name": "Fiber Duct A-B (updated)",
  "description": "Updated description",
  "member_link_ids": ["uuid-link-1", "uuid-link-3"]
}
Field Type Required Description
name string No New name (1-100 characters)
description string No New description (always applied, even if empty)
member_link_ids string[] No If present, replaces all members. Null = no change. Empty array = clear all members.

Response: 200 OK -- SRLGWithMembers object

Error responses:


Delete SRLG

DELETE /api/v1/srlgs/{id}

Deletes the SRLG. CASCADE removes all member entries.

Response: 204 No Content

Error responses:


List SRLG Members

GET /api/v1/srlgs/{id}/members

Returns all member entries for an SRLG, ordered by link_id.

Response: 200 OK

[
  { "id": "uuid", "srlg_id": "uuid", "link_id": "uuid-link-1" },
  { "id": "uuid", "srlg_id": "uuid", "link_id": "uuid-link-2" }
]