`PUT /api/v1/maintenance-windows/{id}` — update a maintenance window (Admin only). Typically used to end a window early.
PUT
/api/v1/maintenance-windows/{id}
const url = 'https://example.com/api/v1/maintenance-windows/example';const options = { method: 'PUT', headers: {'Content-Type': 'application/json'}, body: '{"ends_at":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request PUT \ --url https://example.com/api/v1/maintenance-windows/example \ --header 'Content-Type: application/json' \ --data '{ "ends_at": 1 }'Parameters
Section titled “ Parameters ”Path Parameters
Section titled “Path Parameters ” id
required
string
Maintenance window ID
Request Body required
Section titled “Request Body required ” Media type application/json
Request body for PUT /api/v1/maintenance-windows/{id}.
object
ends_at
required
New end time (for ending early), Unix timestamp in seconds.
integer format: int64
Example generated
{ "ends_at": 1}Responses
Section titled “ Responses ”Maintenance window updated
Media type application/json
Response body for a single maintenance window.
object
created_by
required
string
ends_at
required
integer format: int64
id
required
string
reason
required
string
starts_at
required
integer format: int64
Example generated
{ "created_by": "example", "ends_at": 1, "id": "example", "reason": "example", "starts_at": 1}Invalid request body
Admin role required
Maintenance window not found