# AutoCAD 2027 MCP Server: fix and setup for AI agents (Claude, Cursor)

> Source: <https://gist.github.com/nextangel-git/71d7dd54991230ea029bd20d11cfde07>
> Published: 2026-10-08 16:47:46+00:00

**TL;DR.** The MCP server bundled with AutoCAD 2027 (offered by the installer as "Autodesk AutoCAD MCP Server") does not work out of the box in build 26.0.460.2523:

1. `ModelContextProtocol.AspNetCore.dll` is missing from the plugin folder →`MCPHTTPSTART` throws`FileNotFoundException` .
2. The HTTP server is disabled by default (`enableHttpServer: false` ).
3. The plugin is not loaded at startup → commands `MCPCONFIG` /`MCPHTTPSTART` are "unknown" until you`NETLOAD` it.

After the fixes below, the server listens on `http://localhost:5001/mcp` (Streamable HTTP) and works with any MCP client.

Tested on Windows 11, AutoCAD 2027 (26.0.460.2523), Russian UI.

- The server is a .NET plugin running **inside `acad.exe`** ; it only works while AutoCAD is open.
- Plugin folder: `C:\Program Files\Autodesk\ApplicationPlugins\AutoCAD-MCP-Server-2027.bundle\Contents\`
- AutoCAD commands: `MCPCONFIG` (Show / Modify / Write / Load / Reset),`MCPHTTPSTART` ,`MCPHTTPSTOP` .
- Endpoint: `http://localhost:<port>/mcp` , the first free port in a range (usually**5001** ).
- Server name `autodesk-autocad-mcp-server` . Tools include`queryAutoCADObjects` ,`discoverAutoCADTypes` ,`aggregateAutoCADObjects` ,`checkAutoCADObjects` ,`manipulateDrawingCanvas` .

Symptom when running `MCPHTTPSTART`:

```
System.IO.FileNotFoundException: Could not load file or assembly
'ModelContextProtocol.AspNetCore, Version=0.4.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51'
   at Autodesk.AutoCAD.Mcp.Http.HttpMcpServer.StartServer()
```

ASP.NET Core 10 itself is already referenced by AutoCAD (`acdbmgd.runtimeconfig.json` lists `Microsoft.AspNetCore.App 10.0.0`); only the MCP SDK's ASP.NET Core package is missing.

1. Find the exact SDK version shipped with the plugin (2027: `0.4.0-preview.3` ):

```
(Get-Item "C:\Program Files\Autodesk\ApplicationPlugins\AutoCAD-MCP-Server-2027.bundle\Contents\ModelContextProtocol.Core.dll").VersionInfo.ProductVersion
```

2. Download the **same version** of the official package from NuGet ([ModelContextProtocol.AspNetCore 0.4.0-preview.3](https://www.nuget.org/packages/ModelContextProtocol.AspNetCore/0.4.0-preview.3) ) into an empty folder and unzip it:

```
Invoke-WebRequest https://www.nuget.org/api/v2/package/ModelContextProtocol.AspNetCore/0.4.0-preview.3 -OutFile pkg.zip
Expand-Archive pkg.zip x
```

3. Verify `x\lib\net10.0\ModelContextProtocol.AspNetCore.dll` :`[Reflection.AssemblyName]::GetAssemblyName("<path>").FullName` must show`Version=0.4.0.0, PublicKeyToken=cc7b13ffcd2ddd51` , and its ProductVersion must have the same commit hash as`ModelContextProtocol.Core.dll` . (The NuGet DLL has no Authenticode signature; Autodesk re-signs its copies. This is expected.)
4. Copy it into the plugin's `Contents` folder (requires admin):

```
Copy-Item x\lib\net10.0\ModelContextProtocol.AspNetCore.dll "C:\Program Files\Autodesk\ApplicationPlugins\AutoCAD-MCP-Server-2027.bundle\Contents\"
```

An AutoCAD update may remove the file or change the SDK version; repeat this step if the error comes back.

The config file path comes from the environment variable `ACMCP_TOOLS_CONFIG_FILE`. Without it, `MCPCONFIG Write/Load` refuse to work.

1. Set the variable, then **restart AutoCAD** :

```
setx ACMCP_TOOLS_CONFIG_FILE "%APPDATA%\Autodesk\acmcp-config.json"
```

2. Write the file in exactly this format (nested `toolsConfiguration` , camelCase). A flat or PascalCase file is silently ignored by`Load` :

```
{
  "toolsConfiguration": {
    "enabledTools": [],
    "disabledTools": [],
    "enableAllToolsByDefault": true,
    "enableExperimentalFeatures": false,
    "enableDebugLogging": false,
    "enableHttpServer": true,
    "jsonCompression": {
      "enableObjectDeduplication": false,
      "maxPropertyCountForObjectDeduplication": 4,
      "minOccurrenceForObjectDeduplication": 2,
      "enableStringDeduplication": false,
      "enableArrayCompression": true,
      "enabled": true,
      "arrayCompressionMinSize": 3,
      "arrayCompressionMaxSparsity": 0.5,
      "arrayCompressionMinSimilarity": 0.7
    }
  }
}
```

`MCPCONFIG` → `Show` prints the current JSON; `Write` saves it to the file. Use either as the reference format.

In the **AutoCAD command line** (not PowerShell):

1. `NETLOAD` →`C:\Program Files\Autodesk\ApplicationPlugins\AutoCAD-MCP-Server-2027.bundle\Contents\acmcp.dll`
2. `MCPCONFIG` →`Load` →`Configuration imported successfully from: ...`
3. `MCPHTTPSTART` →`AutoCAD MCP Server is ... running on http://localhost:5001/mcp`

Automated via COM. Run it in **Windows PowerShell 5.1** (`powershell.exe`), because PowerShell 7 has no `Marshal.GetActiveObject`. Pass all prompt answers in a **single** `SendCommand` string, otherwise the COM call blocks at the first prompt.

``` php
function Retry([scriptblock]$b) {
    for ($k = 0; $k -lt 60; $k++) { try { return & $b } catch { Start-Sleep 1 } }
    throw "AutoCAD not ready"
}
$ac = Retry { [Runtime.InteropServices.Marshal]::GetActiveObject("AutoCAD.Application") }
if ((Retry { $ac.Documents.Count }) -eq 0) { [void](Retry { $ac.Documents.Add() }); Start-Sleep 3 }
$d = Retry { $ac.ActiveDocument }
$dll = "C:\Program Files\Autodesk\ApplicationPlugins\AutoCAD-MCP-Server-2027.bundle\Contents\acmcp.dll"
Retry { $d.SendCommand("(setvar `"FILEDIA`" 0)` n_NETLOAD`n`"$dll`"` n(setvar `"FILEDIA`" 1)` n_MCPCONFIG`n_Load` n_MCPHTTPSTART`n") }
```

Check that the port is open: `Get-NetTCPConnection -State Listen -OwningProcess (Get-Process acad).Id`.

Claude Code (`.mcp.json` in the project root). Any client that supports Streamable HTTP can use the same URL:

```
{ "mcpServers": { "autocad": { "type": "http", "url": "http://localhost:5001/mcp" } } }
```

Smoke test without a client. The response must contain `"name":"autodesk-autocad-mcp-server"`:

```
Invoke-WebRequest http://localhost:5001/mcp -Method Post -ContentType application/json `
  -Headers @{Accept='application/json, text/event-stream'} `
  -Body '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2025-06-18","capabilities":{},"clientInfo":{"name":"probe","version":"1"}}}'
```

| Symptom | Cause | Fix | 
|---|---|---|
| `MCPCONFIG: The term ... is not recognized` | Typed in PowerShell | Type it in the AutoCAD command line | 
| `Unknown command "MCPCONFIG"` | Plugin not loaded | `NETLOAD acmcp.dll` (step 3) | 
| `NETLOAD` succeeds silently but commands are still unknown | AutoCAD already loaded the DLL itself (built-in assistant) without registering commands | Restart AutoCAD and `NETLOAD` right away | 
| `FileNotFoundException ... ModelContextProtocol.AspNetCore` | Missing DLL | Step 1 | 
| `MCPHTTPSTART` prints nothing, no port opens | `enableHttpServer` is`false` | Step 2, then `MCPCONFIG` →`Load` | 
| `Load` succeeded but`Show` still says`false` | Flat or PascalCase JSON | Use the format from step 2 | 
| `(getenv "ACMCP_TOOLS_CONFIG_FILE")` returns`nil` | AutoCAD was started before `setx` | Restart AutoCAD | 
| COM: `Documents.Count = 0` ,`ActiveDocument` is null | Only the Start tab is open | `Documents.Add()` , wait 2–3 s | 
| COM: `RPC_E_CALL_REJECTED` | AutoCAD is busy or waiting at a prompt | Retry; cancel the stuck prompt with Esc | 
| `SendKeys` types Cyrillic letters | Non-English keyboard layout | Use COM `SendCommand` instead | 
| Command line not visible | Hidden | `Ctrl+9` | 
| Error returns after an AutoCAD update | DLL removed or SDK version changed | Repeat step 1 with the new version | 

*Keywords: AutoCAD 2027 MCP, Model Context Protocol, acmcp.dll, MCPHTTPSTART, MCPCONFIG, ACMCP_TOOLS_CONFIG_FILE, ModelContextProtocol.AspNetCore FileNotFoundException, Claude Code AutoCAD.*
