loading…
Search for a command to run...
loading…
Enables Claude to create, query, and modify BIM elements in Allplan via natural language, with full undo history support.
Enables Claude to create, query, and modify BIM elements in Allplan via natural language, with full undo history support.
A production-grade MCP server that exposes Allplan's BIM API (geometry, attributes, IFC import/export, and layer management) to MCP clients such as Claude Code and Claude Desktop. Runs as a normal Python process that communicates with a PythonPart agent embedded inside Allplan over local TCP, so Claude can create, query, and modify BIM elements while every operation stays inside Allplan's native undo history.
| Component | Version |
|---|---|
| Allplan | 2026 (tested), likely works on 2025 / 2024-1 |
| OS | Windows 10 / 11 |
| Python (external) | 3.12+ |
uv |
pip install uv |
| Claude Code or Claude Desktop | Latest |
git clone https://github.com/andrej-reeg/allplan-mcp-bridge.git
cd allplan-mcp-bridge
uv sync
python scripts\install_pythonpart.py
Auto-detects the Allplan 2026 PythonParts directory. Pass --scripts-dir and
--library-dir explicitly if auto-detection fails.
uv run python -m allplan_mcp_server
You should see {"event": "ipc.connected", ...} in the log. If not, check that the
Allplan palette is visible and the bridge is active.
Add to ~/.claude/claude_desktop_config.json:
{
"mcpServers": {
"allplan": {
"command": "uv",
"args": ["run", "python", "-m", "allplan_mcp_server"],
"cwd": "C:\\path\\to\\allplan-mcp-bridge"
}
}
}
Then ask Claude:
"Create a 5 m wall at (0,0,0) to (5000,0,0), height 3000 mm, thickness 300 mm."
The wall should appear in Allplan, inside one undo bracket.
Claude Code / Desktop
│ stdio JSON-RPC (MCP protocol)
▼
allplan_mcp_server (this repo — normal Python 3.12 process)
│ TCP 127.0.0.1:49152 length-prefixed JSON + HMAC token auth
▼
allplan_agent (PythonPart — runs INSIDE Allplan's embedded Python)
│ thread-safe queue
▼
Allplan main thread → NemAll_Python_* API → BIM document
See docs/architecture.md for the full picture and docs/threading-model.md for the one law that must never be broken.
All settings use the ALLPLAN_MCP_ prefix. Set as environment variables or in a
.env file in the repository root.
| Variable | Default | Description |
|---|---|---|
ALLPLAN_MCP_IPC_TRANSPORT |
tcp |
tcp or named_pipe |
ALLPLAN_MCP_TCP_HOST |
127.0.0.1 |
TCP host (loopback only) |
ALLPLAN_MCP_TCP_PORT |
49152 |
TCP port |
ALLPLAN_MCP_ALLPLAN_WORKSPACE_ROOT |
auto-detected | Root path for IFC file allowlist |
ALLPLAN_MCP_REQUEST_TIMEOUT_SECONDS |
10.0 |
Timeout for standard operations |
ALLPLAN_MCP_LONG_OP_TIMEOUT_SECONDS |
120.0 |
Timeout for IFC import/export |
ALLPLAN_MCP_LOG_LEVEL |
INFO |
DEBUG, INFO, WARNING, ERROR |
ALLPLAN_MCP_MAX_FRAME_BYTES |
16777216 |
IPC frame size cap (16 MiB) |
ALLPLAN_MCP_MAX_ARG_BYTES |
1048576 |
Per-tool argument size cap (1 MiB) |
See docs/tool-catalog.md for the full catalog with input schemas and examples. Short summary:
| Category | Tools |
|---|---|
| Geometry | create_wall, create_slab, create_column, create_beam, get_element, delete_element, move_element |
| Document | get_active_document_info, save_document, undo, redo |
| Attributes | get_attributes, set_attributes |
| Layers | list_layers, create_layer, set_layer_visibility, assign_layer |
| IFC | export_ifc, import_ifc |
| Health | health |
| Version | Status |
|---|---|
| Allplan 2026 | Tested, supported |
| Allplan 2025 | Should work — not formally tested |
| Allplan 2024-1 | Should work — not formally tested |
| Earlier | Not supported |
docs/architecture.md for the design note.create_slab, create_column, create_beam create generic
3-D solids (not architectural elements with material assignments). Architecture
elements are planned for v2.ipc.connect_failed in MCP server logs
~/.allplan-mcp/bridge.log for errors from the agent.Wall/element created but in wrong position
~/.allplan-mcp/debug.log for _wall: attempt N lines — these show which
geometry placement strategy succeeded.PathNotAllowedError on IFC export
ALLPLAN_MCP_ALLPLAN_WORKSPACE_ROOT.Timeout errors on get_active_document_info
{main_thread_required: true}
when called from the background pump. Trigger a mouse event in Allplan (move the
cursor into the drawing) to process the next tick.uv sync --dev
uv run pytest tests/unit tests/integration
uv run ruff check src tests
uv run mypy src
See CONTRIBUTING.md for how to add a new tool.
Run in your terminal:
claude mcp add allplan-mcp-bridge -- npx Security
Low riskAutomated heuristic from public metadata — not a security guarantee.