Skip to content

Feature: /mcp slash command to enable/disable MCP servers #835

Description

@alecuba16

Summary

Add a /mcp slash command to the TUI that lets users toggle MCP servers on/off interactively. The toggle state persists to ~/.jcode/mcp.json (opencode-style) and refreshes the manager in-memory config and UI state immediately after each toggle.

Problem

Today there is no way to enable or disable an individual MCP server from the TUI without editing the config file and restarting. Users who run several MCP servers have no quick way to temporarily silence a noisy or broken server during a session.

Proposal

  • /mcp slash command opens a toggle list of configured MCP servers.
  • Toggling writes the enabled/disabled flag to ~/.jcode/mcp.json so it survives restarts.
  • The manager in-memory config and the info-widget UI state refresh immediately after each toggle.

Implementation

A working implementation is ready for review on the feature/mcp-server-toggles branch (rebased onto latest master, 465 insertions across 15 files, jcode-app-core + jcode-tui build, mcp + info_widget + slash_command tests pass).

@1jehuang would be great if you could take a look.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions