Skip to content

feat: add MCP server tab to configuration dialog#60

Merged
lewis617 merged 5 commits into
mainfrom
feat/mcp-server-tab
May 19, 2026
Merged

feat: add MCP server tab to configuration dialog#60
lewis617 merged 5 commits into
mainfrom
feat/mcp-server-tab

Conversation

@lewis617
Copy link
Copy Markdown
Contributor

  • Add MCP tab in ConfigurationDialog to view and manage MCP servers
  • Display server status (connected/disconnected/connecting/error), tool count, and connection details
  • Support connect/disconnect buttons with loading state for each server
  • Show empty state with .mcp.json configuration hint when no servers configured
  • Backend: add getMcpServers/connectMcpServer/disconnectMcpServer handlers in messageHandler and chatSession
  • Update spec.md with MCP tab features and three-tab structure description
  • Add e2e demo tests for MCP tab: server list, empty state, and connect/disconnect actions

lewis617 added 5 commits May 19, 2026 16:07
- Add MCP tab in ConfigurationDialog to view and manage MCP servers
- Display server status (connected/disconnected/connecting/error), tool count, and connection details
- Support connect/disconnect buttons with loading state for each server
- Show empty state with .mcp.json configuration hint when no servers configured
- Backend: add getMcpServers/connectMcpServer/disconnectMcpServer handlers in messageHandler and chatSession
- Update spec.md with MCP tab features and three-tab structure description
- Add e2e demo tests for MCP tab: server list, empty state, and connect/disconnect actions
…dates

The previous implementation manually fetched MCP servers after connect/disconnect,
which returned stale 'disconnected' state since the connection is asynchronous.
SDK's onMcpServersChange callback fires after the connection completes, but was
not registered.

Fix:
- Register onMcpServersChange in ChatSession's AgentCallbacks (wave-agent pattern)
- Forward callback through ChatProvider to webview via 'mcpServersUpdate' message
- ConfigurationDialog now handles both mcpServersResponse (initial) and
  mcpServersUpdate (push) commands
- Remove redundant manual getMcpServers calls in messageHandler
- Update notification message to clarify it indicates request sent, not completion
- Display formatted JSON parameters in confirmation dialog for MCP tools (mcp__*)
- Match wave-agent's behavior of showing tool parameters for user review
- Add section 4.4 MCP Tool Confirmation to spec.md
- Add MCP confirmation demo screenshot to product-spec-confirmations.demo.ts
- Update section 6.3 MCP integration to reference the confirmation dialog
@lewis617 lewis617 merged commit 211cb61 into main May 19, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant