
SandboxAPI
io.github.MichielDeRuiter由 GitHub 帳號 MichielDeRuiter 發布v1.0.0更新於 Oct 24, 2026
Execute code in 8 languages (Python, JS, TS, Go, Java, C++, C, Bash) in gVisor sandboxes.
概覽
SandboxAPI 讓 AI 助理在隔離的 gVisor 沙箱中執行八種語言的程式碼,可透過託管遠端端點或自架 Docker 服務使用。
- 可以做什麼
- 以 Python、JavaScript、TypeScript、Go、Java、C++、C 或 Bash 執行程式碼,可指定逾時與標準輸入
- 批次送出多段程式碼,每段在各自獨立的沙箱中執行
- 列出支援的語言及其版本與範例程式碼
- 適用情境
- 適合助理需要真正執行或測試程式碼、而不只是推理程式碼的情況,且希望執行過程與自己的電腦和網路隔離。適用於快速驗證腳本、比較不同語言與批次實驗。
- 執行需求
- 可使用託管遠端端點(OAuth 或 Bearer API 金鑰),也可在本機執行 Docker 映像或 Go 建置。自架需 SANDBOXAPI_API_KEY,MCP_API_KEY、MCP_PORT、SANDBOXAPI_URL 為選用。API 金鑰需向廠商網站或 RapidAPI 取得。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 SandboxAPI,將其新增到工作區。
- 連接 所需的 憑證。它們會被私密儲存,絕不會在公開頁面上展示。
- 為需要使用其工具的對話啟用該服務。
Web executable,透過 Streamable HTTP。 遠端服務在工作區中設定後即可從網頁執行環境執行。
交給代理程式安裝
把這段提示詞貼上到 Claude Code、Codex、Cursor 等代理程式,或 SourceWeft 對話中。代理程式會讀取該伺服器的安裝指南,先向你展示發布者、端點和登入方式,經你同意後再把它新增到你的客戶端。金鑰不會寫進任何命令。
閱讀 https://sourceweft.com/mcp/io.github.MichielDeRuiter%2Fsandboxapi-mcp/install.md,並按其中說明把這個 MCP 伺服器接入我的客戶端。修改任何設定之前,先告訴我它的發布者、端點和登入方式,等我確認。不要把 API 金鑰寫進命令或我會提交的檔案;問我金鑰應從哪裡取得。其他 MCP 客戶端
把它新增到你客戶端的 mcpServers 設定中。 客戶端會在首次連接時完成 OAuth 登入。
{
"mcpServers": {
"sandboxapi": {
"type": "http",
"url": "https://mcp.sandboxapi.dev/mcp"
}
}
}README
SandboxAPI MCP Server
Give your AI agent the ability to execute code in 8 programming languages, safely.
SandboxAPI MCP Server connects any MCP-compatible AI client (Claude, Cursor, VS Code, Windsurf, etc.) to secure code execution. Every execution runs inside a gVisor-sandboxed Docker container with no network access, strict resource limits, and ephemeral filesystems.
Quick Start
Option 1: Remote Server (No Setup)
Connect directly to the hosted endpoint. No local installation required.
Claude Desktop (claude_desktop_config.json):
VS Code (.vscode/mcp.json):
Cursor (~/.cursor/mcp.json):
Option 2: Docker
Then point your client to http://localhost:8081/mcp.
Option 3: Build from Source
Available Tools
execute_code
Execute code in a sandboxed container.
execute_batch
Execute multiple code snippets. Each runs in its own isolated sandbox.
list_languages
List all supported programming languages with versions and example code. No parameters.
Supported Languages
Environment Variables
Security
Every code execution is isolated with defense-in-depth:
- gVisor (runsc) — User-space kernel intercepts all syscalls
- Network isolation — Executed code cannot make outbound connections
- Resource limits — CPU, memory, and disk usage are capped
- Ephemeral containers — Destroyed immediately after execution
- Read-only filesystem — No persistent writes between executions
- Code size limits — Source code capped at 1MB
- Timeout enforcement — Hard kill after configured timeout
API Key
Get your API key at sandboxapi.dev or through RapidAPI.
Links
License
MIT
來源:README.md,提交 edb9d15
工具
0版本歷史
1- v1.0.0最新Sep 16, 2026
評分
已滿足適用檢查項的 85%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通必需25 分
- 已宣告認證方式必需10 分
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分