
mcp-servers-for-revit/mcp-server-for-revit-python 是从 https://github.com/mcp-servers-for-revit/mcp-server-for-revit-python. 导入的 MCP 服务器候选
概览
mcp-servers-for-revit/mcp-server-for-revit-python 是从 https://github.com/mcp-servers-for-revit/mcp-server-for-revit-python. 导入的 MCP 服务器候选
概述(AI 翻译)
基于 pyRevit 的 Autodesk Revit 模型上下文协议(MCP)实现
本地配对与Autodesk Marketplace发布
该项目正在为Autodesk Marketplace的评审做准备;尚未获得认证。 审核候选人保留全部20个工具,包括Python执行。参见 出版要求与杰出门槛, 隐私信息和安全界限。
安装 pyRevit 扩展后,在 Revit 中选择 MCP > Bridge > Connect 同意并为你的Windows用户创建一个加密配对秘密。选择 断开连接以撤销。更改模型和Python执行的请求显示 其有效载荷在 Revit 中进行审查后再继续。配对也允许本地化 Revit发现和启动。配对在Revit实例间共享,用于同一任务 Windows用户;连接前选择正确的路由端口。
MCP到Revit的桥只接受环回主机。远程VM/LAN的HTTP桥包括
拒绝。可选的HTTP MCP传输需要配对承载头;stdio 是
推荐的发布传输,客户端配置中无需令牌。
不要让任何一个监听者接触到网络、隧道或互联网。
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
MCP server for Revit - Python
A pyRevit-oriented implementation of the Model Context Protocol (MCP) for Autodesk Revit
Local pairing and Autodesk Marketplace publication
This project is being prepared for Autodesk Marketplace review; it is not yet certified. The review candidate retains all 20 tools, including Python execution. See publication requirements and outstanding gates, privacy information, and security boundaries.
After installing the pyRevit extension, choose MCP > Bridge > Connect in Revit to consent and create an encrypted pairing secret for your Windows user. Choose Disconnect to revoke it. Requests that change models and Python execution show their payload for review in Revit before proceeding. Pairing also permits local Revit discovery and launch. Pairing is shared across Revit instances for the same Windows user; select the correct Routes port before connecting.
The MCP-to-Revit bridge accepts only loopback hosts. Remote VM/LAN HTTP bridges are
rejected. Optional HTTP MCP transports require a paired bearer header; stdio is
the recommended publication transport and needs no token in client configuration.
Do not expose either listener to a network, tunnel or the internet.
How?
- This minimal implementation leverages the Routes module inside pyRevit to create a bridge between Revit and Large Language Models (LLMs).
- It provides a straightforward template to get started quickly, letting you prototype and iterate tools to give LLMs access to your Revit models.
- These tools are designed to be expanded for your specific use cases. You’re very welcome to fork the repo and make your own contributions.
- Note: The pyRevit Routes API is currently in draft form and subject to change. This extension authenticates its own routes using Windows-user pairing. Other pyRevit routes/extensions remain outside this protection; review pyRevit server binding and the security document.
Batteries Included
This repo is aimed at:
- Beginners to the Revit API
- Python specialists who aren’t versed in C#
- Anyone wanting to prototype and iterate quickly with LLMs and Revit
It contains:
- A complete Routes implementation for pyRevit
- A minimal MCP server script to connect to any MCP-compatible client
- Several test commands to get you started right away
Key Architecture Components
The system runs as two separate servers working together in a chain:
Claude / LLM Client
|
| MCP Protocol (stdio or HTTP)
v
main.py (MCP Server)
|
| HTTP requests (localhost:48884)
v
pyRevit Routes (REST API running inside Revit)
|
| Revit API calls
v
Revit Application
main.py is the MCP server. It speaks the MCP protocol so that Claude (or any MCP-compatible client) can call tools. When a tool is called, main.py translates it into an HTTP request and forwards it to Revit.
安装
This server does not publish a one-line install command.
Open the repository installation guide 新手?先看 mcpskill.org 教程 →配置
{
"mcpServers": {
"Revit Connector": {
"command": "uv",
"args": [
"run",
"--frozen",
"mcp",
"run",
"/absolute/path/to/main.py"
]
}
}
}