Skip to main content

Connect VS Code

The steps below demonstrate how to connect to the DoiT MCP server using Visual Studio Code. VS Code loads MCP servers from an mcp.json file, then makes the tools available in GitHub Copilot Chat when MCP is enabled for your setup. Before you connect, confirm you meet the Required permissions.

Prerequisites

Supported connection methods

VS Code supports stdio and Streamable HTTP (type: "http"). See Connection methods for authentication details. The examples below show both.

Configure with stdio

  1. In VS Code, open the Command Palette (⇧⌘P on macOS, Ctrl+Shift+P on Windows or Linux).

  2. Run MCP: Open Workspace Folder MCP Configuration to create or edit .vscode/mcp.json in the current workspace, or run MCP: Open User Configuration if you want the server available in all workspaces.

  3. In the mcp.json file, add an entry for DoiT MCP server using standard input/output (stdio) and the published package @doitintl/doit-mcp-server. Replace your_doit_api_key with your personal API token.

    {
    "servers": {
    "doitMcp": {
    "type": "stdio",
    "command": "npx",
    "args": ["-y", "@doitintl/doit-mcp-server@latest"],
    "env": {
    "DOIT_API_KEY": "your_doit_api_key"
    }
    }
    }
    }
  4. Save mcp.json. If VS Code prompts you to trust or start the server, confirm so the process can launch.

  5. Confirm the DoiT MCP server is listed and started by running MCP: List Servers from the Command Palette. In Copilot Chat, select Agent mode and use the tools picker to confirm that DoiT MCP tools are available.

You can now use GitHub Copilot Chat in VS Code to ask questions or make requests related to DoiT Cloud Intelligence data.

Configure with Streamable HTTP

  1. Open the same mcp.json file described under Configure with stdio.

  2. Use an HTTP server entry:

    {
    "servers": {
    "doitMcp": {
    "type": "http",
    "url": "https://mcp.doit.com/mcp"
    }
    }
    }
  3. Save mcp.json, complete the DoiT sign-in and consent flow when prompted, then confirm the server with MCP: List Servers.