Skip to main content
POST
Create snapshot

Authorizations

X-API-Key
string
header
required

Headers

Idempotency-Key
string

Optional team-scoped key for retrying the request. Use 1 to 255 lowercase ASCII letters, digits, or hyphens (a-z, 0-9, -), such as a lowercase UUID. The HTTP method, path, query, and request content identify the request. When idempotency is enabled, a matching retry of a completed request replays its status and body, including the IDs of any resources it created, without repeating the operation. A failure explicitly classified as safe to retry (Should-Retry: true) permits a fresh attempt with the same key and request. Only one attempt can run at a time. A different request returns 409 with error_code idempotency_request_mismatch. A matching request whose original has no recorded response yet and is within its expected response window returns 409 with error_code idempotency_in_progress. A matching request whose original has no recorded response and whose expected response deadline has passed or is unknown returns 422 with error_code idempotency_outcome_unknown. These conflicts and unknown outcomes do not execute the request again. If the key's record is unavailable or idempotency is misconfigured, the request returns 503; Should-Retry tells whether to retry with the same key. After the retention period expires, the key can start a new operation.

Required string length: 1 - 255
Pattern: ^[a-z0-9-]+$

Path Parameters

sandboxID
string
required

Body

application/json
name
string

Optional name for the snapshot template. If a snapshot template with this name already exists, a new build will be assigned to the existing template instead of creating a new one.

memory
boolean

Whether to capture a full memory snapshot. When false, only the filesystem is persisted: the snapshot is smaller and faster to take, and sandboxes created from it cold-boot (start fresh from disk) instead of restoring memory, so they begin without the source sandbox's running processes, in-memory state, and open connections. The source sandbox keeps running in both cases. Defaults to true.

Response

Snapshot created successfully

snapshotID
string
required

Identifier of the snapshot template including the tag. Uses namespace/alias when a name was provided (e.g. team-slug/my-snapshot:default), otherwise falls back to the raw template ID (e.g. abc123:default).

names
string[]
required

Full names of the snapshot template including team namespace and tag (e.g. team-slug/my-snapshot:v2)