Set the cluster maintenance window
const url = 'http://localhost:8000/clusters/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/maintenance-window';
const options = {
method: 'PUT',
headers: {
'API-Version': '2026-06-01.beta',
'API-Key': '<API-Key>',
'Content-Type': 'application/json'
},
body: '{"enabled":true,"days_of_week":[1],"start_local":"example","end_local":"example","timezone":"example"}'
};
try {
const response = await fetch(url, options);
const data = await response.json();
console.log(data);
} catch (error) {
console.error(error);
}curl --request PUT \
--url http://localhost:8000/clusters/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/maintenance-window \
--header 'API-Key: <API-Key>' \
--header 'API-Version: 2026-06-01.beta' \
--header 'Content-Type: application/json' \
--data '{ "enabled": true, "days_of_week": [ 1 ], "start_local": "example", "end_local": "example", "timezone": "example" }'Creates or replaces the cluster’s maintenance window.
Required scope: clusters:write
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Header Parameters
Section titled “Header Parameters”Request Bodyrequired
Section titled “Request Bodyrequired”A cluster maintenance window: when Skycloak applies upgrades and other disruptive changes.
object
Whether the window is active.
Days of week the window applies to (0 = Sunday … 6 = Saturday).
Local start time, HH:MM.
Local end time, HH:MM.
IANA timezone, e.g. Europe/Berlin.
Example generated
{
"enabled": true,
"days_of_week": [
1
],
"start_local": "example",
"end_local": "example",
"timezone": "example"
}Responses
Section titled “Responses”The request has succeeded.
A cluster maintenance window: when Skycloak applies upgrades and other disruptive changes.
object
Whether the window is active.
Days of week the window applies to (0 = Sunday … 6 = Saturday).
Local start time, HH:MM.
Local end time, HH:MM.
IANA timezone, e.g. Europe/Berlin.
Example generated
{
"enabled": true,
"days_of_week": [
1
],
"start_local": "example",
"end_local": "example",
"timezone": "example"
}Access is unauthorized.
RFC 9457 Problem Details object.
object
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}The server cannot find the requested resource.
RFC 9457 Problem Details object.
object
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}Client error
object
object
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com",
"errors": [
{
"field": "example",
"detail": "example",
"code": "example",
"value": "example"
}
]
}Client error
RFC 9457 Problem Details object.
object
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}Headers
Section titled “Headers”Server error
RFC 9457 Problem Details object.
object
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}Server error
RFC 9457 Problem Details object.
object
Example generated
{
"type": "https://example.com",
"title": "example",
"status": 1,
"detail": "example",
"instance": "https://example.com"
}