Lupin / Sandboxes
Sandbox and container API for AI agents
Give an agent an isolated environment for code and files.
Build an agent workflow with sandboxes
Research, data processing and development tasks often need a working directory, tools and command output. Lupin’s hosted container API creates an isolated environment, exposes command results and lets the calling application stop or resume its runtime. It is distinct from the browser session API.
What the API supports
- Create and list hosted sandbox containers
- Run commands and inspect exit codes, standard output and errors
- Upload and download files through documented transfer operations
- Stop and resume runtime
- Inspect published ports and request temporary shell access
From setup to a verified outcome
Check execution access
Confirm that the hosted sandbox provider is configured and that the workspace has a sandbox runtime allowance and available concurrency.
Run and verify
Create or resume an environment, transfer the necessary files and run a bounded command. Inspect exit_code and the output; HTTP success alone does not mean the command succeeded.
Control exposure and runtime
Use application authentication for any published service and stop the environment when it is idle. Inspect usage rather than assuming a stopped browser also stops a sandbox.
Availability and limits
- Hosted sandbox access depends on provider configuration and the workspace plan. The Free plan does not include sandbox runtime.
- File transfers have a size limit; the current API uses base64 transport with an approximately 2 MB ceiling.
- The current API supports stop/resume and port publication. Container deletion and port revocation are not exposed by this surface.
- Temporary shell and published service URLs need appropriate access controls; do not publish private files without application authentication.
Check your workspace for its current configuration, usage and limits. Compare the plans before creating paid resources.
Start with the API reference
The following read endpoint is part of this capability. Authenticate with the relevant workspace key and inspect the documented response and permission requirements.
GET /v0/containersOpenAPI specification · Sandboxes documentation · Agent registration
Common questions
Are browser sessions and sandboxes the same resource?
No. Browser sessions provide a browser environment. The container API provides an isolated place to execute commands and manage files.
Does a successful HTTP response mean my command worked?
No. Inspect the returned exit code, status, stdout and stderr to determine whether the command completed successfully.