The full stack
NanoClaw solves the problem of agents escaping their sandbox. Buckle solves the problem of agents misusing the access they’ve been given. You need both.
How it works
NanoClaw runs each agent in a Docker container. Buckle runs as a sidecar (or shared service) that acts as the HTTP gateway for all agent traffic. When NanoClaw spawns an agent container, it configures the agent to route HTTP traffic through Buckle’s gateway.- NanoClaw creates a Docker container for the agent
- The container’s
HTTP_PROXY/HTTPS_PROXYenvironment variables point to Buckle’s gateway - The agent makes normal HTTP requests. It doesn’t know Buckle exists
- Buckle checks rules (block/rate-limit), injects credentials, and forwards the request
- The response flows back to the agent
Setup
Prerequisites
- Docker running on your machine
- Buckle running (see Quickstart)
- NanoClaw installed (github.com/qwibitai/nanoclaw)
1. Start Buckle
2. Configure agents and credentials in Buckle
You can do this through the dashboard at localhost:10254, or automate it with the Buckle CLI:- CLI (recommended for automation)
- Dashboard
3. Configure NanoClaw to route through Buckle
When NanoClaw spawns agent containers, configure them to use Buckle as their HTTP proxy. The agent containers need:HTTP_PROXYandHTTPS_PROXYpointing to Buckle’s gateway- The Buckle CA certificate for HTTPS interception
- A
Proxy-Authorizationheader with the agent’s access token
applyContainerConfig() handles all of this automatically:
One-line install (Cloud)
If you’re using Buckle Cloud, the dashboard provides a one-line install command that clones NanoClaw, configures your.env with the correct Cloud URL and API key, installs dependencies, and sets up the CLI:
/setup wizard inside the NanoClaw directory.
Migrating from self-hosted to Cloud
If you’re already running NanoClaw with a self-hosted Buckle instance and want to move to Cloud, use the migration script:- Exports secrets from your local Buckle instance
- Updates your CLI config to point at Buckle Cloud
- Finds all NanoClaw installations on your machine (via launchd, systemd, or common directories)
- Updates each NanoClaw
.envwith the Cloud URL and API key - Restarts NanoClaw services so they route through Cloud
After migration, reconnect your OAuth app integrations (Gmail, GitHub, etc.) in the Cloud dashboard since OAuth tokens are not transferable between instances.
Per-agent policies
Since each NanoClaw agent gets its own Buckle agent identity, you can set different rules per agent:- Your “email-agent” can read emails but not delete them
- Your “code-agent” can access GitHub but not Slack
- Your “research-agent” has read-only access to everything, rate-limited to 100 requests per hour