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

@meituan-travel/travel-cli

v1.0.16

Published

美团酒旅 CLI - 酒店、机票、火车票、景点、行程规划

Readme

@meituan-travel/travel-cli

美团酒旅 CLI - 酒店、机票、火车票、景点、行程规划查询工具。

安装

npm i -g @meituan-travel/travel-cli

配置

使用前需要设置认证 Token。将 Token 保存到配置文件:

mkdir -p ~/.config/meituan-travel
cat > ~/.config/meituan-travel/config.json << 'EOF'
{
  "key": "your-token"
}
EOF

Token 从以下位置获取:https://developer.meituan.com/zh/v2/dev/token

使用方式

# 完整参数(城市 + 查询内容)
mttravel 北京 "北京到上海的机票"

# 省略城市(默认北京)
mttravel "北京到上海的机票"

# 酒店搜索
mttravel 上海 "外滩附近酒店"

# 景点推荐
mttravel 杭州 "西湖景点推荐"

# 行程规划
mttravel 成都 "3天行程规划 预算2000"

输出说明

  • stdout: 查询结果内容(可直接展示)
  • stderr: 进度信息(如 🔍 查询中: 北京 - ...
  • exit 0: 成功
  • exit 1: 普通错误(网络超时、参数错误等)
  • exit 3: 鉴权失败(Token 无效或已过期,需更新 Token)

环境变量(可选)

| 变量 | 说明 | 默认值 | |------|------|--------| | MEITUAN_RAW_JSON | 输出原始 JSON | 0(输出格式化内容) |

错误处理

| 错误信息 | 说明 | |----------|------| | 未配置 Token | 需要先配置 config.json | | 请求超时,请稍后重试 | 网络超时,建议重试 | | 鉴权失败 (exit 3) | Token 无效或已过期,需更新 Token | | 暂无结果,建议调整关键词重试 | 查询无结果 |

示例

# 查询机票
mttravel 北京 "4月10日 北京到上海 机票"

# 查询酒店
mttravel "北京 4星酒店 预算500"

# 查询景点
mttravel 西安 "历史古迹"

# 行程规划
mttravel "杭州3天旅行 情侣 预算3000"