Skip to main content
ClaudeWave
Slash Command745 repo starsupdated 20d ago

flow-nexus-sandbox

This command creates and manages isolated E2B sandbox environments for executing untrusted or experimental code safely. Use it when you need to run code in controlled containers with specific templates (Node.js, Python, React, Next.js, or vanilla JavaScript), manage dependencies, set environment variables, upload files, and monitor execution with output capture and timeout controls.

Install in Claude Code
Copy
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/ruvnet/agentic-flow/HEAD/.claude/commands/flow-nexus/sandbox.md -o ~/.claude/commands/flow-nexus-sandbox.md
Then start a new Claude Code session; the slash command loads automatically.

sandbox.md

# Flow Nexus Sandboxes

Deploy and manage isolated execution environments.

## Create Sandbox
```javascript
mcp__flow-nexus__sandbox_create({
  template: "node", // node, python, react, nextjs, vanilla, base
  name: "my-sandbox",
  env_vars: {
    API_KEY: "your_api_key",
    NODE_ENV: "development"
  },
  timeout: 3600 // seconds
})
```

## Execute Code
```javascript
mcp__flow-nexus__sandbox_execute({
  sandbox_id: "sandbox_id",
  code: `
    console.log('Hello from sandbox!');
    const result = await fetch('https://api.example.com');
    return result.json();
  `,
  language: "javascript",
  capture_output: true
})
```

## Manage Sandboxes
```javascript
// List all sandboxes
mcp__flow-nexus__sandbox_list({ status: "running" })

// Get status
mcp__flow-nexus__sandbox_status({ sandbox_id: "id" })

// Upload file
mcp__flow-nexus__sandbox_upload({
  sandbox_id: "id",
  file_path: "/app/data.json",
  content: JSON.stringify(data)
})

// Stop sandbox
mcp__flow-nexus__sandbox_stop({ sandbox_id: "id" })

// Delete sandbox
mcp__flow-nexus__sandbox_delete({ sandbox_id: "id" })
```

## Templates
- **node**: Node.js environment
- **python**: Python 3.x environment  
- **react**: React development setup
- **nextjs**: Next.js full-stack
- **vanilla**: Basic HTML/CSS/JS
- **base**: Minimal Linux environment

## Common Patterns
```javascript
// API development sandbox
mcp__flow-nexus__sandbox_create({
  template: "node",
  name: "api-dev",
  install_packages: ["express", "cors", "dotenv"],
  startup_script: "npm run dev"
})

// ML sandbox
mcp__flow-nexus__sandbox_create({
  template: "python",
  name: "ml-training",
  install_packages: ["numpy", "pandas", "scikit-learn"]
})
```
base-template-generatorSubagent

Use this agent when you need to create foundational templates, boilerplate code, or starter configurations for new projects, components, or features. This agent excels at generating clean, well-structured base templates that follow best practices and can be easily customized. Examples: <example>Context: User needs to start a new React component and wants a solid foundation. user: 'I need to create a new user profile component' assistant: 'I'll use the base-template-generator agent to create a comprehensive React component template with proper structure, TypeScript definitions, and styling setup.' <commentary>Since the user needs a foundational template for a new component, use the base-template-generator agent to create a well-structured starting point.</commentary></example> <example>Context: User is setting up a new API endpoint and needs a template. user: 'Can you help me set up a new REST API endpoint for user management?' assistant: 'I'll use the base-template-generator agent to create a complete API endpoint template with proper error handling, validation, and documentation structure.' <commentary>The user needs a foundational template for an API endpoint, so use the base-template-generator agent to provide a comprehensive starting point.</commentary></example>

claude-flow-helpSlash Command

Show Claude-Flow commands and usage

claude-flow-memorySlash Command

Interact with Claude-Flow memory system

claude-flow-swarmSlash Command

Coordinate multi-agent swarms for complex tasks

flow-nexus-app-storeSlash Command

Browse, publish, and deploy applications

flow-nexus-challengesSlash Command

Coding challenges, achievements, and leaderboards

flow-nexus-authSlash Command

Flow Nexus authentication and user management

flow-nexus-neuralSlash Command

Train and deploy neural networks in distributed sandboxes