npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

mcp-message-pusher

v0.1.2

Published

MCP 服务器,用于通过 MessagePusher 推送消息给大模型工具调用。

Readme

mcp-message-pusher

基于 MessagePusher 的 MCP 服务器,封装了原有 demo.js 的消息推送逻辑,方便在 Claude Desktop、Cursor 等支持 Model Context Protocol 的客户端中被大模型直接调用。

功能特性

  • 提供 send_message_pusher 工具,按需向 MessagePusher 服务推送消息
  • 自动校验标题必填,其余字段可选
  • 保持与原始实现一致的错误处理:返回服务端原始响应,便于排查

安装与运行

npm install -g mcp-message-pusher
# 或者直接在项目中安装
npm install mcp-message-pusher

运行前请确保配置以下环境变量:

| 变量名 | 说明 | | --- | --- | | MESSAGE_PUSHER_SERVER | MessagePusher 服务根地址,例如 https://api.messagepusher.com | | MESSAGE_PUSHER_USERNAME | MessagePusher 用户名 | | MESSAGE_PUSHER_TOKEN | MessagePusher 推送令牌 | | MESSAGE_PUSHER_CHANNEL | 可选,固定推送通道,若设置则覆盖所有调用的 channel |

启动服务器(全局安装后):

MESSAGE_PUSHER_SERVER=... MESSAGE_PUSHER_USERNAME=... MESSAGE_PUSHER_TOKEN=... mcp-message-pusher

与 MCP 客户端集成示例

以 Claude Desktop 为例,在 claude_desktop_config.json 中添加:

{
  "mcpServers": {
    "message-pusher": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-message-pusher"
      ],
      "env": {
        "MESSAGE_PUSHER_SERVER": "https://your-server",
        "MESSAGE_PUSHER_USERNAME": "your-username",
        "MESSAGE_PUSHER_TOKEN": "your-token"
      }
    }
  }
}

随后在对话中授权使用工具即可。

开发说明

# 安装依赖
npm install --cache .npm-cache

# 开发模式(使用 tsx watch)
npm run dev

# 构建
npm run build

发布到 npm 时会自动执行 npm run prepublishOnly,确保 dist 目录为最新编译结果。

工具输入参数

titledescriptioncontent 至少填写其一。

| 字段 | 类型 | 说明 | | --- | --- | --- | | title | string? | 消息标题 | | description | string? | 消息摘要/描述,映射到 description/desp | | content | string? | 消息正文,支持 Markdown | | channel | string? | 指定推送通道名称;若配置了 MESSAGE_PUSHER_CHANNEL 环境变量,则以环境变量为准 | | token | string? | 覆盖环境变量的令牌,可支持通道级 token | | url | string? | 自定义跳转链接 | | to | string? | 推送目标,支持 @alluser1|user2 | | async | boolean? | 是否异步推送,true 时响应包含 uuid | | render_mode | "markdown" \| "code" \| "raw"? | 渲染模式,默认 markdown |

调用成功与否均会返回 MessagePusher 原始 JSON 响应,便于模型解析或转述。若服务不可达或发生网络错误,将抛出异常,由 MCP 客户端负责展示。