友盟 (Umeng) 移动分析 Open API 命令行工具。
一键安装:
curl -fsSL https://raw.githubusercontent.com/biao29/umeng-cli/main/scripts/install.sh | bash或通过 Go:
go install github.com/biao29/umeng-cli/cmd/umeng@latest或从 Releases 下载预编译二进制。
umeng config set api_key <your-api-key>
umeng config set api_security <your-api-security>或通过环境变量:
export UMENG_API_KEY=<your-api-key>
export UMENG_API_SECURITY=<your-api-security># 查看所有应用
umeng apps
# 查看应用日统计
umeng daily <appkey>
# 查看留存率
umeng retention <appkey>
# 综合报告
umeng report <appkey>
# 按名称查找
umeng daily --app "句读_Android"
# JSON 输出
umeng apps --json| 命令 | 说明 |
|---|---|
umeng apps |
列出所有应用 |
umeng overview |
所有应用昨日/今日汇总 |
umeng daily |
日统计 (DAU, 新增, 启动) |
umeng active |
活跃用户趋势 |
umeng new-users |
新增用户趋势 |
umeng launches |
启动次数趋势 |
umeng retention |
留存率 (次日~7日) |
umeng duration |
使用时长分布 |
umeng channels |
渠道分布 |
umeng versions |
版本分布 |
umeng report |
综合报告 |
umeng config |
配置管理 |
umeng skill |
AI Agent Skill 管理 |
umeng doctor |
健康检查 |
支持 YYYY-MM-DD、today、yesterday、-7d、-30d。
- 默认:终端彩色表格
--json:JSON envelope--quiet/--agent:纯数据 JSON--md:Markdown 表格--count:仅数量
# 安装 Skill 到 Claude Code
umeng skill install
# 检查集成状态
umeng doctor设置 --agent 或环境变量 CLAUDE_CODE=1 自动启用结构化 JSON 输出。
make build # 编译
make test # 测试
make vet # 静态分析MIT