gbox logo

gbox

by babelcloud

gbox is an open source project that provides a self-hostable sandbox for MCP integration or other AI agent usecases. The sandbox can be used as a computer for agent and includes tools like terminal, browser, and file editor.

View on GitHub

Last updated: N/A

What is gbox?

gbox is a self-hostable sandbox designed to enable MCP client integration and other AI agent applications. It provides a secure and isolated environment with essential tools for agents to perform tasks.

How to use gbox?

gbox can be installed via Homebrew on macOS. After installation, you can initialize the environment, export MCP configurations, and merge them into AI clients like Claude Desktop or Cursor. The gbox command-line tool allows you to manage sandbox containers, execute commands, and configure volume mounts.

Key features of gbox

  • Terminal: Execute Linux commands and Python scripts.

  • File: Mount host folders, access files via HTTP, and read file content.

  • Browser: Open URLs and retrieve content.

  • HTTP Server: Start HTTP services on demand.

  • SDKs: Python and Typescript SDKs for integration.

  • MCP: Standard MCP support and integration with Claude Desktop & Cursor.

Use cases of gbox

  • Generating Diagrams

  • Generating PDFs

  • Analyzing and Calculation

  • Processing Local Files

  • Execute Arbitrary Tasks

FAQ from gbox

How to run gbox in dev env instead of the system installed one?

  1. Stop the installed gbox by gbox cleanup. It will stop the api server so that you can run the api server in dev env. 2. Execute make api-dev in project root. 3. Execute ./gbox box list, this is the command run from your dev env.

How to connect MCP client such as Claude Desktop to the MCP server in dev env?

  1. Execute make mcp-dev in project root. 2. Execute ./gbox mcp export --merge-to claude

How to open MCP inspect?

  1. Execute make mcp-inspect in project root. 2. Click the link returned in terminal.

How to build and use image in dev env?

  1. Execute make build-image-python in project root to build Python image, or make build-images to build all images. 2. Change the image name as needed (e.g., make build-image-typescript for TypeScript image). 3. You may need to delete current sandboxes to make the new image effective ./gbox box delete --all

Why MCP client still get the old MCP content?

  1. After you change MCP configuration such as tool definitions, you need to run make build to update the dist/index.js file. 2. You may also need to execute ./gbox mcp export --merge-to claude