---
title: "Set server configuration variable"
method: PUT
path: "/v1/server-config/{name}"
tags: ["Server"]
---

# Set server configuration variable

`PUT /v1/server-config/{name}`

Set value of server configuration variable, creating it if it does not exist. Requires SERVER_CONFIG access right. New variables are created as visible string variables without description, units, or default value. Hidden variables cannot be set. Change takes effect immediately unless the variable is marked as requiring server restart.

## Request body

- ServerConfigVariableUpdate — Server configuration variable update request
  - `value` string, required — New value, up to 1999 characters

## Response `200`

Configuration variable updated successfully

- ServerConfigVariable — Server configuration variable
  - `name` string — Variable name (up to 63 characters)
  - `value` string — Current value
  - `defaultValue` string — Default value, empty if not defined
  - `dataType` 'STRING' | 'BOOLEAN' | 'INTEGER' | 'CHOICE' | 'COLOR' | 'PASSWORD' — Type of the value. BOOLEAN values are stored as "0" and "1", COLOR values as CSS color strings, and CHOICE values must be one of possibleValues.
  - `description` string — Human readable description, empty if not defined
  - `units` string — Units of the value (for INTEGER variables), empty if not defined
  - `needServerRestart` boolean — True if server restart is required for a change to take effect
  - `possibleValues` ServerConfigPossibleValue[] — Value constraints. For CHOICE variables, the list of allowed values. For INTEGER variables, either empty (no limit) or a single entry holding the maximum allowed value. Empty for other types.
    - `value` string — Value as stored in the variable
    - `description` string — Human readable description of the value

## Other responses

- `400` — Invalid variable name, missing or invalid value, or value too long
- `401` — Unauthorized
- `403` — User does not have SERVER_CONFIG access right
- `404` — Configuration variable exists but is not visible
- `500` — Database failure

## Changes

- **2026-09-15** `6eac6acac8bf` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/netxms/apis/netxms-api/changes/v1/server-config/:name/put.md)

---

[API](https://skmtc.dev/netxms/apis/netxms-api.md) · [All operations](https://skmtc.dev/netxms/apis/netxms-api/llms.txt) · [OpenAPI document](https://skmtc.dev/netxms/apis/netxms-api/revisions/a203de7e5d7d?raw)
