Connecting GitHub Copilot to PVX.AI

Overview

PVX.AI runs an MCP (Model Context Protocol) server inside AutoCAD that AI clients on the same computer can use. “Copilot” names two product families, and only one of them can connect.

  • GitHub Copilot in VS Code, Visual Studio and the Copilot CLI runs its MCP client on your computer, so it can connect. This article covers these.
  • Microsoft Copilot cannot connect. For the Copilot app on Windows and the web, Microsoft documents no way to add your own MCP server. Microsoft 365 Copilot and Copilot Studio agents connect to remotely hosted MCP servers (Copilot Studio asks for a server URL and reaches it through Power Platform connectors). The PVX.AI server only listens on your own computer, so these products cannot reach it. The same applies to the Copilot coding agent on github.com, which runs in GitHub’s cloud.

Prerequisites

  • Windows, with PVX.AI 2.15 or later installed in AutoCAD 2023 or newer.
  • A PVX.AI license that includes the Claude (MCP) integration.
  • A GitHub Copilot plan, signed in, on the same computer as AutoCAD: VS Code, Visual Studio 2026 (or 2022 version 17.14 or later), or the Copilot CLI.
  • On Copilot Business or Enterprise, an administrator must enable the MCP servers in Copilot policy, which is off by default. If the organisation allows only servers from its MCP registry, PVX.AI must be added there too.

Step-by-Step Guide

1. Start AutoCAD and find the address

Start AutoCAD with PVX.AI and open a drawing. The server starts by itself at http://127.0.0.1:52780/mcp. If that port was busy, the address differs: the generic HTTP article (see Related) has a PowerShell snippet that reads the real one and explains how to fix the port. No token is needed.

2. Add the server in VS Code or the Copilot CLI

VS Code and the Copilot CLI read the same personal file, %USERPROFILE%\.copilot\mcp-config.json, so one entry serves both. In VS Code, select Copilot as the session target (the default for new chats), run Chat: Open Customizations, select MCP Servers, then Add Server (+) in the User group. Choose HTTP (HTTP or Server-Sent Events), enter the address, enter pvxai as the server ID, and select Global > Copilot Global.

In the Copilot CLI, run this in a terminal (or /mcp add inside a session):

copilot mcp add --transport http pvxai http://127.0.0.1:52780/mcp

Either way, the file then holds this entry, which you can also write by hand:

{
  "mcpServers": {
    "pvxai": {
      "type": "http",
      "url": "http://127.0.0.1:52780/mcp",
      "tools": ["*"]
    }
  }
}

Older guides put servers in .vscode/mcp.json under a servers key. That format belongs to VS Code’s Local harness, which is deprecated and due to be removed in February 2027; use the file above for new setups.

3. Or add it in Visual Studio

Create %USERPROFILE%\.mcp.json in Visual Studio with this content and save it:

{
  "servers": {
    "pvxai": {
      "url": "http://127.0.0.1:52780/mcp"
    }
  }
}

Switch the chat to Agent mode and open Tools. Visual Studio adds a new server’s tools switched off, so tick the PVX.AI tools. JetBrains IDEs use the same servers format: in agent mode, open the tools icon, select Add MCP Tools and add the entry to the mcp.json that opens.

4. Check the connection

The server should report 14 tools, such as system, query, solar_layout and solar_electrical. In the CLI, run /mcp get pvxai (or copilot mcp list from a terminal). In VS Code, run Chat: Open Customizations, select MCP Servers and check that pvxai is listed with its tools; if it does not start, check its server output there.

5. Make a first request

Start with a question that changes nothing: “Use the pvxai tools to tell me how many racks and strings are in this drawing and the DC capacity.” Expand the tool call to confirm the answer came from PVX.AI. Copilot asks before it runs a tool: in VS Code, approve or decline the request as it appears; in Visual Studio use the Allow or Confirm drop-down to approve for the session, the solution or always. The Claude Desktop article lists more requests you can make.


Tips & Recommendations

Following the port with the bridge

A fixed URL stops working if the port moves. The bridge program finds the running AutoCAD by itself. Copy %ProgramFiles%\Autodesk\ApplicationPlugins\PVXAI.Cad.bundle\pvxai-solar-design.mcpb to a folder such as C:\PVXAI\bridge, rename the copy to end in .zip and extract it. Then add it as a command (stdio) server instead of the URL, with no arguments; in VS Code choose the command (stdio) option in step 2. Extract it again after updating PVX.AI.

copilot mcp add pvxai -- C:\PVXAI\bridge\server\PVXAI.Bridge.exe

Built-in prompts

PVX.AI offers six prompts, such as design_from_brief and review_design. Visual Studio lists them under + Add Reference > Prompts > MCP prompts. VS Code Copilot sessions do not show MCP prompts, so describe the task in plain words instead.

Good to know

  • Long operations run as jobs that Copilot waits for in steps of up to 55 seconds. Removing racks, clearing electrical design or resetting terrain shows a preview first.
  • Copilot cannot undo. Press Ctrl+Z in AutoCAD.
  • An action run through Copilot uses credits the same way as the same action on the ribbon.

Troubleshooting

  • The server does not appear in VS Code: check that the chat’s session target is Copilot and that the entry is in mcp-config.json, not .vscode/mcp.json.
  • Blocked by your organisation: ask your administrator about the MCP policy and allowlist. Local settings cannot override them.
  • Worked yesterday, fails today: the port probably moved. Read the address again, fix the port, or use the bridge.
  • Calls time out: close any dialog open in AutoCAD and check the drawing before retrying an action that uses credits.

Menu names can differ between versions of Copilot; see the VS Code documentation on MCP servers.

Related