Set display labels for a VPS
PUT /api/v2/vps/{id}/metadata
Sets your own labels for a VPS: a display name and a name for its operating system. They change what the client area shows, not the server itself. displayName also becomes the service name on future invoices. Send null or an empty string to remove it. The service name then goes back to the hostname. To relabel the operating system, send operatingSystemName together with operatingSystemSourceName. Set the source to operatingSystem.displayName from GET /api/v2/vps/{id}. Sending the same value for both removes the label. A rebuild removes the operating system label. A hostname change with PUT /api/v2/vps/{id}/hostname removes the display name.
Authentication: An API key with the scope write:vm. About keys and scopes
Request
Path parameters
idstringrequiredvps_…).Body
displayNamestring or nullnull or an empty string removes it.operatingSystemNamestring or nullnull removes it.operatingSystemSourceNamestring or nulloperatingSystem.displayName of the VPS. Required with operatingSystemName.Example
curl -X PUT "https://cloud.hostup.se/api/v2/vps/vps_01hxa3b4c5d6e7f8g9h0j1k2m3/metadata" \ -H "Authorization: Bearer $HOSTUP_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "displayName": "Production DB" }'curl -X PUT "https://cloud.hostup.se/api/v2/vps/vps_01hxa3b4c5d6e7f8g9h0j1k2m3/metadata" \ -H "Authorization: Bearer $HOSTUP_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "operatingSystemName": "Debian 13", "operatingSystemSourceName": "Debian 12" }'curl -X PUT "https://cloud.hostup.se/api/v2/vps/vps_01hxa3b4c5d6e7f8g9h0j1k2m3/metadata" \ -H "Authorization: Bearer $HOSTUP_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "displayName": null }'Responses
200 The labels were saved.
{ "customerMetadata": { "displayName": "Production DB", "operatingSystemName": "Debian 13", "operatingSystemSourceName": "Debian 12", "updatedAt": "2026-11-02T10:00:00.000Z" }}Response fields
customerMetadataobjectdisplayNamestring or nulloperatingSystemNamestring or nulloperatingSystemSourceNamestring or nullupdatedAtstring or nullErrors
Errors are Problem Details with a stable code. Branch on the code, not on the text.
| 400 | The body is invalid. errors[].pointer names the field. |
| 401 | Authentication is required. |
| 403 | The key lacks write:vm or the VPS belongs to another account. |
| 404 | The VPS was not found. code is vps_not_found. |
| 429 | Rate limited. Retry after the limit resets. 429 responses include Retry-After seconds plus X-RateLimit-* headers. |
| 500 | Internal error. Retry later or contact support if the issue persists. |