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

yhh-mcp-server

v2.0.0

Published

御华浩 B2B 机票 — Cursor/Claude Skill + yhh-cli + MCP stdio(OpenClaw)

Downloads

215

Readme

yhh-mcp-server

御华浩(YHH)B2B 机票 单包发布yhh-cli(Cursor/Claude Skill)+ yhh-mcp(OpenClaw MCP stdio)+ SDK。

Cursor / Claude Code(推荐)

npm install -g yhh-mcp-server

# 一次性配置
yhh-cli config init --api-url http://your-api-host:18080 --client-secret your-secret

# 安装 Skill + 自检
yhh-cli setup --target cursor
yhh-cli doctor

# 验证
yhh-cli auth login --account <账号> --password <密码> --sender-id cursor:default
yhh-cli flight search --depart 上海 --arrive 西安 --date 2026-07-08 --sender-id cursor:default

在 Cursor 中 @yhh-flight-booking,Agent 通过 Shell 执行 yhh-cli

配置也可写入 ~/.config/yhh/config.json,或由环境变量 YHH_API_BASE_URLYHH_CLIENT_SECRET 注入。

OpenClaw(MCP stdio)

{
  "mcp": {
    "servers": {
      "yhh-travel": {
        "command": "npx",
        "args": ["-y", "yhh-mcp-server"],
        "env": {
          "YHH_API_BASE_URL": "http://your-api-host:8080",
          "YHH_CLIENT_SECRET": "your-client-secret"
        }
      }
    }
  }
}

本地开发:

{
  "command": "node",
  "args": ["/path/to/mcp-server/dist/mcp/index.js"]
}

包内结构

mcp-server/
├── src/sdk/       # API 库(import from 'yhh-mcp-server')
├── src/mcp/       # MCP Server(bin: yhh-mcp, yhh-mcp-server)
├── src/cli/       # CLI(bin: yhh-cli)
├── skills/        # yhh-flight-booking Skill
├── data/          # city_airport_mapping.json
└── dist/

yhh-cli 命令一览

| 分组 | 命令 | |------|------| | 安装 | setup, config init/show, doctor, skills install | | 认证 | auth check/login/logout | | 航班 | flight search/detail/offer-detail/return-search/return-offers/note | | 乘客 | passenger list/detail/save/remove | | 订单 | order create/pay/detail/list/cancel |

复杂参数用 --stdin--file order.json 传 JSON(字段同 MCP b2b_* 工具,不含 sender_id)。

环境变量

| 变量 | 必填 | 说明 | |------|------|------| | YHH_API_BASE_URL | 是 | B2B 网关根地址 | | YHH_CLIENT_SECRET | 是 | OAuth Client-Secret | | YHH_TENANT_ID | 否 | 默认 000000 | | YHH_MCP_AUTH_DIR | 否 | 登录态目录,默认 ~/.openclaw/mcp-auth |

发布

npm run pack:check
npm login --registry=https://registry.npmjs.org/
npm publish

开发

cd mcp-server
npm install
npm run build
node dist/cli/index.js --help
node dist/mcp/index.js    # MCP stdio