将 MCP Server 提交到 MCP Registry

前言

MCP Registry 是 MCP 官方提供的一个 提供 MCP Server 的平台,开发者可以将自己开发的 MCP Server 提交到 MCP Registry 以便其他用户可以方便的使用,MCP Registry 于 2025年 9月 8号推出了预览版,本文就讲述如何将自己开发的 MCP Server 提交到 MCP Registry。

提交 MCP Server

本文所使用的 MCP Server 是 qweather-mcp-go ,是一个使用 Node.js 开发的 MCP Server, 环境是 windows 11, 其他系统类似。

安装 Publisher CLI

要提交 MCP Server 需要使用安装使用 Publisher CLI

macOS/Linux/WSL 使用 Homebrew 安装:

bash 复制代码
brew install mcp-publisher

macOS/Linux/WSL 使用预编译的二进制文件安装:

bash 复制代码
# 下载最新版本的预编译二进制文件
curl -L "https://github.com/modelcontextprotocol/registry/releases/download/v1.0.0/mcp-publisher_1.0.0_$(uname -s | tr '[:upper:]' '[:lower:]')_$(uname -m | sed 's/x86_64/amd64/;s/aarch64/arm64/').tar.gz" | tar xz mcp-publisher && sudo mv mcp-publisher /usr/local/bin/

macOS/Linux/WSL 使用源码安装:

需要 Git、Make 和 Go 1.24 以上版本

bash 复制代码
# Clone the registry repository
git clone https://github.com/modelcontextprotocol/registry
cd registry
make publisher

# The binary will be at bin/mcp-publisher
export PATH=$PATH:$(pwd)/bin

Windows PowerShell 使用预编译的二进制文件安装:

powershell 复制代码
$arch = if ([System.Runtime.InteropServices.RuntimeInformation]::ProcessArchitecture -eq "Arm64") { "arm64" } else { "amd64" }; Invoke-WebRequest -Uri "https://github.com/modelcontextprotocol/registry/releases/download/v1.0.0/mcp-publisher_1.0.0_windows_$arch.tar.gz" -OutFile "mcp-publisher.tar.gz"; tar xf mcp-publisher.tar.gz mcp-publisher.exe; rm mcp-publisher.tar.gz

初始化及编辑 server.json

进入 qweather-mcp-go 项目目录,执行 mcp-publisher init 初始化 server.json 文件,初始的文件内容如下:

根据文档的要求编辑 server.json 和 package.json 文件。

验证

这里选择使用 Github 身份验证,执行 mcp-publisher login github,会打开浏览器,进行 oauth 验证。

除了使用 Github 验证,还可以使用 DNS 验证,具体可以参考文档。

发布

执行 mcp-publisher publish,会看到如下输出:

arduino 复制代码
Publishing to https://registry.modelcontextprotocol.io...
✓ Successfully published

怎么查看发布的 MCP Server 呢?可以访问使用以下命令:

lua 复制代码
curl https://registry.modelcontextprotocol.io/servers/io.github.overstarry/qweather-mcp

发现没有成功输出相关的 json 数据,通过查阅 issue, 发现是文档有误,可以使用以下命令:

arduino 复制代码
curl "https://registry.modelcontextprotocol.io/v0/servers?search=io.github.overstarry/qweather-mcp"

可以看到已经成功发布了。

小结

本文介绍了如何将自己开发的 MCP Server 提交到 MCP Registry, 通过使用 Publisher CLI 初始化、编辑、验证和发布,成功将 qweather-mcp-go 发布到了 MCP Registry 上,其他开发者可以方便的使用这个 MCP Server。

参考

相关推荐
小蠢驴打代码1 小时前
记忆库能通过测试,不等于回答值得信:Coding Agent Memory 的两层评估设计
github·ai编程
喂你一颗橘子糖1 小时前
我用 Codex 跑长任务:快照、Loop 和单线写入,解决三个失控问题
ai编程
李剑一2 小时前
瑞幸也AI上了?我用AI命令行帮我点了一杯咖啡,但是我花了不止一杯咖啡钱
aigc·openai·ai编程
leoZ2312 小时前
记忆系统与 Agent 定制完全指南(六):Agent 编排与调度
ai编程
Ai拆代码的曹操2 小时前
opencode CLI 源码拆解:yargs + effectCmd 双层架构如何管理 20+ 子命令
架构·ai编程·opencode·源码拆解
AINative软件工程3 小时前
LLM 应用的熔断降级工程实践:Circuit Breaker 不只是重试的升级版
后端·llm·ai编程
倔强的石头_11 小时前
不想每次都从头解释:我用 Doubao-Seed-Evolving 做了一个「稿件接力站」
ai编程
大模型码小白13 小时前
【Python零基础教程】继承、多态与魔法函数:面向对象编程三大核心特性详解
java·大数据·开发语言·人工智能·python·ai编程
-XWB-14 小时前
【LLM】Agent Planning 完全指南:8 种纯 LLM 范式 + 8 种混合规划模式详解(二)
人工智能·经验分享·aigc·学习方法·ai编程
沉默王二15 小时前
腾讯一面,我霸气反问:“你说你们在做Agent项目,说说 SubAgent、Plan 模式、Skill 调用这些你们都是怎么做的?”面试官一直在擦汗。。
面试·agent·ai编程