Skip to content

Commit 7ea2d9d

Browse files
committed
docs(mcp): add sandbox_run_project as default, Claude Code setup guide
1 parent 8ce91e2 commit 7ea2d9d

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

apps/docs/content/docs/mcp/index.mdx

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@ description: Model Context Protocol server for AI agent integration.
55

66
The `@sandchest/mcp` package is a [Model Context Protocol](https://modelcontextprotocol.io/) server that gives AI agents access to Sandchest sandboxes. It works with any MCP-compatible client including Claude, Cursor, and Windsurf.
77

8+
For most agent requests, the best default is `sandbox_run_project`: one tool call that creates a sandbox, loads the project, installs dependencies, runs the command, and returns a replay URL.
9+
810
## Installation
911

1012
```bash
@@ -15,6 +17,19 @@ bun add @sandchest/mcp
1517

1618
The MCP server requires a `SANDCHEST_API_KEY` environment variable.
1719

20+
If you want agents to upload local code with tools like `sandbox_run_project` or `sandbox_upload_dir`, also set `SANDCHEST_MCP_ALLOWED_PATHS` to one or more approved local roots.
21+
22+
### Claude Code
23+
24+
The fastest setup path is:
25+
26+
```bash
27+
sandchest mcp init claude-code --allow-path /absolute/path/to/your/workspace
28+
sandchest skill install --global
29+
```
30+
31+
This writes the MCP config to `~/.claude/mcp.json`, allow-lists your local workspace for upload tools, and installs the Sandchest skill so Claude Code is more likely to choose `sandbox_run_project` first.
32+
1833
### Claude Desktop
1934

2035
Add to your Claude Desktop MCP config (`~/Library/Application Support/Claude/claude_desktop_config.json`):
@@ -55,11 +70,22 @@ Add to your Cursor MCP settings:
5570

5671
With the MCP server, AI agents can:
5772

73+
- Run a repo command in a fresh sandbox with one tool call
5874
- Create isolated sandboxes to run code safely
5975
- Execute commands and inspect results
6076
- Upload and download files
6177
- Fork sandboxes for experimentation
6278
- Use persistent sessions for multi-step workflows
6379
- Access replay URLs for sharing
6480

81+
## Recommended workflow
82+
83+
Use these defaults in order:
84+
85+
1. For "run this command in a new sandbox" requests, use `sandbox_run_project`.
86+
2. For repeated work, check `sandbox_list` and fork an existing prepared sandbox.
87+
3. Drop to `sandbox_create`, `sandbox_git_clone`, `sandbox_upload_dir`, and sessions only when you need fine-grained control.
88+
89+
For Claude Code, also install the bundled Sandchest skill. It reinforces the same decision tree and reduces the odds of the agent falling back to manual multi-step setup for one-shot tasks.
90+
6591
See the [Tools Reference](/docs/mcp/tools) for the complete list.

0 commit comments

Comments
 (0)