Skip to content

Quickstart

Create your first coding agent sandbox in 5 minutes.

1. Install

curl -fsSL https://raw.githubusercontent.com/shakedaskayo/ciab/main/install.sh | bash

See Installation for more options.

2. Start the Server

ciab server start --config config.toml

The API is now available at http://localhost:9090 (default port).

Health Check

Verify the server is running: curl http://localhost:9090/health

3. Create a Sandbox

ciab sandbox create \
  --provider claude-code \
  --name my-first-sandbox \
  --env ANTHROPIC_API_KEY=$ANTHROPIC_API_KEY

This will:

  1. Validate the sandbox specification
  2. Resolve and inject credentials
  3. Start the agent process (local by default, or in a container with Docker/OpenSandbox)

You'll see provisioning progress streamed to your terminal.

4. Chat with the Agent

# Single message
ciab agent chat --sandbox-id <id> --message "Explain the project structure" --stream

# Interactive mode
ciab agent chat --sandbox-id <id> --interactive --stream

The --stream flag shows the agent's response as it's generated, including tool use.

5. Execute Commands

# Run a command in the sandbox
ciab sandbox exec <id> -- ls -la /workspace

# Check installed tools
ciab sandbox exec <id> -- node --version

6. Browse Files

# List files
ciab files list <id> --path /workspace

# Download a file
ciab files download <id> --path /workspace/README.md --output ./README.md

# Upload a file
ciab files upload <id> --path /workspace/data.json --input ./data.json

7. Monitor Resources

ciab sandbox stats <id>

Output shows CPU usage, memory, disk, and network statistics.

8. Clean Up

# Stop the sandbox
ciab sandbox stop <id>

# Delete it entirely
ciab sandbox delete <id>

Using the REST API

All CLI operations are available via the REST API:

# Create a sandbox
curl -X POST http://localhost:9090/api/v1/sandboxes \
  -H "Content-Type: application/json" \
  -d '{
    "agent_provider": "claude-code",
    "name": "api-sandbox",
    "env_vars": {
      "ANTHROPIC_API_KEY": "sk-ant-..."
    }
  }'

# Send a message
curl -X POST http://localhost:9090/api/v1/sessions/<sid>/messages \
  -H "Content-Type: application/json" \
  -d '{"role": "user", "content": [{"type": "text", "text": "Hello!"}]}'

# Stream events (SSE)
curl -N http://localhost:9090/api/v1/sandboxes/<id>/stream

Next Steps