コンテンツにスキップ

update_netbox_server

PUT
/api/v1/netbox/servers/{id}
curl --request PUT \
--url https://example.com/api/v1/netbox/servers/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "base_url": "example", "ca_cert_pem": "example", "enabled": true, "name": "example", "site_id_field": "example", "sync_interval_secs": 1, "token": "example" }'
id
required
string format: uuid

The server id

Media typeapplication/json
object
base_url
required
string
ca_cert_pem

Three-state, and it has to be: absent leaves the stored CA alone, null clears it, a string replaces it. Without the middle state there is no way to remove a certificate short of deleting the server.

string | null
enabled
required
boolean
name
required
string
site_id_field

⚠️ Two-state, and this is a full-document PUT: omitting it clears the setting, the same way omitting enabled would. ca_cert_pem above is three-state only because the browser never holds the certificate it needs to preserve; this value it does hold.

string | null
sync_interval_secs
integer format: int32
token

A replacement token. Omitted (or null) leaves the sealed one alone — which is what lets the settings form round-trip without the browser ever holding the token.

string | null
Examplegenerated
{
"base_url": "example",
"ca_cert_pem": "example",
"enabled": true,
"name": "example",
"site_id_field": "example",
"sync_interval_secs": 1,
"token": "example"
}

Updated

A field failed validation (see the create route), or token_required_for_new_address: base_url names a different scheme, host or port and no replacement token was sent — the stored token is never sent to a new address

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"
}
}

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 ManageConfig

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"
}
}

No such server

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"
}
}

Inventory storage is unavailable (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"
}
}