+ Maintenance Windows +
++ Maintenance windows tell Towerops to suppress alerts for a site or device during planned work. Windows can be one-off or recurring (iCal RRULE). +
+ ++ List maintenance windows +
+
+ GET /api/v1/maintenance_windows. Optional filter
+ query param accepts active, upcoming, or past.
+
<%= raw("""
+curl -G https://towerops.net/api/v1/maintenance_windows \\
+ -H "Authorization: Bearer #{@sample_token}" \\
+ -d filter=active
+""") %>
+ + Create a maintenance window +
+
+ POST /api/v1/maintenance_windows. Required: name, starts_at, ends_at. Scope to a site or a specific device. Set
+ recurring: true
+ with a recurrence_rule
+ (RRULE) to repeat.
+
<%= raw(~S"""
+curl -X POST https://towerops.net/api/v1/maintenance_windows \
+ -H "Authorization: Bearer YOUR_API_TOKEN" \
+ -H "Content-Type: application/json" \
+ -d '{
+ "maintenance_window": {
+ "name": "Quarterly firmware roll",
+ "starts_at": "2026-06-01T05:00:00Z",
+ "ends_at": "2026-06-01T09:00:00Z",
+ "site_id": "SITE_UUID",
+ "suppress_alerts": true
+ }
+ }'
+""") %>
+ + Get / update / delete +
+
+ Standard CRUD on /api/v1/maintenance_windows/:id. GET
+ returns the resource; PATCH
+ updates fields with the same body shape as create; DELETE
+ returns a JSON success body.
+
<%= raw("""
+curl -X DELETE https://towerops.net/api/v1/maintenance_windows/WINDOW_ID \\
+ -H "Authorization: Bearer #{@sample_token}"
+""") %>
+