volumes

Create a persistent volume, empty or restored from a backup.

Ready in about a second (a restore takes as long as its download); send Prefer: wait=10 to wait for it. Attach it when creating a sandbox with volumes: [{volumeId, path, mode}]. A volume lives on one host's disks. It is backed up off that host daily unless you turn that off, and whenever you ask; backedUp is true once a backup has been copied off the host and checked. Writes since the last backup are not in it. A backup is crash-consistent: what a program had not yet written to the disk is not in it.

post/v1/volumes

Request

  • Base URL: https://api.withruntime.com
  • URL: https://api.withruntime.com/v1/volumes
  • Auth: HTTP bearer

Headers

Idempotency-Keystring

Replaying the same key with the same request within 24 hours returns the first result and never repeats the effect. A refusal is not kept: a request refused before it ran (no_capacity, busy, a limit) runs afresh when sent again with its key. The SDKs send one automatically; the server makes one when absent and returns it in the idempotency-key response header.

Request body

namestring

Your own handle for the resource. Letters, digits, dot, dash, underscore.

labelsobject

Your own key/value tags, at most 32. Filter lists with label=key:value.

regionstring

Omit for the default region, or the backup's region.

sizeMiBinteger

Fixed size, reserved in full. 64 MiB to 1 TiB. Omit when restoring a backup.

fromBackupstring

A ready backup to restore into the new volume. The new volume is the backup's size, in its region, on whichever host has room, and is ready once the restore is checked.

Response

Success

idstring required
kind'volume' required
statusstring required
state'creating' | 'ready' | 'failed' | 'deleting' | 'deleted' required
namestring nullable
sizeMiBinteger required
usedMiBinteger nullable
backedUpboolean required

A volume lives on one host's disks. It is backed up off that host daily unless you turn that off, and whenever you ask; backedUp is true once a backup has been copied off the host and checked. Writes since the last backup are not in it. A backup is crash-consistent: what a program had not yet written to the disk is not in it.

restoredFromstring nullable

The backup this volume was made from.

createdAtstring

Changes

No recorded changes to this operation across all 1 revision of this API.