Skip to content

Quickstart

You can interact with an AgentBox Sandbox using either of the following methods:

  1. Create a Sandbox with the CLI.

  2. Quick Start a Sandbox with the Python SDK.


Install AgentBox CLI, follow the instructions in the Install AgentBox CLI

 npm install -g agentbox-cli

Sign in with the AgentBox CLI, follow the instructions here: AgentBox CLI Authentication

agentbox auth login -u your_email -p your_password

Build a Sandbox template

# Initialize template
agentbox template init

# Build template (choose platform)
agentbox template build --platform linux_x86
✅ Building sandbox template YOUR_TEMPLATE_ID finished.

Start your Sandbox

You can pass the template ID to the CLI or Python SDK to start your custom Sandbox:

agentbox sandbox sp ${TEMPALTE_ID}

Install the Python SDK, follow the instructions in the Python SDK installation guide.

Quick Start a Sandbox with the Python SDK as follow:

from agentbox import Sandbox

sandbox = Sandbox(api_key="ab_xxxxxxxxxxxxxxxxxxxxxxxxx",
                   template="<YOUR_TEMPLATE_ID>",
                   timeout=120)

result = sandbox.commands.run('ls -l')