Create or replace VPS backup schedule

POST /api/v2/vps/{id}/backup-schedules

Create or replace a VPS scheduled backup.

Read GET /api/v2/vps/{id}/backup-schedules first to check limits and actions.canCreate.

Scheduled backups create offsite, longer-term recovery images and can take longer to create or restore than snapshots.

Use snapshot schedules only for short-lived local block-on-write rollback points.

For weekly, send dayOfWeek and do not send dayOfMonth; for monthly, send dayOfMonth and do not send dayOfWeek; for daily, send neither.

VPS Services Backups

Authentication

Required API scope: write:vm

Authenticate with an API key in the Authorization: Bearer <token> header.

Context

Path Parameters

id string required Example: vps_01hxa3b4c5d6e7f8g9h0j1k2m3

Public VPS ID from GET /api/v2/vps data[].id. Do not invent this value; use the exact ID returned by the referenced API response.

Headers

Authorization Bearer <token>
Accept application/json
Content-Type application/json

Body

required
application/json
frequency string · enum required · Example: daily
daily
weekly
monthly
hour integer · min: 0 · max: 23 required · Example: 2
dayOfWeek integer · min: 0 · max: 6 · Example: 1

Required only when frequency is weekly; 0 is Sunday.

dayOfMonth integer · min: 1 · max: 31 · Example: 15

Required only when frequency is monthly.

retentionCount integer · min: 1 required · Example: 3
enabled boolean required · Example: true
name string · Example: Nightly backup

Responses

201 Backup schedule saved.
id string required · Example: bks_01hxa3b4c5d6e7f8g9h0j1k2m3
name string required · Example: Nightly backup
frequency string · enum required · Example: daily
daily
weekly
monthly
time string · nullable required · Example: 02:00

daySpecifier string · nullable required · Example: null

retentionCount integer required · Example: 3
enabled boolean required · Example: true
lastRun string · nullable required · Example: 2026-04-27T02:00:00.000Z

nextRun string · nullable required · Example: 2026-04-28T02:00:00.000Z

status string · nullable · enum required · Example: completed

completed
running
queued
failed
cancelled
unknown
400 Invalid request. The response body is an RFC 7807 Problem Details document.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
401 Unauthorized. Authentication is required.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
403 Forbidden. The caller lacks a required scope or does not own the resource.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
404 Not found. The resource does not exist or is not owned by the caller.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
429 Rate limited. Retry after the limit resets. 429 responses include Retry-After seconds plus X-RateLimit-* headers.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
500 Internal error. Retry later or contact support if the issue persists.
type string · Example: https://developer.hostup.se/errors/invalid_request
title string · Example: Validation failed
status integer · Example: 400
detail string · Example: The request body failed validation.
code string · Example: invalid_request

Stable machine-readable code. Branch on this field, not on detail.

instance string · Example: /api/v2/orders
requestId string · Example: req_01hxa3b4c5d6e7f8g9h0j1k2m3
timestamp string · Example: 2026-04-27T12:34:56.000Z
errors array<object>

Field-level validation errors when code is invalid_request.

errors[].pointer string required · Example: /items/0/eppCode
errors[].detail string required · Example: `eppCode` is required for this transfer.
errors[].code string required · Example: missing_required
extensions object
POST https://cloud.hostup.se/api/v2/vps/{id}/backup-schedules
For AI assistants
View as Markdown
cURL
curl -X POST "https://cloud.hostup.se/api/v2/vps/vps_01hxa3b4c5d6e7f8g9h0j1k2m3/backup-schedules" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "frequency": "daily",
    "hour": 2,
    "retentionCount": 3,
    "enabled": true,
    "name": "Nightly backup"
  }'
Response
{
  "id": "bks_01hxa3b4c5d6e7f8g9h0j1k2m3",
  "name": "Nightly backup",
  "frequency": "daily",
  "time": "02:00",
  "daySpecifier": null,
  "retentionCount": 3,
  "enabled": true,
  "lastRun": null,
  "nextRun": "2026-04-28T02:00:00.000Z",
  "status": null
}
Request Body Daily backup schedule
{
  "frequency": "daily",
  "hour": 2,
  "retentionCount": 3,
  "enabled": true,
  "name": "Nightly backup"
}