Extend a VPS maintenance deadline
POST /api/v2/vps/{id}/maintenance/actions/extend
Moves the restart deadline of one pending maintenance change forward by deadline.extensionDays days. Take deadlineId from pendingChanges[].deadline.id on GET /api/v2/vps/{id}/maintenance and check canExtend first. The new date applies at once. Each deadline can be extended maxExtensions times. After that the call returns 403. A deadline for a change the VPS no longer has returns 400.
Authentication: An API key with the scopes write:vm and write:services. About keys and scopes
Request
Path parameters
idstringrequiredThe VPS ID (
vps_…).Body
deadlineIdstringrequiredThe deadline ID (
mtd_…) from pendingChanges[].deadline.id.Example
curl -X POST "https://cloud.hostup.se/api/v2/vps/vps_01hxa3b4c5d6e7f8g9h0j1k2m3/maintenance/actions/extend" \ -H "Authorization: Bearer $HOSTUP_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "deadlineId": "mtd_01hxa3b4c5d6e7f8g9h0j1k2m3" }'Responses
200 The deadline was extended.
{ "extension": { "originalDeadlineAt": "2026-11-15T00:00:00.000Z", "newDeadlineAt": "2026-11-22T00:00:00.000Z", "extensionCount": 1, "maxExtensions": 2, "canExtendAgain": true }}Response fields
extensionobjectThe result of the extension.
originalDeadlineAtstring or nullThe original deadline.
newDeadlineAtstring or nullThe deadline after this extension.
extensionCountinteger or nullExtensions used, including this one.
maxExtensionsinteger or nullHow many extensions are allowed.
canExtendAgainboolean or nullTrue when the deadline can be extended once more.
Errors
Errors are Problem Details with a stable code. Branch on the code, not on the text.
| 400 | Invalid request. The response body is an RFC 7807 Problem Details document. |
| 401 | Unauthorized. Authentication is required. |
| 403 | All extensions for this deadline are used or the key lacks a scope. |
| 404 | Not found. The resource does not exist or is not owned by the caller; 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. |