Skip to content
Subako Docs
English
Esc
navigateopen⌘Jpreview

List a session's sandboxes

GET/v1/sessions/{session_id}/sandboxes
Authorization
AuthorizationBearer token · headerrequired
Path parameters
session_idstring<uuid>required
Session id
Responses
200Every sandbox the session's agent grants, in name order. The list is whole: an agent grants a bounded set, so nothing pages.
itemsSessionSandboxBody[]required
Show properties
Array of SessionSandboxBody
archive_bytesinteger<int64> | null
Size of the last published snapshot, which can predate the latest exec. Null means no archive is available, regardless of status.
archive_refused_bytesinteger<int64> | null
What the workspace packed to when a backup was last refused for exceeding this sandbox's archive bound; cleared by the next archive that lands. It distinguishes a workspace too large to save from one that was never backed up, which both report a null `archive_bytes`.
classstringrequired
created_atstring<date-time>required
environmentSessionSandboxEnvironmentBodyrequired
Which image the sandbox boots. One variant today; a workspace environment is a later variant of this union.
Show properties
One of:
object
releasestringrequired
The platform image line the row was stamped with, e.g. `2026`.
typestringrequired
Allowed:platform
last_used_atstring<date-time> | null
namestringrequired
networkSessionSandboxNetworkBodyrequired
Where the sandbox may reach, as its grant said when the session was made.
Show properties
One of:
object
typestringrequired
Allowed:unrestricted
object
typestringrequired
Allowed:none
statusSessionSandboxStatusBodyrequired
Stable lifecycle vocabulary for v1. Adding or changing a value requires a new API version; additional internal states map to these public states. - `dormant`: no instance has been started; an exec provisions one. - `provisioning`: an instance is starting, restoring, or resuming; exec waits. - `running`: an instance is available for exec. - `draining`: backup, suspension, or retirement is in progress; exec waits. - `suspended`: an idle instance is paused; an exec resumes it. Archive deletion still returns 409 until automatic retirement. - `archived`: the instance is retired; an exec provisions a new one and restores the last published archive, if present. Archive deletion is permitted. - `failed`: the generation failed; a new exec attempts provisioning from the last published archive, if present. Archive deletion is permitted. A published archive can be downloaded in any state. Status is a snapshot; a concurrent exec or lifecycle transition can change whether deletion succeeds.
Allowed:dormantprovisioningrunningdrainingsuspendedarchivedfailed
400Malformed path parameter.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
401Missing, malformed, or invalid bearer token.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
403A workspace credential lacking session.read. A session token carries no permissions and never lands here.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
404No such session, or the caller cannot see it.
errorErrorDetailrequired
What went wrong: a `code` to branch on and a `message` to show. The message is written for a person and may change; the code will not.
Show properties
codeErrorCoderequired
The machine-readable half of an error response, and the field a client branches on. Closed: every error carries exactly one of these.
Allowed:unauthorizedforbiddennot_foundinvalid_requestconflictclient_outdatedprecondition_failedtoo_many_requestsinternal
messagestringrequired
Try it
Server
Authorization
Parameters
Request
curl -X GET "https://api.us.cloud.subako.ai/v1/sessions/497f6eca-6276-4993-bfeb-53cbbbba6f08/sandboxes" \
  -H "Authorization: Bearer YOUR_TOKEN"
Response
{
  "items": [
    {
      "archive_bytes": 0,
      "archive_refused_bytes": 0,
      "class": "string",
      "created_at": "2019-08-24T14:15:22Z",
      "environment": {
        "release": "string",
        "type": "platform"
      },
      "last_used_at": "2019-08-24T14:15:22Z",
      "name": "string",
      "network": {
        "type": "unrestricted"
      },
      "status": "dormant"
    }
  ]
}