Installation
- Gradle (Kotlin DSL)
- Maven
Quick Start
Core Features
Lifecycle Management
Manage the sandbox lifecycle, including renewal, pausing, and resuming.Custom Health Check
Define custom logic to determine if the sandbox is healthy. This overrides the default ping check.Command Execution & Streaming
Execute commands and handle output streams in real-time.File Operations
Manage files and directories, including read, write, list, delete, and search.Sandbox Management (Admin)
UseSandboxManager for administrative tasks and finding existing sandboxes.
Configuration
Connection Configuration
TheConnectionConfig class manages API server connection settings.
- Basic
- Advanced
Sandbox Creation Configuration
TheSandbox.builder() allows configuring the sandbox environment.
API Reference
Sandbox
Main class for interacting with sandboxes.
Methods
static method
Returns a builder for creating a new sandbox instance.Returns:
Sandbox.Buildermethod
Access to command execution operations.Returns:
CommandsClientmethod
Access to file system operations.Returns:
FilesClientmethod
Extends the sandbox expiration time.Parameters:
duration(Duration): Extension duration
method
Pauses the sandbox (suspends all processes).
method
Resumes the paused sandbox.
method
Terminates the sandbox immediately.
method
Retrieves current sandbox information.Returns:
SandboxInfomethod
Gets the external endpoint for a port.Parameters:
port(int): Internal port number
SandboxEndpointmethod
Implements AutoCloseable for try-with-resources.
Examples
Running a Java Application
Network Policy Example
Port Forwarding
Error Handling
Next Steps
Python SDK
Explore the Python SDK
C# SDK
Explore the C# SDK
API Reference
Detailed API documentation
Examples
Browse more code examples