Skip to content
Docs

Sandboxes

Create sandboxes to run commands and work with files in isolated environments. You can inspect command output, save snapshots, and manage session timeouts or network access.

Create a snapshot.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to snapshot.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Create a snapshot.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to snapshot.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Create a named sandbox.

Parameters

ParameterTypeRequiredDescription
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectYesRequest body for this tool.

Create a named sandbox.

Parameters

ParameterTypeRequiredDescription
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Create a named sandbox.

Parameters

ParameterTypeRequiredDescription
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Create a directory.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to create the directory in.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Extend session timeout.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to extend the timeout for.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Get a named sandbox.

Parameters

ParameterTypeRequiredDescription
namestringYesName for the sandbox. Must be unique per project and URL-safe (alphanumeric, hyphens, underscores).
projectIdstringNoThe project ID or name (required when not using OIDC token).
resumebooleanNoWhether to automatically resume a stopped named sandbox by creating a new instance from its snapshot. Default: false.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

Get a session.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to retrieve.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

Get a command.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session containing the command.
cmdIdstringYesThe unique identifier of the command to retrieve.
waitstringNoIf set to "true", the request will block until the command finishes execution. Useful for synchronously waiting for command completion. Allowed values: "true", "false". Default: "false".
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

Stream command logs.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session containing the command.
cmdIdstringYesThe unique identifier of the command to stream logs for.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

Get a snapshot.

Parameters

ParameterTypeRequiredDescription
snapshotIdstringYesThe unique identifier of the snapshot to retrieve.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

Kill a command.

Parameters

ParameterTypeRequiredDescription
cmdIdstringYesThe unique identifier of the command to terminate.
sessionIdstringYesThe unique identifier of the session containing the command.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

List named sandboxes for a project. This tool corresponds to the listNamedSandboxes catalog operation. Use list_sessions to list Sandbox sessions.

Parameters

ParameterTypeRequiredDescription
projectstringYesThe unique identifier or name of the project to list named sandboxes for.
limitnumberNoMaximum number of named sandboxes to return in the response. Used for pagination. Minimum: 1. Maximum: 50. Default: 20.
sortBystringNoField to sort by. Allowed values: "createdAt", "name", "statusUpdatedAt", "currentSnapshotId". Default: "createdAt".
namePrefixstringNoFilter named sandboxes whose name starts with this prefix. Only valid when sortBy=name.
cursorstringNoOpaque pagination cursor from a previous response.
sortOrderstringNoSort direction. Allowed values: "asc", "desc". Default: "desc".
statusstringNoFilter named sandboxes by status. Only valid when sortBy is createdAt. Allowed values: "running", "stopping", "stopped".
tagsstring | Array<string>NoFilter sandboxes by tag. Format: "key:value". Only one tag filter is supported at a time.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

List commands.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to list commands for.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

List snapshots.

Parameters

ParameterTypeRequiredDescription
projectstringYesThe unique identifier or name of the project to list snapshots for.
namestringNoName for the sandbox. Must be unique per project and URL-safe (alphanumeric, hyphens, underscores).
limitnumberNoMaximum number of snapshots to return in the response. Used for pagination. Minimum: 1. Maximum: 50. Default: 20.
cursorstringNoOpaque pagination cursor from a previous response.
sortOrderstringNoSort direction for results by creation time. Allowed values: "asc", "desc". Default: "desc".
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

List sessions.

Parameters

ParameterTypeRequiredDescription
projectstringYesThe unique identifier or name of the project to list sessions for.
namestringNoFilter sessions by sandbox name. Only sessions belonging to the specified sandbox are returned.
limitnumberNoMaximum number of sessions to return in the response. Used for pagination. Minimum: 1. Maximum: 50. Default: 20.
cursorstringNoOpaque pagination cursor from a previous response.
sortOrderstringNoSort direction for results by creation time. Allowed values: "asc", "desc". Default: "desc".
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.

Read a file.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to read the file from.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectYesRequest body for this tool.

Execute a command.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session in which to execute the command.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Stop a session.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to stop.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyunknownNoRequest body for this tool.

Update a sandbox.

Parameters

ParameterTypeRequiredDescription
namestringYesThe sandbox to update.
projectIdstringNoThe project ID that owns the named sandbox. When provided, takes precedence over OIDC project context.
resumebooleanNoWhether to automatically resume a stopped named sandbox by creating a new instance from its snapshot. Default: false.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Update network policy.

Parameters

ParameterTypeRequiredDescription
sessionIdstringYesThe unique identifier of the session to update the network policy for.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodyobjectNoRequest body for this tool.

Write files.

Parameters

ParameterTypeRequiredDescription
xCwdstringNoThe target directory where the tarball contents will be extracted. If not specified, files are extracted to the sandbox home directory.
sessionIdstringYesThe unique identifier of the session to write files to.
teamIdstringNoTeam ID to use for this operation.
slugstringNoTeam slug to use for this operation. Use instead of teamId.
requestBodystringYesA base64-encoded gzipped tarball to extract. Provide this binary value as a base64 string.

Was this helpful?

supported.