コンテンツにスキップ

list_maintenance_windows

GET
/api/v1/maintenance-windows
curl --request GET \
--url https://example.com/api/v1/maintenance-windows \
--header 'Authorization: Bearer <token>'

Every maintenance window

Media typeapplication/json
Array<object>

A stored maintenance window (API shape; times are RFC 3339 text at the edge).

object
active
required

Whether the window covers “now” (computed at read time for the UI).

boolean
enabled
required
boolean
ends_at
required
string
id
required
string format: uuid
name
required
string
scope_id
required
string
scope_level
required

How a maintenance window is scoped. The first three mirror threshold scoping (ADR-013): Node = node id, Profile = device-class id, Group = a tag value. FolderGroup is the hierarchical inventory group (resolved recursively, incl. subgroups, ADR-022) — the scope the All Nodes right-click uses. It is not a threshold concept, so it stays local to maintenance rather than extending the shared [yagra_common::ScopeLevel].

string
Allowed values: node profile group group_id
starts_at
required
string
Example
[
{
"scope_level": "node"
}
]

No valid bearer token

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}

Role lacks the View permission

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}

This core has no write side (skeleton mode)

Media typeapplication/json

The ADR-019 envelope every failure renders as. pub(crate) and schema-bearing so the OpenAPI document can name one error shape for every endpoint (ADR-035) instead of leaving 4xx/5xx bodies undescribed — a client that has to guess the failure shape ends up parsing the success shape and reading undefined.

object
error
required
object
code
required

Stable machine-readable code. Clients branch on this, never on the message.

string
message
required

Operator-facing sentence. Safe to display; never carries an internal error’s own text.

string
Examplegenerated
{
"error": {
"code": "example",
"message": "example"
}
}