Sandbox SDK and API
Run code and agents, expose applications, coordinate workers, and inspect their results. Use the SDK from TypeScript or JavaScript, or call the HTTP API from Python.
Get started
| Language | Install | Guide |
|---|---|---|
| TypeScript and JavaScript | npm install @tangle-network/sandbox | Create your first sandbox |
| Python | pip install httpx | Use the Sandbox HTTP API |
Both use your Tangle API key and account balance. Run these examples on your server; keep the API key out of browser code.
Sandboxes
| Guide | What you can do |
|---|---|
| Lifecycle | Create, size, stop, resume, and delete sandboxes. |
| Commands and files | Execute code, manage processes, and read or write files. |
| Images and storage | Build images, share templates, and use your own snapshot storage. |
| Ingress and egress | Expose HTTPS previews, connect over SSH, and control outbound access. |
| Terminals and computer use | Stream terminals and connect agents to computer tools. |
| Previews and snapshots | Open an app, save a workspace, and restore its files. |
| GPUs | Attach compute for a GPU job and inspect its lease and charges. |
Agents and workflows
| Guide | What you can do |
|---|---|
| Agents and sessions | Run agents, stream results, review changes, and reconnect. |
| Interactive agents | Stream native agent TUIs, send input, and reconnect. |
| Customer workspaces | Keep a sandbox and conversations for each customer. |
| Parallel tasks and batches | Run independent jobs and collect their results. |
| Fleets | Coordinate named workers, select agents, and manage budgets. |
| Workflows | Compose sandbox steps or run a saved Tangle workflow. |
| Traces and analysis | Inspect agent runs, export timings, and request analysis. |
Access and integrations
Access, secrets, and usage covers account resources, team access, browser tokens, and credentials. The API map connects SDK managers and package entrypoints to their guides.
Find package versions and releases on npm. Python examples use HTTPX; a public Python SDK package is not available yet.