Skip to content

Granular Tool Management for MCP Servers via Configuration file #251792

Open
@matteo-ladrat-Legrand

Description

@matteo-ladrat-Legrand

Problem

Currently, VS Code only allows enabling or disabling entire MCP servers. While we can disable individual tools on a per-session basis through the agent mode interface, this approach has significant limitations:

  • Repetitive: We must manually disable unwanted tools in every new chat session (except if i missed a way to do it)
  • No persistence: Tool preferences don't carry over between sessions
  • Error-prone: Easy to forget to disable risky tools, leading to accidental usage

This forces us to either accept all tools from a server, disable the entire server, or waste time managing tools repeatedly in each session.

Proposed Solution

Add configuration options to manage individual tools from MCP servers through settings, providing persistent control that eliminates the need for per-session management if we want

1st idea: Allowlist approach

{
  "mcp": {
    "my-server": {
      "command": "node",
      "args": ["server.js"],
      "allowedTools": ["safe-tool-1", "safe-tool-2"]
    }
  }
}

2nd idea: Blocklist approach

{
  "mcp": {
    "my-server": {
      "command": "node",
      "args": ["server.js"],
      "disabledTools": ["risky-tool-1", "experimental-tool-2", "useless-tool-3"]
    }
  }
}

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions