Isolated sandboxes

Set packages and network rules once. Each session gets its own sandbox.

  1. Restrict outbound hosts

    Allow only the hosts, package registries, and MCP servers a task needs.

    Read the docs
    const environment = await client.waitForPending(  await client.environments.create({    name: "locked-down",    config: {      type: "cloud",      networking: {        type: "limited",        allowed_hosts: ["github.com"],        allow_package_managers: true,        allow_mcp_servers: true,      },    },  }),)
  2. Install packages on boot

    Declare apt, npm, or pip packages and an optional setup script.

    Read the docs
    await client.environments.update(environment.id, {  version: environment.version,  config: {    type: "cloud",    setup: {      packages: { npm: ["typescript", "vitest"] },      script: "corepack enable",    },  },})
  3. Boot on demand, sleep when idle

    Each session gets its own Linux container and keeps /workspace across sleeps.

    Read the docs
    const session = await client.waitForPending(  await client.sessions.create({    agent: agent.id,    environment_id: environment.id,  }),)

Managed agents for any harness

Pick the harness and model. Checkfu runs everything around them.