Update a site's maintenance window
Gives the website a window of its own, starting at start_hour and lasting four hours, UK time. Changes already queued move to the new window.
Path parameters
The id of a site row. A website's production site and each of its environments has its own id. Digits only. At least 1.
Body
The hour the window opens, from 0 to 23, UK time.
Returns
200 The window was saved. restamped counts the queued changes that moved.
Fields of the 200 answer
Why the window cannot be changed. Sent only when editable is false.
window_scope_unavailableforbiddenwindow_lockedThe window in force, wherever it comes from.
Fields
The hour the window closes. 0 to 23.
The window in words, such as 00:00–04:00 UK time.
The level the window comes from. staff_lock is a window Corefinity has set, which cannot be changed here.
siteclusterstaff_lockcompanyplatformTrue when Corefinity has set the window.
The hour the window opens, in timezone. 0 to 23.
The window this level uses when it has none of its own.
Fields
websiteclustercompanyplatform0 to 23.
The next occurrence of the window.
The notice period while it runs: until is its end, or null before it has a date. Null once it has passed.
The start hour set at this level. Null when the level has none of its own and inherits.
Changes waiting for the window.
Fields
Whether you are told about them before they apply.
Sent after a change: how many queued changes moved to the new window.
A site by its id and domain.
Fields
A scheduled snapshot that falls inside the window, with its local time. Null when there is none.
If it is refused
| Status | Reason | What to do |
|---|---|---|
401 | none | Send a valid token as Authorization: Bearer <token>. |
403 | company_unavailable | Your company is unavailable. |
403 | forbidden | The person is not allowed to do this. |
403 | scope_required | Use a token with the scope named in scope. |
403 | two_factor_required | Turn on two-factor on your account, then send again. |
404 | feature_off | This feature is not on for your organisation yet. |
409 | batch_applying | Maintenance is running on the site now. Try again when it finishes. |
409 | window_locked | The maintenance window is set by Corefinity. Contact support to change it. |
422 | window_scope_unavailable | This has no maintenance window of its own. Set the window on its website or cluster. |
422 | window_start_invalid | The start hour is not one. Choose an hour from 00 to 23. |
429 | rate_limited | Wait for the seconds in Retry-After. |
429 | throttled | Too many tries. Wait a minute and try again. |
Reasons are listed by name in Errors and refusals.
The same task elsewhere
curl -X PUT https://manage.corefinity.com/api/corestack/sites/1042/maintenance-window \
-H "Authorization: Bearer $COREFINITY_TOKEN" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-d '{
"start_hour": 3
}'use Illuminate\Support\Facades\Http;
$response = Http::withToken(env('COREFINITY_TOKEN'))
->acceptJson()
->put('https://manage.corefinity.com/api/corestack/sites/1042/maintenance-window', [
'start_hour' => 3,
]);
$data = $response->json();const res = await fetch('https://manage.corefinity.com/api/corestack/sites/1042/maintenance-window', {
method: 'PUT',
headers: {
Authorization: `Bearer ${process.env.COREFINITY_TOKEN}`,
Accept: 'application/json',
'Content-Type': 'application/json',
},
body: JSON.stringify({
start_hour: 3,
}),
});
// An answer with no body (204) has nothing to parse.
const text = await res.text();
const data = text && JSON.parse(text);import os
import requests
res = requests.put(
"https://manage.corefinity.com/api/corestack/sites/1042/maintenance-window",
headers={
"Authorization": f"Bearer {os.environ['COREFINITY_TOKEN']}",
"Accept": "application/json",
},
json={
"start_hour": 3,
},
)
data = res.json() if res.content else None{
"editable": true,
"effective": {
"end_hour": 7,
"label": "03:00–07:00 UK time",
"length_hours": 4,
"source": "site",
"source_label": "This website",
"staff_locked": false,
"start_hour": 3,
"timezone": "Europe/London"
},
"inherited": {
"level": "platform",
"name": "Corefinity default",
"start_hour": 0
},
"next": {
"ends_at": "2026-11-04T07:00:00Z",
"hours": 4,
"label": "03:00–07:00 UK time",
"last_start_at": "2026-11-04T06:30:00Z",
"local_date": "2026-11-04",
"starts_at": "2026-11-04T03:00:00Z"
},
"notice_period": {
"until": null
},
"own": {
"start_hour": 3
},
"pending": {
"count": 0,
"notice": false
},
"restamped": 0,
"site": {
"domain": "harbourandfinch.example.com",
"id": 1042
},
"snapshot_overlap": null
}{
"message": "Unauthenticated."
}{
"code": "company_unavailable",
"message": "Your company is unavailable.",
"reason": "company_unavailable"
}{
"code": "feature_off",
"message": "Not found.",
"reason": "feature_off"
}{
"code": "batch_applying",
"message": "Maintenance is running on this site now. Try again when it finishes.",
"reason": "batch_applying"
}{
"code": "window_scope_unavailable",
"message": "Environments use their website's window.",
"reason": "window_scope_unavailable"
}{
"code": "rate_limited",
"message": "Too many requests. Try again in 60 seconds.",
"reason": "rate_limited",
"retry_after_seconds": 60
}