Feature module | Description |
Sandbox instance lifecycle management. It supports connection, suspending and resuming, termination, timeout configuration, and access address retrieval. | |
Process and command management. It provides features, such as command execution, process management, terminal connection, input, and process termination. | |
File system management. It provides features, such as file read/write, directory management, and file information retrieval. | |
Code interpreter management. It provides features, such as code execution, context creation, and status persistence. | |
Template management. It providing featues such as template retrival, list, update, deletion, and tag management. | |
Storage volume management. It supports volume creation, connection, destruction, listing, and information retrieval. |
SDK method | Description |
sandbox.connect() | Connects to an existing sandbox instance. If it is paused, it will automatically resume. |
Sandbox.list() | Lists sandbox instances. |
sandbox.getInfo() | Obtains the details of a sandbox instance. |
sandbox.kill() | Terminates a sandbox instance. |
sandbox.setTimeout() | Sets or refreshes the maximum lifetime of a sandbox instance. |
sandbox.isRunning() | Checks whether a sandbox instance is running. |
sandbox.pause() | Suspends a sandbox instance. |
Sandbox.connect(sandboxId) | Connects to an existing sandbox instance. If it is paused, it will automatically resume. |
Sandbox.setTimeout(sandboxId, ms) | Refreshes the maximum lifetime of a sandbox instance by its ID. |
sandbox.getHost(port) | Obtains the external access address of a sandbox instance for a given port. |
sandbox.downloadUrl(path) | Obtains a pre-signed download URL for a file in a sandbox instance via the file path. |
sandbox.uploadUrl(path) | Obtains a pre-signed upload URL for a file in a sandbox instance via the file path. |
SDK method | Description |
sandbox.commands.run() | Runs a command. |
sandbox.commands.list() | Lists running processes. |
sandbox.commands.connect() | Connects to an existing process. |
sandbox.commands.sendStdin() | Sends input. For example, enter text in the terminal. |
sandbox.commands.kill() | Terminates a process. |
sandbox.pty.create() | Creates a Pseudo Terminal (PTY). |
sandbox.pty.connect() | Connects to an existing PTY session. |
sandbox.pty.sendInput() | Sends input to a PTY. |
sandbox.pty.resize() | Resizes the PTY window. |
sandbox.pty.kill() | Terminates a PTY. |
sandbox.commands.closeStdin() | Closes the input channel for a command. |
SDK method | Description |
sandbox.files.read() | Reads a file. |
sandbox.files.write() | Writes a file. |
sandbox.files.list() | Lists the contents of a directory. |
sandbox.files.exists() | Determines whether a file exists. |
sandbox.files.makeDir() | Creates a directory. |
sandbox.files.remove() | Deletes a file. |
sandbox.files.rename() | Renames a file. |
sandbox.files.watchDir() | Listens for file changes within a directory in a sandbox instance. |
sandbox.files.getInfo() | Obtains file information. |
sandbox.files.writeFiles() | Writes multiple files simultaneously. |
SDK method | Description |
sandbox.runCode() | Runs code. |
sandbox.createContext() | Creates an execution context. |
SDK method | Description |
Template.assignTags() | Assigns tags to a template. |
Template.getTags() | Queries tags of a template. |
Template.removeTags() | Removes tags from a template. |
SDK method | Description |
Volume.create() | Creates a storage volume. |
Volume.connect() | Connects to an existing storage volume. |
Volume.destroy() | Destroys a storage volume. |
Volume.list() | Lists all storage volumes in the team. |
Volume.getInfo() | Obtains storage volume information. |