Skip to content

Delete a snapshot of a VPS

DELETE /api/v2/vps/{id}/snapshots/{snapshotId}

Deletes a snapshot of a VPS and frees its slot. This cannot be undone. The delete runs in the background after the 204. Follow it with GET /api/v2/vps/{id}/active-jobs. The answer is also 204 when no snapshot has that name. Read GET /api/v2/vps/{id}/snapshots to confirm it is gone.

Authentication: An API key with the scope backup:vm. About keys and scopes

Request

Path parameters

idstringrequired
The VPS ID (vps_…).
snapshotIdstringrequired
The snapshot name, from data[].name on GET /api/v2/vps/{id}/snapshots. Letters, digits, _ and -.

Example

DELETE /api/v2/vps/{id}/snapshots/{snapshotId}
curl -X DELETE "https://cloud.hostup.se/api/v2/vps/vps_01hxa3b4c5d6e7f8g9h0j1k2m3/snapshots/before-upgrade" \
-H "Authorization: Bearer $HOSTUP_API_KEY"

Responses

204 The delete is queued.

Errors

Errors are Problem Details with a stable code. Branch on the code, not on the text.

400Invalid request. The response body is an RFC 7807 Problem Details document.
401Unauthorized. Authentication is required.
403Forbidden. The caller lacks a required scope or does not own the resource.
404Not found. The resource does not exist or is not owned by the caller; code is vps_not_found.
429Rate limited. Retry after the limit resets. 429 responses include Retry-After seconds plus X-RateLimit-* headers.
500Internal error. Retry later or contact support if the issue persists.