LN

ljmerza/nodered-mcp

开发工具

本页由 AI 翻译,技术细节请以原文为准。 查看原文

24 stars 3 forks 质量 80 趋势 30MIT

用于读取、查询和编辑Node-RED flows.json的MCP服务器

概览

Node-RED的MCP服务器。从MCP客户端读取、编辑并部署你的流程。 该服务器允许MCP客户端与Node-RED实例工作:标签页、节点、线路、组、子流和配置节点。它可以读取、编辑这些节点,并将结果部署到正在运行的实例中。 它通过管理API连接到Node-RED,或者直接读写flows.json文件。无论哪种方式,工具都能理解Node-RED格式。它们可以区分流节点和配置节点,沿着线路跨标签页,并像编辑器一样调整组框大小。 - 列出标签页、组、子流、孤儿节点和配置节点及其引用内容。按名称、类型或标签页搜索。从节点到节点追踪线路。- 创建、更新、重命名、复制和删除节点。启用和禁用它们。布线和拆线,插入一个线到现有线路中,或绕过线路以便流量绕过该线路。- 创建、填充、重新样式和删除组。创建、重命名、重新排序和删除标签页。

概述(AI 翻译)

Node-RED的MCP服务器。从MCP客户端读取、编辑并部署你的流程。

关于

该服务器允许MCP客户端与Node-RED实例工作:标签、节点, 线路、组、子流和配置节点。它可以读取、编辑它们,并且 将结果部署到正在运行的实例中。

它通过管理员API连接到Node-RED,或者读写 flows.json 文件直接发送。无论哪种情况,工具都能理解 Node-RED 格式化。它们可以区分流节点和配置节点,沿着线路走 标签页,以及像编辑器那样调整组框大小。

特色

  • 阅读。 列表标签页、组、子流、孤儿节点和配置节点 以及引用它们的内容。按名称、类型或标签搜索。描摹电线 从一个节点到另一个节点。
  • 编辑节点。 创建、更新、重命名、复制和删除节点。 启用和禁用它们。接线再拆线,插入一个到现有的 布线,或者绕过一个,让流量绕过它。
  • 编辑组和标签页。 创建、填充、重新样式和删除组。 创建、重命名、重排和删除标签页。导入和导出节点集合。
  • 布局。 在放置节点前请求一个空闲区域,这样你就不会有

本页由 AI 翻译,技术细节请以原文为准。

README

以下为原文 README 节选,完整内容请查看原文。

nodered-mcp

An MCP server for Node-RED. Read, edit, and deploy your flows from an MCP client.

About

This server lets an MCP client work with a Node-RED instance: tabs, nodes, wires, groups, subflows, and config nodes. It can read them, edit them, and deploy the result to the running instance.

It connects to Node-RED through the Admin API, or reads and writes a flows.json file directly. Either way, the tools understand the Node-RED format. They can tell a flow node from a config node, follow a wire across tabs, and size a group box the same way the editor does.

Features

  • Reading. List tabs, groups, subflows, orphaned nodes, and config nodes along with what references them. Search by name, type, or tab. Trace a wire from node to node.
  • Editing nodes. Create, update, rename, duplicate, and delete nodes. Enable and disable them. Wire and unwire them, insert one into an existing wire, or bypass one so traffic routes around it.
  • Editing groups and tabs. Create, populate, restyle, and delete groups. Create, rename, reorder, and delete tabs. Import and export sets of nodes.
  • Layout. Ask for a free region before placing nodes, so you do not have to guess coordinates. Check the canvas for overlapping nodes and groups, fix them, and repack a tab’s groups into columns.
  • Batching. Edits stay in memory until you save or deploy, so a build with many nodes lands as a single change. Use diff to see what will change, and undo to step back one call at a time.
  • Safety checks. A layout gate blocks any write that creates a new overlap. A staleness check blocks any write that would overwrite a deploy someone made from the browser while you were working.

Requirements

  • Python 3.11 or newer. The only dependency is fastmcp.
在 GitHub 查看完整 README

安装

uvx nodered-mcp
新手?先看 mcpskill.org 教程 →

配置

{ "mcpServers": { "nodered": { "type": "stdio", "command": "uvx", "args": ["nodered-mcp"], "env": { "NODERED_URL": "http://localhost:1880" } } } }