原型 · 预览版:收录官方注册中心里的全部服务器,每 30 分钟同步一次。使用 Google 登录即可撰写评价。原型 · 每 30 分钟更新
PopNx MCP为使用 AI 的人准备的 MCP 服务器 · 用大白话讲清楚

SafeNode MCP Gateway

作者:sp3ak版本 0.1.2i★ 0i在你的电脑上运行官方网站 ↗
注册名称io.github.sp3ak/safenode-mcp-gateway

安装方法

What it does

Policy proxy for MCP tool calls. A denied call never reaches the downstream server.

  • Connects 在你的电脑上运行
  • Account or key Needs SAFENODE_API_KEY
  • Category 其他

为什么排在这里

列表按使用分(满分 100)排序,由以下部分组成

热度0/80GitHub 星标或每周下载量:较大的计 60,较小的计 20
新鲜度7/1230 天内有发布或代码更新得满分
仍在响应0/8上次检查时云端端点有响应
使用分7/100

质量: 基础检查通过 3/3 项(仅展示,不用于排序) · 上升势头: 暂无数据 (只用于“上升中”标签)

安装

选择你使用的 AI 应用,然后复制设置。

用一句话让 AI 帮你安装

请帮我安装 SafeNode MCP Gateway。按照 https://mcp.popnx.com/i/sp3ak-safenode-mcp-gateway.md 操作,先把命令给我看,等我同意后再运行。

粘贴到能在你电脑上工作的 AI(如 Claude Code、Cursor)。它会读取我们的步骤,先给你看命令,等你同意。无需密钥,无需注册。 · 查看 AI 会读取的全文

通过 3/3 项检查 · 在你的电脑上运行 · ✓ 命令已检查 2026年11月14日

第一步:你用哪个 AI?

选择你用的应用,步骤会显示在下方。

可连接 Claude,但需要先准备

需要 SafeNode MCP Gateway 的密钥(在开发者网站创建) · 需要先在电脑上安装 Node.js(只需一次) · 仅限电脑上的 Claude 应用(Windows 或 Mac),网页和手机不可用

让 AI 帮你安装

把这段话复制到 Claude 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。

请在这台电脑上为 Claude 安装 MCP server SafeNode MCP Gateway,按顺序:1) 用 node -v 检查是否有 Node.js。没有的话,请让我从 https://nodejs.org/en/download 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "mcpServers": { "safenode-gateway": { "command": "npx", "args": [ "-y", "safenode-mcp-gateway" ], "env": { "SAFENODE_API_KEY": "your-value" } } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) SAFENODE_API_KEY 先保留 "your-value",请我自己把真实值粘贴到文件或应用的输入框里。不要让我在对话里输入密钥。5) 按约定执行,然后确认 SafeNode MCP Gateway 的工具真的出现了。

这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。

  1. 安装 Node.js(如果还没有)

    已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter

    node -v
    • 显示版本号(例如 v26.13.1)= 已安装,可跳过这一步
    • 显示 "command not found"(Windows 显示 "is not recognized")= 还没安装,或刚装好但需要关掉终端再重新打开
    怎么打开终端

    Mac:按 ⌘ + Space,输入 Terminal 后按 Enter

    Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”

    还没安装: 打开官方下载页,选择 LTS 版本和点选式安装程序:Mac 用 .pkg · Windows 用 .msi。双击后一路下一步即可,不需要 curl 命令

    打开 Node.js 下载页 ↗

    装好后关掉终端再打开,重新运行同一条命令,应显示版本号: node -v

    安装一次,所有需要 Node.js 的工具都能用

  2. 注册并创建 SafeNode MCP Gateway 的密钥

    打开开发者网站,注册账户并创建 API 密钥,下一步要用。价格和免费方案请看开发者网站。

    打开 SafeNode MCP Gateway 网站 ↗

  3. 打开电脑版 Claude 应用的设置文件

    SettingsDeveloperEdit Config

  4. 粘贴这些设置并保存文件

    {
      "mcpServers": {
        "safenode-gateway": {
          "command": "npx",
          "args": [
            "-y",
            "safenode-mcp-gateway"
          ],
          "env": {
            "SAFENODE_API_KEY": "your-value"
          }
        }
      }
    }

    只把密钥粘贴到应用的输入框里,不要粘贴到聊天中或发给任何人

  5. 退出 Claude 再重新打开

  6. 试一试

    用 SafeNode MCP Gateway 告诉我你能帮我做什么,然后做一件给我看

    ✓ 如果 Claude 说正在使用 SafeNode MCP Gateway,或回答中出现 SafeNode MCP Gateway 的工具名称,就表示连接成功

1 项可选设置(不填也能用)

上面的命令不填这些也能用。想调整时再按开发者的说明添加。

  • SAFENODE_BASE_URL Override the SafeNode API base URL. Defaults to https://safenode.tech.

说明仍为英文原文。

菜单名称已于 2026年11月11日 对照 Anthropic 帮助页面核实 · 你的界面可能因版本略有不同

ChatGPT 暂时无法连接 SafeNode MCP Gateway

SafeNode MCP Gateway 需要安装在你的电脑上,而 ChatGPT 只能连接在网上运行的服务器

你可以改用这些方式

A · 使用能连接 SafeNode MCP Gateway 的应用

  • 需要 SafeNode MCP Gateway 的密钥(在开发者网站创建) · 需要先在电脑上安装 Node.js(只需一次) · 仅限电脑上的 Claude 应用(Windows 或 Mac),网页和手机不可用
  • 需要 SafeNode MCP Gateway 的密钥(在开发者网站创建) · 需要先在电脑上安装 Node.js(只需一次)
  • 需要 SafeNode MCP Gateway 的密钥(在开发者网站创建) · 需要先在电脑上安装 Node.js(只需一次)
  • 需要 SafeNode MCP Gateway 的密钥(在开发者网站创建) · 需要先在电脑上安装 Node.js(只需一次)

B · 其他 类中能连接 ChatGPT 的其他服务器

从同类中使用较多的里挑选,仅限用地址即可连接、无需密钥的

可连接 Claude Code,但需要先准备

需要 SafeNode MCP Gateway 的密钥(在开发者网站创建) · 需要先在电脑上安装 Node.js(只需一次)

让 AI 帮你安装

把这段话复制到 Claude Code 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。

请在这台电脑上为 Claude Code 安装 MCP server SafeNode MCP Gateway,按顺序:1) 用 node -v 检查是否有 Node.js。没有的话,请让我从 https://nodejs.org/en/download 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):claude mcp add --scope user safenode-gateway --env SAFENODE_API_KEY=your-value -- npx -y safenode-mcp-gateway 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) SAFENODE_API_KEY 先保留 "your-value",请我自己把真实值粘贴到文件或应用的输入框里。不要让我在对话里输入密钥。5) 按约定执行,然后确认 SafeNode MCP Gateway 的工具真的出现了。

这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。

  1. 安装 Node.js(如果还没有)

    已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter

    node -v
    • 显示版本号(例如 v26.13.1)= 已安装,可跳过这一步
    • 显示 "command not found"(Windows 显示 "is not recognized")= 还没安装,或刚装好但需要关掉终端再重新打开
    怎么打开终端

    Mac:按 ⌘ + Space,输入 Terminal 后按 Enter

    Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”

    还没安装: 打开官方下载页,选择 LTS 版本和点选式安装程序:Mac 用 .pkg · Windows 用 .msi。双击后一路下一步即可,不需要 curl 命令

    打开 Node.js 下载页 ↗

    装好后关掉终端再打开,重新运行同一条命令,应显示版本号: node -v

    安装一次,所有需要 Node.js 的工具都能用

  2. 注册并创建 SafeNode MCP Gateway 的密钥

    打开开发者网站,注册账户并创建 API 密钥,下一步要用。价格和免费方案请看开发者网站。

    打开 SafeNode MCP Gateway 网站 ↗

  3. 打开终端

    Mac:按 Command+空格,输入 Terminal · Windows:打开 PowerShell

  4. 粘贴这条命令并按 Enter

    claude mcp add --scope user safenode-gateway --env SAFENODE_API_KEY=your-value -- npx -y safenode-mcp-gateway

    按 Enter 前,把“your-value”改成你的密钥

    只把密钥粘贴到应用的输入框里,不要粘贴到聊天中或发给任何人

  5. 在 Claude Code 中输入 /mcp

    应能看到 SafeNode MCP Gateway 在列表中并显示已连接

  6. 试一试

    用 SafeNode MCP Gateway 告诉我你能帮我做什么,然后做一件给我看

    ✓ 如果 Claude Code 说正在使用 SafeNode MCP Gateway,或回答中出现 SafeNode MCP Gateway 的工具名称,就表示连接成功

1 项可选设置(不填也能用)

上面的命令不填这些也能用。想调整时再按开发者的说明添加。

  • SAFENODE_BASE_URL Override the SafeNode API base URL. Defaults to https://safenode.tech.

说明仍为英文原文。

菜单名称已于 2026年11月11日 对照 Anthropic 帮助页面核实 · 你的界面可能因版本略有不同

可连接 Cursor,但需要先准备

需要 SafeNode MCP Gateway 的密钥(在开发者网站创建) · 需要先在电脑上安装 Node.js(只需一次)

让 AI 帮你安装

把这段话复制到 Cursor 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。

请在这台电脑上为 Cursor 安装 MCP server SafeNode MCP Gateway,按顺序:1) 用 node -v 检查是否有 Node.js。没有的话,请让我从 https://nodejs.org/en/download 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "mcpServers": { "safenode-gateway": { "command": "npx", "args": [ "-y", "safenode-mcp-gateway" ], "env": { "SAFENODE_API_KEY": "your-value" } } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) SAFENODE_API_KEY 先保留 "your-value",请我自己把真实值粘贴到文件或应用的输入框里。不要让我在对话里输入密钥。5) 按约定执行,然后确认 SafeNode MCP Gateway 的工具真的出现了。

这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。

  1. 安装 Node.js(如果还没有)

    已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter

    node -v
    • 显示版本号(例如 v26.13.1)= 已安装,可跳过这一步
    • 显示 "command not found"(Windows 显示 "is not recognized")= 还没安装,或刚装好但需要关掉终端再重新打开
    怎么打开终端

    Mac:按 ⌘ + Space,输入 Terminal 后按 Enter

    Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”

    还没安装: 打开官方下载页,选择 LTS 版本和点选式安装程序:Mac 用 .pkg · Windows 用 .msi。双击后一路下一步即可,不需要 curl 命令

    打开 Node.js 下载页 ↗

    装好后关掉终端再打开,重新运行同一条命令,应显示版本号: node -v

    安装一次,所有需要 Node.js 的工具都能用

  2. 注册并创建 SafeNode MCP Gateway 的密钥

    打开开发者网站,注册账户并创建 API 密钥,下一步要用。价格和免费方案请看开发者网站。

    打开 SafeNode MCP Gateway 网站 ↗

  3. 点击这个按钮打开 Cursor

    在 Cursor 中打开

    Cursor 会请你确认安装,点击 Install

  4. 填写你的密钥

    在 SafeNode MCP Gateway 的设置中,SAFENODE_API_KEY 还是空的,填入你的密钥并保存

    只把密钥粘贴到应用的输入框里,不要粘贴到聊天中或发给任何人

  5. 在 Cursor 中以 Agent 模式打开 AI 聊天

  6. 试一试

    用 SafeNode MCP Gateway 告诉我你能帮我做什么,然后做一件给我看

    ✓ 如果 Cursor 说正在使用 SafeNode MCP Gateway,或回答中出现 SafeNode MCP Gateway 的工具名称,就表示连接成功

1 项可选设置(不填也能用)

上面的命令不填这些也能用。想调整时再按开发者的说明添加。

  • SAFENODE_BASE_URL Override the SafeNode API base URL. Defaults to https://safenode.tech.

说明仍为英文原文。

菜单名称已于 2026年11月11日 对照 Cursor 帮助页面核实 · 你的界面可能因版本略有不同

可连接 VS Code,但需要先准备

需要 SafeNode MCP Gateway 的密钥(在开发者网站创建) · 需要先在电脑上安装 Node.js(只需一次)

让 AI 帮你安装

把这段话复制到 VS Code 的对话里。AI 会先检查电脑,告诉你要改哪个文件,并且每次都等你同意。

请在这台电脑上为 VS Code 安装 MCP server SafeNode MCP Gateway,按顺序:1) 用 node -v 检查是否有 Node.js。没有的话,请让我从 https://nodejs.org/en/download 安装,不要自己安装。2) 只使用这份配置(已通过 PopNx MCP 检查):{ "servers": { "safenode-gateway": { "type": "stdio", "command": "npx", "args": [ "-y", "safenode-mcp-gateway" ], "env": { "SAFENODE_API_KEY": "your-value" } } } } 3) 告诉我要修改的文件完整路径或要运行的命令,等我同意。4) SAFENODE_API_KEY 先保留 "your-value",请我自己把真实值粘贴到文件或应用的输入框里。不要让我在对话里输入密钥。5) 按约定执行,然后确认 SafeNode MCP Gateway 的工具真的出现了。

这段话不包含你的密钥。如果需要密钥,AI 会请你自己粘贴到文件或应用的输入框里。

  1. 安装 Node.js(如果还没有)

    已经装好了吗?先检查 · 打开终端,输入这条命令后按 Enter

    node -v
    • 显示版本号(例如 v26.13.1)= 已安装,可跳过这一步
    • 显示 "command not found"(Windows 显示 "is not recognized")= 还没安装,或刚装好但需要关掉终端再重新打开
    怎么打开终端

    Mac:按 ⌘ + Space,输入 Terminal 后按 Enter

    Windows:打开“开始”菜单,输入 Windows PowerShell,然后选“打开”

    还没安装: 打开官方下载页,选择 LTS 版本和点选式安装程序:Mac 用 .pkg · Windows 用 .msi。双击后一路下一步即可,不需要 curl 命令

    打开 Node.js 下载页 ↗

    装好后关掉终端再打开,重新运行同一条命令,应显示版本号: node -v

    安装一次,所有需要 Node.js 的工具都能用

  2. 注册并创建 SafeNode MCP Gateway 的密钥

    打开开发者网站,注册账户并创建 API 密钥,下一步要用。价格和免费方案请看开发者网站。

    打开 SafeNode MCP Gateway 网站 ↗

  3. 点击这个按钮打开 VS Code

    在 VS Code 中打开

    VS Code 会请你确认安装,点击 Install

  4. 填写你的密钥

    在 SafeNode MCP Gateway 的设置中,SAFENODE_API_KEY 还是空的,填入你的密钥并保存

    只把密钥粘贴到应用的输入框里,不要粘贴到聊天中或发给任何人

  5. 在 VS Code 中以 Agent 模式打开 AI 聊天

  6. 试一试

    用 SafeNode MCP Gateway 告诉我你能帮我做什么,然后做一件给我看

    ✓ 如果 VS Code 说正在使用 SafeNode MCP Gateway,或回答中出现 SafeNode MCP Gateway 的工具名称,就表示连接成功

1 项可选设置(不填也能用)

上面的命令不填这些也能用。想调整时再按开发者的说明添加。

  • SAFENODE_BASE_URL Override the SafeNode API base URL. Defaults to https://safenode.tech.

说明仍为英文原文。

菜单名称已于 2026年11月11日 对照 VS Code 帮助页面核实 · 你的界面可能因版本略有不同

其他支持 MCP 的应用(如 Windsurf、Zed、Gemini CLI)添加方式各不相同,请在应用列表中查看

查看所有支持 MCP 的应用 →

JSON 设置在下方“开发者专用”中

卡住了?问问正在用 SafeNode MCP Gateway 的人💬 讨论 →
开发者专用:终端命令和 JSON 设置

安装在电脑上

Claude Code

claude mcp add --scope user safenode-gateway --env SAFENODE_API_KEY=your-value -- npx -y safenode-mcp-gateway

Claude Desktop (claude_desktop_config.json)

{
  "mcpServers": {
    "safenode-gateway": {
      "command": "npx",
      "args": [
        "-y",
        "safenode-mcp-gateway"
      ],
      "env": {
        "SAFENODE_API_KEY": "your-value"
      }
    }
  }
}

Cursor (~/.cursor/mcp.json)

{
  "mcpServers": {
    "safenode-gateway": {
      "command": "npx",
      "args": [
        "-y",
        "safenode-mcp-gateway"
      ],
      "env": {
        "SAFENODE_API_KEY": "your-value"
      }
    }
  }
}

VS Code (mcp.json)

{
  "servers": {
    "safenode-gateway": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "safenode-mcp-gateway"
      ],
      "env": {
        "SAFENODE_API_KEY": "your-value"
      }
    }
  }
}

需要你填写的值

  • SAFENODE_API_KEY 机密 必填 env
    SafeNode API key. Free tier at https://safenode.tech — no card required.
  • SAFENODE_BASE_URL env
    Override the SafeNode API base URL. Defaults to https://safenode.tech.

说明仍为英文原文。

这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。

一览

每周下载量i
59/周
连接方式
在你的电脑上运行
最新版本i
0.1.2
分类i
其他
发布到注册中心i
2026年8月10日
代码最后更新i
2026年10月18日
作者
sp3ak
软件包
npm: safenode-mcp-gateway
注册状态
活跃

哪些应用可以使用它

依据这个服务器的连接方式和各应用自己的文档,检查于 2026年11月10日。

在你的电脑上运行,适用于

ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast

全部应用及其优缺点 →

它能做什么

它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。

基础检查i

我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月19日

  • ✓ 通过

    作者与仓库一致

    注册名称已通过 GitHub 账户 sp3ak 验证,该账户拥有此仓库

  • ✓ 通过

    仍在维护

    代码最后更新于32天前

  • ✓ 通过

    有许可证

    使用 MIT

  • – 不适用

    端点有响应

    它在你的电脑上运行,没有互联网端点

  • – 不适用

    使用 OAuth 登录

    在你的电脑上运行,改用本地设置

  • … 尚未检查

    工具描述中没有隐藏指令

    它在你的电脑上运行;我们只能读取互联网端点的工具列表

已公开的漏洞(OSV.dev)

OSV.dev 中没有 safenode-mcp-gateway@0.1.2 的记录

只检查这个版本的包本身,不包括所有依赖 · 检查于 2026年11月16日

我们检查什么 → · JSON

作者:申请重新检查或报告信息错误
给作者:在 README 中加徽章

如果你是作者,可把这段代码贴到 README。徽章会链接回本页。

[![Featured on PopNx MCP](https://mcp.popnx.com/badge/sp3ak-safenode-mcp-gateway.svg)](https://mcp.popnx.com/en/servers/sp3ak-safenode-mcp-gateway)

讨论

提问、分享技巧或报告无法使用。按“有帮助”数量排序。

还没有帖子,欢迎第一个提问或分享。

此处内容由用户撰写,不代表 PopNx 团队。

登录后发帖

用户评价

还没有评价

登录后写评价

与“其他”中的其他服务器比较i

  • 星标数多于此分类中其他 20653 个服务器的 0%
  • 发布到注册中心的时间比此分类中其他 20653 个服务器的 16% 更新
  • 基础检查结果等于或优于此分类中其他 20653 个服务器的 99%

与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。

常见问题

SafeNode MCP Gateway 安全吗?

它在 3 项适用的基础检查中通过了 3 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。

它需要哪些密钥或代码?

你需要填写:SAFENODE_API_KEY

它在我的电脑上运行还是在云端?

它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。

它还在维护吗?

GitHub 仓库最后更新于32天前,最新版本(0.1.2)于3个月前进入注册中心。

哪些应用可以使用它?

支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Node.js。

有什么可以替代它?

同一分类中有:World Monitor, openstatus, Oh My Posh Validator, Strata, Jitsu

功能相近的其他选择

同一分类、其他作者、命令已通过检查。官方的排在前面,再按星标排序。

如何看卡片:↓ 每周下载量i★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i

World Monitor

Real-time global intelligence on conflict, markets, energy, trade, shipping and cyber. 100 tools.

作者:koala73广泛使用★ 9.1万3天前更新

在云端运行✓ 服务方 · worldmonitor.app

openstatus

Manage monitors, status pages, incidents and maintenances in your openstatus workspace.

作者:openstatusHQ广泛使用★ 92742个月前更新

在云端运行✓ 服务方 · openstatus.dev

Strata

MCP server for progressive tool usage at any scale (see https://klavis.ai)

作者:Klavis-AI正在增长★ 582514个月前更新

在云端运行仓库已归档✓ klavis.ai

Jitsu

Manage Jitsu data pipelines: destinations, streams, connections, functions, live events.

作者:jitsucom广泛使用★ 51364个月前更新

在云端运行✓ 服务方 · jitsu.com
与相似项目对比
本项
SafeNode MCP Gateway
World MonitoropenstatusOh My Posh ValidatorStrataJitsu
运行位置需要安装在电脑上在云端运行,无需安装在云端运行,无需安装在云端运行,无需安装在云端运行,无需安装在云端运行,无需安装
需要密钥是否否否否否
可在 Claude 中按 + 添加否否否否否否
基础检查3/34/44/44/41/44/4
许可证MITAGPL-3.0AGPL-3.0MITApache-2.0MIT
价格登记中未列出费用登记中未列出费用登记中未列出费用登记中未列出费用登记中未列出费用登记中未列出费用

作者的 README

打开 README

按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。

SafeNode MCP Gateway

An MCP proxy that enforces policy on every tool call. The agent cannot route around it.

npx safenode-mcp-gateway

Why a proxy

An MCP server that exposes an evaluate_action tool is theatre. The model can choose not to call it, which means it enforces nothing.

This is a proxy. It sits between your MCP client (Claude Desktop, Claude Code, Cursor, any MCP host) and the MCP servers you already use. tools/list passes straight through, so the model sees exactly the tools it saw before. Every tools/call is evaluated against SafeNode *first*. A denial means the call never reaches the downstream server at all.

Claude Desktop ──► safenode-mcp-gateway ──► filesystem server

│ github server ▼ postgres server SafeNode API allow/warn/review/deny

Your agent needs no code changes. It does not know the gateway is there.

Get an API key — free tier, no card · Docs · Python SDK


Setup

1. Get an API key

Free at safenode.tech. Keys look like sn_....

2. Write a config

safenode-gateway.json — take the servers straight out of your existing MCP client config:

{

"failMode": "fail_closed", "payloadMode": "redacted", "logFile": "./safenode-decisions.jsonl", "servers": [ { "name": "filesystem", "command": "npx", "args": ["-y", "@modelcontextprotocol/server-filesystem", "/Users/you/projects"] } ], "tools": { "read_file": { "failMode": "fail_open" }, "write_file": { "payloadMode": "metadata_only" } } }

Do not put your API key in this file. Set SAFENODE_API_KEY in the environment — it takes precedence over the config, so the file stays safe to commit.

3. See what would be sent, before sending anything
SAFENODE_API_KEY=sn_... npx safenode-mcp-gateway --dry-run

Prints the exact JSON body that an evaluation would POST. No network call. This is the fastest way to satisfy yourself about what leaves your machine.

4. Point your MCP client at the gateway

Claude Desktop — claude_desktop_config.json:

{

"mcpServers": { "safenode": { "command": "npx", "args": ["-y", "safenode-mcp-gateway", "--config", "/absolute/path/to/safenode-gateway.json"], "env": { "SAFENODE_API_KEY": "sn_..." } } } }

Claude Code — .mcp.json in your project:

{

"mcpServers": { "safenode": { "command": "npx", "args": ["-y", "safenode-mcp-gateway", "--config", "./safenode-gateway.json"], "env": { "SAFENODE_API_KEY": "sn_..." } } } }

Cursor — ~/.cursor/mcp.json, same shape as Claude Desktop.

Replace your existing server entries with this one. The gateway spawns them itself, so listing them in both places would run each server twice.


What each decision does

DecisionBehaviour
allowForwarded. The downstream result is returned unchanged.
warnForwarded, with a [SafeNode warning] line prepended so the model *and* the human see it.
reviewNot forwarded. Returns a message saying approval is needed.
denyNot forwarded. Returns the human-readable reasons and the trace_id.

Denials come back as MCP tool *errors*, not transport failures, so the model sees why and can try something else instead of the host surfacing an opaque crash.

Fail behaviour

failMode decides what happens when SafeNode itself is unreachable.

fail_closed (default)Block the call.
fail_openForward it, unevaluated.
raiseCrash the gateway.

The gateway defaults to `fail_closed`, unlike the SafeNode SDKs, which default to `fail_open`. That difference is deliberate. An SDK wraps a developer's own code, where taking production down during a SafeNode outage loses the user forever. The gateway fronts arbitrary MCP tools it knows nothing about — filesystem writes, shell commands, payments — and silently letting all of that through the moment SafeNode is unreachable defeats the point of installing it.

Loosen it per tool for the read-only ones:

"tools": {

"read_file": { "failMode": "fail_open" }, "list_files": { "failMode": "fail_open" } }

Degraded decisions are logged to stderr and marked "degraded": true with a null traceId in the decision log, so they can never be counted as real policy decisions.

What data leaves your machine

For every tool call, the gateway sends: the tool name, the downstream server name, a session id, any static context from your config, and the tool arguments as the payload.

payloadMode controls the arguments:

fullSent verbatim.
redacted (default)Scrubbed client-side first.
metadata_onlyNo values at all — key names and hashes only.

Redaction covers emails, Luhn-validated credit cards, US SSNs, provider API key prefixes (sk-, ghp_, xoxb-, AKIA, AIza), bearer tokens, and PEM private key blocks. Values become [REDACTED: ].

Why redaction counts are always sent

Alongside the redacted payload, the gateway sends counts of what it removed:

"safenode_redactions": { "email": 2, "credit_card": 1 }

This is load-bearing. SafeNode's server-side sensitive_data rule matches patterns against payload *values*. If the gateway scrubbed those values and said nothing, a policy of "deny any action containing a card number" would silently start passing — the client-side privacy feature would have disabled the server-side security control. Reporting counts closes that: policy can act on the *presence* of a card number without ever receiving one.

If you use sensitive_data with patterns, pair it with a redaction_metadata rule.

These counts are self-reported. They raise the floor for an honest client; they are not a defence against a hostile one.

No telemetry

The gateway talks to exactly two things: the downstream MCP servers you configured, and the SafeNode API. No analytics, no phone-home, no postinstall scripts.

Local decision log

Set logFile to get a JSONL record of every decision, independent of the server-side audit trail — so you still have evidence of what your agent tried to do when the network was down:

{"timestamp":"2026-08-08T04:12:09.412Z","server":"filesystem","tool":"write_file","decision":"deny","degraded":false,"traceId":"9f1c…","reasons":["Path is outside the approved workspace."],"forwarded":false,"durationMs":143,"sessionId":"a3f1…"}

Configuration reference

KeyDefaultMeaning
apiKey—Prefer SAFENODE_API_KEY in the environment
baseUrlhttps://safenode.techFor staging
failModefail_closedfail_closed \fail_open \raise
payloadModeredactedfull \redacted \metadata_only
timeoutMs5000Evaluation request budget
logFilenullJSONL decision log path
prefixToolsfalseForce __ naming
servers[]requiredDownstream MCP servers
tools{}{}Per-tool overrides
context{}{}Static context on every evaluation

failMode, payloadMode and context can be set globally, per server, or per tool. Most specific wins.

tools. .bypass: true skips evaluation entirely for one tool. It does what it says — the call is forwarded with no policy check at all.

Tool name collisions

If two downstream servers export the same tool name, the gateway prefixes every tool with __ and logs a warning. Silently picking a winner would apply one server's policy to another server's tool, which is a security bug rather than a cosmetic one.

What this is not

  • Not a sandbox. It decides whether a call is forwarded. It does not contain the downstream server, restrict syscalls, or limit what that server can do once the call reaches it.
  • Not a prompt-injection detector. It evaluates the *action*, not the reasoning that produced it. If your agent has been talked into deleting a table, this can stop the delete — it will not tell you the agent was manipulated.
  • Not offline. Every tool call costs a round trip to the SafeNode API. There is no local policy evaluation.
  • Not a substitute for scoping the underlying servers. Still pass a filesystem server the narrowest root directory that works.
  • Not free of side effects. Every evaluation is recorded server-side and counts against your monthly quota.

Latency

Each gated tool call adds one round trip to the SafeNode API, with a 5000ms budget by default. Bypassed tools add nothing.

A measured p99 for the evaluate endpoint is not published yet, because it has not been measured under realistic load. When it has been, it will go here and in the docs rather than being estimated.

Docker

docker build -t safenode-mcp-gateway .

Running it with no arguments starts against a bundled demo config that proxies an included echo server, so you can see the proxy work without any setup:

docker run -i --rm safenode-mcp-gateway

The demo key is a placeholder, so tools/list passes through while any real tool call is denied by the fail_closed policy. For real use, mount your own config and supply a key:

docker run -i --rm \

-e SAFENODE_API_KEY=sn_... \ -v /path/to/safenode-gateway.json:/app/config.json \ safenode-mcp-gateway --config /app/config.json

-i is required. MCP speaks JSON-RPC over stdio, so without stdin attached the gateway has nothing to talk to.

Agent skill

SKILL.md teaches an agent to set the gateway up for you, moving your existing servers behind it, and how to behave when a call is blocked or held for review. Copy it into a folder in your agent's skills directory (for Claude Code, ~/.claude/skills/safenode-mcp-gateway/). The policy-authoring companion is in skill/safenode-policies/.

Requirements

Node 18+. One runtime dependency: @modelcontextprotocol/sdk.

Contributing

See CONTRIBUTING.md. Bug reports about enforcement gaps — anything that reaches a downstream server when it should have been blocked — are the most valuable thing you can file.

Security

See SECURITY.md. Please do not open public issues for vulnerabilities.

License

MIT. See LICENSE.