Integrasi MCP (Server Alat Eksternal)

July 29, 2026 · View on GitHub

Codewhale dapat memuat alat tambahan melalui MCP (Model Context Protocol). Server MCP dapat berupa proses stdio lokal yang dijalankan oleh TUI, atau server jarak jauh berbasis URL yang menggunakan Streamable HTTP dengan fallback SSE.


Konfigurasi Server MCP

Konfigurasi server MCP disimpan di dalam mcp.json (baik di $CODEWHALE_HOME/mcp.json untuk global atau .codewhale/mcp.json untuk proyek).

Contoh konfigurasi mcp.json:

{
  "mcpServers": {
    "filesystem": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-filesystem", "/path/to/allowed/dir"]
    },
    "git": {
      "command": "uvx",
      "args": ["mcp-server-git", "--repository", "."]
    }
  }
}

Perintah CLI & TUI untuk MCP

  • /mcp — Kelola server dan alat MCP dari dalam TUI.
  • codewhale mcp init — Inisialisasi templat konfigurasi mcp.json.
  • codewhale doctor — Periksa kesehatan dan kesiapan server MCP yang terkonfigurasi.