# e2b-sandbox

e2b-sandbox executes AI-generated code in isolated cloud VMs with resource monitoring, process streaming, and multiple language runtimes.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode, Windsurf (Devin Desktop), Claude.ai · 2 installs
- Author: padak
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/padak/ng_component/tree/HEAD/.claude/skills/e2b_skill/SKILL.md
- Updated: 2025-11-13
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/e2b-sandbox

## What it does

This skill guides coding agents on orchestrating secure cloud micro-VMs using the E2B SDK. Instances spin up in roughly 150 milliseconds, offering an isolated filesystem with either 1GB on the Hobby tier or 5GB on Pro. The agent learns how to run scripts across Python, JavaScript, TypeScript, and Bash while capturing standard outputs, logs, and generated visual artifacts.

It covers the entire VM lifecycle: setting execution deadlines, pausing instances, inspecting metadata, and running shell commands in the background with real-time output streaming. The skill also details telemetry handling, including querying CPU, memory, and disk utilization snapshots collected every few seconds.

Running code and tracking lifecycle events via the HTTP endpoint demands an E2B_API_KEY. Without it, the client cannot authenticate against the cloud infrastructure.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add padak/ng_component --skill e2b-sandbox -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/e2b_skill/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/e2b_skill/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add padak/ng_component --skill e2b-sandbox -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/e2b_skill/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add padak/ng_component --skill e2b-sandbox -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/e2b_skill/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install padak/ng_component .claude/skills/e2b_skill
```

2. **Manually: put the files in place**
- File: `.github/skills/e2b_skill/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add padak/ng_component --skill e2b-sandbox -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/padak/ng_component --path .claude/skills/e2b_skill
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/e2b_skill/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add padak/ng_component --skill e2b-sandbox -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/padak/ng_component/tree/HEAD/.claude/skills/e2b_skill/SKILL.md

## When to use it
- execute untrusted AI-generated code inside disposable cloud VMs
- run TypeScript and JavaScript snippets with top-level await outside your host machine
- stream terminal outputs from long-running background tasks in real time
- track CPU, RAM, and disk consumption across active sandbox environments

## Example prompts
- Create an E2B sandbox with a 10-minute timeout and execute this Python script
- Run this TypeScript snippet inside an isolated environment and print the output
- Fetch the latest CPU and memory metrics for this active E2B sandbox instance

## Similar
- [bailian-sandbox](https://affpapa.org/en/nevibecode/skills/bailian-sandbox.md) — skill · 1100 installs
- [zeroboot-vm-sandbox](https://affpapa.org/en/nevibecode/skills/zeroboot-vm-sandbox.md) — skill · 1300 installs
- [sandbox-sdk](https://affpapa.org/en/nevibecode/skills/sandbox-sdk.md) — skill · 4 installs
- [deno-sandbox](https://affpapa.org/en/nevibecode/skills/deno-sandbox.md) — skill · 367 installs
- [sandbox-stable](https://affpapa.org/en/nevibecode/skills/sandbox-stable.md) — skill · 85900 installs
- [sandbox-self-test](https://affpapa.org/en/nevibecode/skills/sandbox-self-test.md) — skill · ★ 81 repo stars

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
