Skip to main content
POST
/
v2
/
sandboxes
/
volumes
Create a Volume
curl --request POST \
  --url https://api.example.com/v2/sandboxes/volumes \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "size": "<string>",
  "storage_class": "<string>",
  "wait_for_ready": true,
  "timeout": 60
}
'
{
  "name": "<string>",
  "size": "<string>",
  "storage_class": "<string>",
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "created_at": "<string>",
  "updated_at": "<string>"
}

Body

application/json

Request model for creating a PersistentVolume and PersistentVolumeClaim.

name
string
required

Name of the volume (max 63 chars, DNS-1035 format: lowercase alphanumeric and hyphens, must start with letter)

size
string
required

Storage size (e.g., '1Gi', '10Gi')

Examples:

"1Gi"

"5Gi"

"10Gi"

storage_class
string | null

Storage class name. Only 'standard' is allowed. Uses cluster default if not specified.

Allowed value: "standard"
wait_for_ready
boolean
default:true

Wait for volume to be bound before returning. If True, the request blocks until the PVC is bound or times out.

timeout
integer
default:60

Timeout in seconds when wait_for_ready is True.

Required range: 5 <= x <= 300

Response

Successful Response

Response model for a Volume.

name
string
required
size
string
required
storage_class
string
required
id
string<uuid> | null

Unique volume identifier

created_at
string | null
updated_at
string | null