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

lusun-collect-mcpserver

v1.0.0

Published

芦笋收款 MCP Server —— 让 AI 助手通过 [Model Context Protocol](https://modelcontextprotocol.io) 直接创建和管理收款订单。

Readme

lusun-collect-mcpserver

芦笋收款 MCP Server —— 让 AI 助手通过 Model Context Protocol 直接创建和管理收款订单。

功能

  • 无需手动配置 Token,启动时自动申请匿名 Token
  • 创建银行转账收款订单,获取收款账号信息
  • 查询订单列表(支持分页、状态过滤)
  • 查询单个订单详情及转账核验状态
  • 检查 Token 是否已绑定到芦笋账号
  • 内置 Prompt 模板,开箱即用

一键安装

For Agents(推荐)

无需 clone 仓库,直接用 npx 运行,适合在 MCP 客户端配置中使用:

{
  "mcpServers": {
    "lusun-collect": {
      "command": "npx",
      "args": ["-y", "lusun-collect-mcpserver"]
    }
  }
}

复制上方配置粘贴到你的 MCP 客户端配置文件即可,首次运行会自动下载并申请匿名 Token,无需任何手动配置。


快速开始

前置要求

  • Node.js >= 18
  • pnpm

安装与构建

git clone https://github.com/yuanze-dev/lusun-collect-mcpserver.git
cd lusun-collect-mcpserver
pnpm install
pnpm run build

接入 Claude Desktop

编辑 Claude Desktop 配置文件:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json
{
  "mcpServers": {
    "lusun-collect": {
      "command": "node",
      "args": ["/绝对路径/lusun-collect-mcpserver/build/index.js"]
    }
  }
}

重启 Claude Desktop 后即可使用。

接入其他 MCP 客户端

服务使用标准 stdio 传输,任何支持 MCP 的客户端均可通过以下命令启动:

node /path/to/lusun-collect-mcpserver/build/index.js

配置

服务启动时自动处理 Token,无需手动配置。Token 优先级如下:

| 优先级 | 来源 | 说明 | |--------|------|------| | 1 | 环境变量 LUSUN_MCP_TOKEN | 手动指定 Token | | 2 | ~/.config/lusun-mcp/config.json | 本地缓存 | | 3 | 自动创建 | 首次启动时调用 API 申请匿名 Token |

匿名 Token 在任意设备上均可使用,但订单数据无法与账号关联,也无法提现。如需提现,请前往 collect.lusun.com 完成账号绑定。

可选环境变量

| 变量名 | 默认值 | 说明 | |--------|--------|------| | LUSUN_MCP_TOKEN | — | 手动指定 MCP Token | | LUSUN_API_BASE_URL | https://api.lusun.com | API 基础地址 | | LUSUN_COLLECT_BASE_URL | https://collect.lusun.com | 收款页面基础地址 |

Tools

| 工具名 | 说明 | 参数 | |--------|------|------| | setupToken | 初始化或重置 MCP Token | 无 | | createOrder | 创建收款订单,返回收款账户信息和订单号 | title(必填)、amount(必填,元)、description(可选) | | checkBinding | 检查 Token 是否已绑定到账号 | 无 | | getOrderList | 查询订单列表 | offset(默认 0)、limit(默认 20,最大 100)、stat(0=未支付, 1=已支付, 3=已过期) | | getPublicOrder | 查询单个订单的公开信息及转账核验状态 | order_id(必填) |

Prompts

内置以下 Prompt 模板,可直接在 MCP 客户端中调用:

| Prompt 名 | 说明 | 参数 | |-----------|------|------| | lusun-assistant | 自然语言收款助手,自动选择工具完成操作 | request(自然语言描述需求) | | collect-payment | 发起一次收款,引导 Agent 完整执行创建流程 | titleamountdescription(可选) | | check-order | 查询指定订单状态,确认是否到账 | order_id | | list-orders | 汇总展示最近订单,适合对账场景 | stat(all/unpaid/paid/expired)、limit(默认 10) |

示例(使用 lusun-assistant):

帮我收 500 元餐费

查一下最近已支付的订单

开发

# 安装依赖
pnpm install

# 构建
pnpm run build

# 运行测试
pnpm test

项目结构:

src/
  index.ts          # 服务入口
  lib/
    api.ts          # HTTP 请求封装
    token.ts        # Token 管理
    url.ts          # URL 构建
    errors.ts       # 错误码映射
  tools/            # MCP Tools
  prompts/          # MCP Prompts

License

MIT