← 返回 Skills 市场
gzzzj

Garmin Health Report

作者 GZZZJ · GitHub ↗ · v2.0.0
cross-platform ⚠ suspicious
330
总下载
0
收藏
0
当前安装
1
版本数
在 OpenClaw 中安装
/install garmin-health-report
功能描述
Generate comprehensive daily health reports from Garmin Connect data with professional running analysis (Heart Rate Zones, TRIMP, Jack Daniels VDOT).
使用说明 (SKILL.md)

Garmin Health Report

Generate professional daily health reports from Garmin Connect data with advanced running analysis.

Features:

  • Sleep Analysis: Duration, stages (deep/light/REM), scores, and 7-dimension quality ratings
  • Heart Rate Monitoring: Resting HR with recovery status
  • Activity Tracking: Steps, distance, floors, goal completion
  • Professional Running Metrics:
    • Heart Rate Zones (Zone 1-5 distribution)
    • TRIMP (Training Impulse) load calculation
    • Jack Daniels VDOT estimation with training paces
    • Personalized recovery and training advice
  • 7-Day Trend Analysis: Activity patterns and consistency tracking
  • Personalized Recommendations: Sleep tips, step goals, training insights

Regional Support: Works with both Garmin.com (international) and Garmin.cn (China region) accounts.

Quick Start

1. Install Dependencies

This skill requires Python 3.8 or higher and garth library:

# Install garth (Garmin Connect authentication library)
pip3 install garth

# Verify installation
python3 -c "import garth; print('garth installed successfully')"

2. Authenticate with Garmin Connect

First time setup requires authentication with Garmin Connect:

# Navigate to skill directory
cd ~/.agents/skills/garmin-health-report

# Run authentication script
python3 authenticate.py

Follow prompts to enter your Garmin Connect username and password. Tokens will be securely stored in ~/.garmin-health-report/tokens.json.

For China Region Users (garmin.cn):

Create a config file before authenticating:

mkdir -p ~/.garmin-health-report
cat > ~/.garmin-health-report/config.json \x3C\x3C 'EOF'
{
  "is_cn": true,
  "log_level": "INFO"
}
EOF

Then run python3 authenticate.py.

3. Generate Health Report

Generate a report for today or any specific date:

# Today's report
python3 health_daily_report.py

# Specific date
python3 health_daily_report.py 2025-01-15

# Save to file
python3 health_daily_report.py > ~/health_report_$(date +%Y-%m-%d).txt

4. (Optional) Automate with Cron

To automatically generate daily health reports, add to your crontab:

crontab -e

# Add this line for daily report at 23:00
0 23 * * * /usr/bin/python3 /path/to/health_daily_report.py >> /path/to/health_report.log 2>&1

Usage Examples

# Generate today's report
python3 health_daily_report.py

# Generate report for a specific date
python3 health_daily_report.py 2026-03-01

# Check authentication status
python3 authenticate.py

# Logout and remove saved tokens
python3 authenticate.py
# Then choose 'y' when prompted to logout

Understanding the Metrics

Heart Rate Zones

Zone Intensity Purpose % HRR
1 Recovery Warm-up, recovery \x3C50%
2 Aerobic Base Build foundation 50-60%
3 Aerobic Endurance Improve endurance 60-70%
4 Lactate Threshold Raise threshold 70-80%
5 VO2Max Maximal intensity >80%

TRIMP (Training Impulse)

A measure of training load combining duration and intensity:

  • \x3C100: Light load - recovery days
  • 100-200: Moderate load - daily training
  • 200-300: High load - needs recovery
  • >300: Very high load - recommend rest

VDOT (VDot O₂max)

Estimate of running aerobic capacity (based on Jack Daniels' Running Formula). Higher VDOT = faster race pace potential.

VDOT is used to calculate optimal training paces:

  • E (Easy): Recovery and base building
  • M (Marathon): Marathon race pace
  • T (Threshold): Tempo/lactate threshold
  • I (Interval): Speed intervals
  • R (Repetition): Repetitions/sprints

Output Format

The report generates a beautifully formatted text output:

📅 2026-03-01 健康日报
============================================================

😴 睡眠质量
总睡眠:7.7 小时
└─ 深睡:1.4h (18%) | 浅睡:4.5h (58%) | REM:1.9h (24%)

睡眠评分:82 (良好)

💓 心率监测
静息心率:57 bpm 💙

👟 活动量
今日步数:13620 步
步数目标:10000 步
完成度:136.2%
...

💪 运动数据分析(专业版)
... (detailed HR zones, TRIMP, VDOT analysis)

💡 J.A.R.V.I.S.有话说
... (personalized insights)

📈 长期趋势(过去7天)
... (7-day pattern analysis)

============================================================
💪 今天运动量很充足!继续保持!

✨ 明天加油!💪

Configuration

Edit the configuration section at the top of health_daily_report.py:

# Health history file (for 7-day trend analysis)
HISTORY_FILE = os.path.expanduser("~/.garmin_health_report/history.json")

# User profile (optional, for more accurate HR zone calculations)
USER_RESTING_HR = None  # e.g., 53
USER_AGE = None        # e.g., 25

Setting USER_RESTING_HR and USER_AGE improves accuracy of:

  • Heart rate zone calculations
  • TRIMP (Training Impulse) estimation
  • Recovery status assessment

If not set, defaults will be used (Age: 30, Resting HR: 60).

Troubleshooting

Error: garth not installed

ModuleNotFoundError: No module named 'garth'

Solution: Install garth:

pip3 install garth

Error: Not authenticated

Error: Not authenticated.
Run 'python3 authenticate.py' first.

Solution: Run python3 authenticate.py to authenticate with Garmin Connect.

China Region Issues

# Verify config
cat ~/.garmin-health-report/config.json
# Should show: {"is_cn": true, ...}

# Clear tokens and re-authenticate
rm ~/.garmin-health-report/tokens.json
python3 authenticate.py

Privacy & Data

  • All data is retrieved from your personal Garmin Connect account
  • Tokens are stored locally in ~/.garmin-health-report/tokens.json
  • No data is sent to third-party servers beyond Garmin's API
  • Health history is stored locally in ~/.garmin_health_report/history.json
  • Token files have restricted permissions (600: owner read/write only)

Differences from Original (garmer-based Version)

This version uses garth directly instead of garmer:

Simpler dependency - Only requires garth (a single library) ✅ Same features - All original functionality preserved:

  • Sleep analysis
  • Heart rate monitoring
  • Steps tracking
  • Activity analysis
  • Professional running metrics (HR Zones, TRIMP, VDOT)
  • 7-day trend analysis
  • Personalized recommendations

Why the change?

  • Removes complex dependency chain (garmer → garth)
  • Uses the underlying Garmin Connect library directly
  • Easier to install (pip3 install garth vs dealing with garmer's issues)
  • Better error handling and debugging

License

MIT License - See LICENSE file for details.

Credits

  • Uses garth library for Garmin Connect API access
  • Jack Daniels VDOT formulas based on "Daniels' Running Formula"
  • TRIMP calculation using Banister's equation
安全使用建议
Things to consider before installing: - Inspect SKILL.md and README for any hidden/control characters (the pre-scan flagged unicode-control-chars). Open the files in a hex-aware editor or run utilities to reveal invisible characters. - Review the included Python files locally (authenticate.py, garmin_client.py, health_daily_report.py). The code appears to call only the garth library and Garmin endpoints, but verify there are no unexpected network calls or hard-coded endpoints. - Understand token storage: the skill saves OAuth tokens under ~/.garmin-health-report (and a separate history file under ~/.garmin_health_report). Ensure you are comfortable with tokens being stored on disk and check file permissions. Logout/delete behavior may not remove all garth-generated token files (oauth1/oauth2 json) — manually inspect the directory if you remove credentials. - Verify the garth package reputation (pip package index, project repo). Using third-party pip packages has inherent supply-chain risk; prefer reviewing the package source or pinning versions. - Note region defaulting: authenticate.py defaults to China region unless you create config.json or pass explicit args. If you have a non-China Garmin account, run the auth script with the 'international' mode or create config.json to avoid connecting to the wrong domain. - If you have security concerns, run the scripts in a restricted environment (container/VM) and do not enter credentials until you are satisfied with the source. If you'd like, I can highlight the exact lines that reference token paths, domain configuration, and any places that might leave residual tokens so you can inspect them further.
功能分析
Type: OpenClaw Skill Name: garmin-health-report Version: 2.0.0 The OpenClaw skill 'garmin-health-report' is classified as benign. All code and documentation align with the stated purpose of generating health reports from Garmin Connect data. Credential handling uses `getpass` and stores tokens locally in `~/.garmin-health-report/tokens.json` via the `garth` library. Data fetching is exclusively from Garmin Connect API endpoints. No evidence of data exfiltration, unauthorized remote control, persistence mechanisms (beyond user-instructed `crontab` setup), or prompt injection attempts against the agent was found. File system access is limited to user-specific configuration and history files.
能力评估
Purpose & Capability
Name/description, required binary (python3), dependency (garth), and the included Python modules (authenticate.py, garmin_client.py, health_daily_report.py) align with a Garmin Connect report generator. There are no unrelated cloud credentials or unexpected services requested.
Instruction Scope
Runtime instructions tell the user to run authenticate.py and health_daily_report.py and to store tokens under ~/.garmin-health-report; that matches the code. Minor oddities: authenticate.py defaults to China region (is_cn True) if no config exists, which may surprise international users; code reads/writes files in the user's home directory (~/.garmin-health-report and ~/.garmin_health_report). No instructions ask the agent to read broad system state or unrelated secrets.
Install Mechanism
Installation is via pip (garth from PyPI) as declared in SKILL.md and requirements.txt — a standard mechanism for Python tools. This is expected but comes with the normal caveat that third-party pip packages can carry risk; there are no downloads from arbitrary URLs or extracted archives.
Credentials
The skill requests no environment variables but reads/writes files in the user home directory to persist tokens and history. It requires interactive entry of Garmin username/password and stores tokens locally (garth.save into ~/.garmin-health-report). This is proportionate for a client that talks to Garmin, but users should be aware tokens and credentials are stored on disk and deletion/cleanup in logout may be incomplete.
Persistence & Privilege
The skill is not always-enabled, does not modify other skills, and does not request elevated or persistent platform privileges. Its file writes are limited to user-owned home-directory locations.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install garmin-health-report
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /garmin-health-report 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v2.0.0
**Major update: Migrates to direct use of the `garth` library, simplifying dependencies and setup.** - Now uses `garth` directly for Garmin Connect access (no longer requires `garmer`) - Quick start guides and troubleshooting updated for simple `pip3 install garth` setup - All features preserved: sleep, heart rate, step tracking, running metrics (HR Zones, TRIMP, VDOT), trend analysis, and advice - Expanded documentation on authentication, China region support, and configuration - Improved privacy explanations; all data and tokens stored locally only - Clear comparison with previous versions and rationale for the change
元数据
Slug garmin-health-report
版本 2.0.0
许可证
累计安装 0
当前安装数 0
历史版本数 1
常见问题

Garmin Health Report 是什么?

Generate comprehensive daily health reports from Garmin Connect data with professional running analysis (Heart Rate Zones, TRIMP, Jack Daniels VDOT). 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 330 次。

如何安装 Garmin Health Report?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install garmin-health-report」即可一键安装,无需额外配置。

Garmin Health Report 是免费的吗?

是的,Garmin Health Report 完全免费(开源免费),可自由下载、安装和使用。

Garmin Health Report 支持哪些平台?

Garmin Health Report 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 Garmin Health Report?

由 GZZZJ(@gzzzj)开发并维护,当前版本 v2.0.0。

💬 留言讨论