
NiFiMCP
io.github.nifimcp由 GitHub 账号 nifimcp 发布v0.1.0-rc.1更新于 Nov 6, 2026
Evidence-backed, read-only Apache NiFi investigation: cited evidence and reviewable flow drafts
概览
只读的 Apache NiFi 调查服务器:让助手描述流程、追踪溯源并起草可审阅的流程文件,并附引用证据。
- 可以做什么
- 描述指定范围内的 NiFi 流程、参数、服务与配置检查结果,并报告队列、公告和带标签假设的流程健康状况
- 追踪单个 FlowFile 的溯源时间线,检查未匹配路由的上游来源,并比较已注册的流程快照
- 将调查导出为 JSON 或自包含的 HTML 报告,包含证据记录与完整性哈希
- 查询固定版本的处理器目录,静态校验拟议子流程,并起草一个停止状态的本地流程定义及审阅页
- 通过命令行完成同样的工作(describe、investigate、report、draft、register、catalog),并使用三个内置提示词
- 适用场景
- 适合值班或平台团队让助手解释不熟悉的 NiFi 流程、排查积压队列或追踪单个 FlowFile,并把观察到的事实与假设区分开。也适合在隔离网络中审阅导出的流程定义,以及把路由子流程起草为本地文件。
- 运行要求
- 本地 Python 3.12 运行时;通过 uvx 或 pip 安装 PyPI 包 nifimcp-server(预发布版 0.1.0rc1,需固定版本)。实时模式需要操作员配置文件,以及一个仅具只读策略的专用 NiFi 客户端证书,通过 HTTPS 双向 TLS 连接 NiFi 2.12.0。演示与离线包模式无需 NiFi。
安装
在 SourceWeft 中
- 打开 控制台中的 NiFiMCP,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
NiFiMCP
Give AI the context to understand your NiFi flows, investigate failures with cited evidence, and draft what comes next.
Explore NiFiMCP · How it works · Bring us one critical NiFi workflow
NiFiMCP is an open-source Model Context Protocol server for evidence-backed Apache NiFi investigation. It reads; it does not change your NiFi.
Public preview 0.1.0rc1. Tested on Linux x86_64 with Python 3.12 against stock Apache NiFi 2.12.0 (single node, certificate authentication) and Claude Code. Live NiFi access is read-only; a flow draft is a local file that an authorized person imports separately. Anything outside that boundary is listed as untested or unsupported in the capability matrix. Expect rough edges and report them.
NiFiMCP is an independent project for Apache NiFi, founded and maintained by Lloyd Clark. It is not affiliated with, sponsored by or endorsed by the Apache Software Foundation or Cloudera. Apache NiFi and NiFi are trademarks of the Apache Software Foundation. Website: nifimcp.com.
1. Try NiFiMCP in one minute
The demo needs no NiFi, no model and no account. It replays evidence captured from a real NiFi 2.12.0 instance running a synthetic flow. With uv installed:
Open nifimcp-demo/report.html. Every statement in it links to the exact source bytes it came from.
[Investigation report produced by the demo]
2. Install
NiFiMCP needs Python 3.12. The package on PyPI is nifimcp-server and it installs the nifimcp command
(nifi-mcp is an unrelated project, and PyPI treats nifimcp as the same name). 0.1.0rc1 is a pre-release,
so pin the version:
or, with pip in a Python 3.12 virtual environment, pip install nifimcp-server==0.1.0rc1.
From source, for development or to run the test suites:
For machines without internet access, use the offline kit (hash-locked wheels, SBOM and licenses) from the GitHub release and follow docs/OFFLINE_INSTALL.md.
3. How it works
[NiFiMCP preview: understand scoped NiFi context, investigate with cited evidence, and propose reviewable flow drafts. Execute with approval is a roadmap goal, not a preview feature.]- Understand (preview): read scoped flows, configuration and live status through a read-only identity.
- Investigate (preview): follow evidence to a finding; unknowns stay explicit and every statement cites its source bytes.
- Propose (preview, experimental): generate a reviewable flow draft as local files; a person decides what to import, and the separate lab CLI can test it in a disposable NiFi first.
- Execute with approval (roadmap, not in this preview): no tool in this release changes NiFi.
4. Connect a scoped NiFi identity
NiFiMCP works in three modes:
For live mode, create a dedicated NiFi identity (a client certificate) and give it read-only access to the process groups you want the assistant to see, nothing more:
NiFi's "view the data" policy would also let this identity open FlowFile content in the NiFi UI. NiFiMCP has no route to content, attribute dumps or replay, and only allowlisted attribute values leave the server. Without that policy, describe and health still work, and provenance and sampling return a permission error that names the missing policy.
Never grant write policies. NiFiMCP has no tool that modifies NiFi, and the scoped identity is your second line of defense. Then write an operator config (docs/CONFIGURATION.md) and check it:
Add the server to your MCP host:
The recorded Claude Code sessions in evidence/host/ used the source-checkout form of the same command
(uv run --frozen --project /path/to/nifimcp nifimcp serve --config ...). Other MCP hosts that launch
stdio servers should work with the same command but have not been tested.
5. Five useful prompts
- "Explain the flow in scope
orders-intakefor an on-call operator who did not build it. Cite evidence and list unknowns." - "Events are piling up on connection
<id>. Investigate the last hour and separate observed facts, plausible explanations and missing evidence." - "Trace FlowFile
<uuid>through scopeorders-intakebetween 09:00 and 10:00 UTC. Where did it go and what can't you see?" - "Compare the flow definitions I registered as
beforeandafter. What changed in routing and queue settings?" - "Draft an attribute router that sends
status=criticaltoout_critical,standardtoout_standardand everything else toout_unmatched. Validate it and give me labeled test cases."
The server also ships three MCP prompts: explain_this_flow, investigate_this_feed and draft_bounded_routing_flow.
6. What it actually does
Every result uses one envelope: status, scope, source version, collection time, evidence records (source hash plus JSON pointer), findings labeled as observed, static rule, hypothesis or operator note, explicit gaps, and the limits that were applied.
A non-AI command line covers the same ground: nifimcp describe, investigate, report, draft,
register, unregister and catalog. Run nifimcp --help. For a sample subflow plan, run
nifimcp draft --example attribute_router > plan.json, then nifimcp draft --plan plan.json --output ./draft.
7. Three separate things: investigate, draft, execute
In the recorded Claude Code session the assistant drafted a router with draft_flow, which wrote files and
touched no NiFi. The import you see in evidence/host/*/lab-verification/ was done afterward by the lab
CLI with the lab admin certificate (CN=nifimcp-lab-admin) through NiFi's upload endpoint, into a scratch
group of a container that was then destroyed. The MCP server has no upload, start or deploy route, and the
observer identity holds no write policy. Execution against a real NiFi is not part of this release.
It is planned as a separate, approval-controlled component.
8. Boundaries
- Read-only. No start, stop, delete, upload or deploy tool exists. Drafts are local files and never touch NiFi.
- Scoped. Only configured process groups are visible; out-of-scope IDs are refused without revealing whether they exist. Clusters are refused.
- Bounded. Hard limits on time windows, events, components, depth, sample size, result size and run time.
- No content. FlowFile content is never read. Attribute values appear only when allowlisted. Sensitive values, secret-like literals and common credential shapes are masked (best-effort pattern matching).
- No hidden calls. No telemetry, no update checks, no embedded model. Only allowlisted NiFi REST endpoints.
- Honest about evidence. Current settings are never presented as the cause of a past event. Empty provenance results are not proof that data never existed. A SEND event is not proof of downstream receipt.
- Drafts are experimental. A draft passes static checks only. Runtime behavior is unknown until the separate lab CLI imports it into a disposable NiFi and runs labeled cases.
- Your model is yours. NiFiMCP itself runs without network access, but it embeds no model: the MCP host supplies the model and may send tool results to its provider. A fully offline AI setup has not been tested here.
NiFi names, messages and attributes are treated as untrusted text. Your MCP host's model still decides what to say; check its claims against the cited evidence.
9. Known limits of this preview
Three acceptance gates are BLOCKED, not passed, and they matter in practice:
Also untested: NiFi versions other than 2.12.0 (refused at preflight), bearer-token login against a real NiFi (unit tests only), MCP hosts other than Claude Code, and provenance searches by custom indexed attribute.
10. The evidence report
export_investigation (or nifimcp report) writes one HTML file with no scripts or external resources:
collections and intervals, a flow map, findings with their kind and limitations, the provenance timeline,
gaps, every evidence record and integrity hashes.
[Findings with evidence links]
11. How it was qualified
Tests run against a real, disposable NiFi 2.12.0 container (the official image, pinned by digest) with real TLS identities and policies. Mocks never count as an integration pass.
The acceptance ledger with commands, versions and results is in docs/ACCEPTANCE.md, and the release validation summary with checksums in docs/VALIDATION.md. The incident corpus measures the fixed rules, not any language model.
12. Contributing and roadmap
Bug reports, compatibility reports for other NiFi versions and new labeled incident cases are the most useful contributions. Start with the starter issues, CONTRIBUTING.md and SECURITY.md. The roadmap leads with safe read-only cluster support and external validation.
13. Engineering help
NiFiMCP stays free and open source. For teams running NiFi on restricted or air-gapped networks, or building their own NiFi expertise, the maintainer's company, Federal SI, offers three separately scoped services:
- Supported Air Gap Kit: deployment and configuration help around the free offline kit, validation in your environment, operating guidance and handover.
- Forward Deployed Engineering: practical deployment, integration and workflow assistance, remote or on site.
- Technical Exchange: hands-on knowledge transfer using representative workflows.
Services add people, not software features: the preview limits still apply, and a fully offline AI setup has not been tested. Discuss your environment.
Licensed under the Apache License 2.0. Third-party notices: NOTICE, ATTRIBUTION.md.
来源:README.md,提交 f978c84
工具
0版本历史
1- v0.1.0-rc.1最新Oct 30, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分