vscode icon indicating copy to clipboard operation
vscode copied to clipboard

MCP: support an array of commands to start an MCP server

Open joelverhagen opened this issue 6 months ago • 2 comments

Currently, VS Code only supports a single command to launch an MCP server. https://code.visualstudio.com/docs/copilot/chat/mcp-servers#_configuration-format

It would be great if the server JSON object supported a commands property, instead of a single command + args + env + envFile. This would allow a setup command first, and then a start command after.

For a .NET based MCP server, this could look:

{
  "mcp": {
    "servers": {
      "my-mcp-server": {
        "type": "stdio",
        "commands": [
          {
            "command": "dotnet",
            "args": [ "tool", "install", "--global", "Knapcode.PirateMcp", "--version", "2.0.0" ]
          },
          { 
            "command": "piratemcp", // may need PATH to be reloaded... that's beside the point...
            "args": [ ]
          }
        ]
      }
    }
  }
}

This would also allow npx (or similar) commands to separate the setup from the install command to provide a better UI or debugging experience.

joelverhagen avatar May 20 '25 16:05 joelverhagen

Marking as feature req to gauge interest

connor4312 avatar May 22 '25 16:05 connor4312

This feature request is now a candidate for our backlog. The community has 60 days to upvote the issue. If it receives 20 upvotes we will move it to our backlog. If not, we will close it. To learn more about how we handle feature requests, please see our documentation.

Happy Coding!

This feature request has not yet received the 20 community upvotes it takes to make to our backlog. 10 days to go. To learn more about how we handle feature requests, please see our documentation.

Happy Coding!

:slightly_frowning_face: In the last 60 days, this feature request has received less than 20 community upvotes and we closed it. Still a big Thank You to you for taking the time to create this issue! To learn more about how we handle feature requests, please see our documentation.

Happy Coding!