{
  "schemaVersion": "1.0",
  "item": {
    "slug": "trainingpeaks",
    "name": "TrainingPeaks",
    "source": "tencent",
    "type": "skill",
    "category": "开发工具",
    "sourceUrl": "https://clawhub.ai/rubengarciam/trainingpeaks",
    "canonicalUrl": "https://clawhub.ai/rubengarciam/trainingpeaks",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadMode": "redirect",
    "downloadUrl": "/downloads/trainingpeaks",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=trainingpeaks",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "installMethod": "Manual import",
    "extraction": "Extract archive",
    "prerequisites": [
      "OpenClaw"
    ],
    "packageFormat": "ZIP package",
    "includedAssets": [
      "SKILL.md",
      "scripts/tp.py"
    ],
    "primaryDoc": "SKILL.md",
    "quickSetup": [
      "Download the package from Yavira.",
      "Extract the archive and review SKILL.md first.",
      "Import or place the package into your OpenClaw setup."
    ],
    "agentAssist": {
      "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
      "steps": [
        "Download the package from Yavira.",
        "Extract it into a folder your agent can access.",
        "Paste one of the prompts below and point your agent at the extracted folder."
      ],
      "prompts": [
        {
          "label": "New install",
          "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
        },
        {
          "label": "Upgrade existing",
          "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
        }
      ]
    },
    "sourceHealth": {
      "source": "tencent",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-07T17:22:31.273Z",
      "expiresAt": "2026-05-14T17:22:31.273Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=afrexai-annual-report",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=afrexai-annual-report",
        "contentDisposition": "attachment; filename=\"afrexai-annual-report-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null
      },
      "scope": "source",
      "summary": "Source download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this source.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/trainingpeaks"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    },
    "downloadPageUrl": "https://openagent3.xyz/downloads/trainingpeaks",
    "agentPageUrl": "https://openagent3.xyz/skills/trainingpeaks/agent",
    "manifestUrl": "https://openagent3.xyz/skills/trainingpeaks/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/trainingpeaks/agent.md"
  },
  "agentAssist": {
    "summary": "Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.",
    "steps": [
      "Download the package from Yavira.",
      "Extract it into a folder your agent can access.",
      "Paste one of the prompts below and point your agent at the extracted folder."
    ],
    "prompts": [
      {
        "label": "New install",
        "body": "I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete."
      },
      {
        "label": "Upgrade existing",
        "body": "I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run."
      }
    ]
  },
  "documentation": {
    "source": "clawhub",
    "primaryDoc": "SKILL.md",
    "sections": [
      {
        "title": "TrainingPeaks Skill",
        "body": "CLI access to the TrainingPeaks internal API. Pure Python stdlib — no pip dependencies."
      },
      {
        "title": "Setup: Getting Your Auth Cookie",
        "body": "Log in to TrainingPeaks in your browser\nOpen DevTools → Application → Cookies → app.trainingpeaks.com\nFind the cookie named Production_tpAuth\nCopy its value (long encoded string)\n\nThen authenticate:\n\npython3 scripts/tp.py auth \"<paste_cookie_value_here>\"\n\nOr set the environment variable (useful for CI/scripts):\n\nexport TP_AUTH_COOKIE=\"<cookie_value>\"\n\nCredentials are stored in ~/.trainingpeaks/ with 0600 permissions."
      },
      {
        "title": "auth <cookie> — Authenticate",
        "body": "Store and validate a Production_tpAuth cookie. Exchanges it for a Bearer token and caches the athlete ID.\n\npython3 scripts/tp.py auth \"eyJhbGci...\"\n# ✓ Authenticated successfully!\n#   Account: user@example.com\n#   Athlete ID: 12345\n#   Token expires in: 60 minutes"
      },
      {
        "title": "auth-status — Check Authentication",
        "body": "python3 scripts/tp.py auth-status\n# Cookie: stored (file)\n# Token: valid (42m remaining)\n# Athlete ID: 12345\n# ✓ Ready"
      },
      {
        "title": "profile [--json] — Athlete Profile",
        "body": "python3 scripts/tp.py profile\n# Profile\n# ════════════════════════════════════════\n#   Name:        Ruben Example\n#   Email:       ruben@example.com\n#   Athlete ID:  12345\n#   Account:     Premium\n#   Bike FTP:    280 W"
      },
      {
        "title": "workouts <start> <end> [--filter all|planned|completed] [--json]",
        "body": "List workouts in a date range (max 90 days).\n\n# All workouts this week\npython3 scripts/tp.py workouts 2026-01-26 2026-02-01\n\n# Only completed workouts\npython3 scripts/tp.py workouts 2026-01-01 2026-01-31 --filter completed\n\n# Raw JSON for scripting\npython3 scripts/tp.py workouts 2026-01-26 2026-02-01 --json\n\nOutput columns: Date, Title, Sport, Status (✓/○), Planned duration, Actual duration, TSS, Distance."
      },
      {
        "title": "workout <id> [--json] — Workout Detail",
        "body": "Get full details for a single workout including description, coach comments, and all metrics.\n\npython3 scripts/tp.py workout 123456789\n# Workout: Tempo Intervals 3x10min\n# ══════════════════════════════════════════════════\n#   Date:         2026-01-28\n#   Sport:        Bike\n#   Status:       Completed ✓\n#   ..."
      },
      {
        "title": "fitness [--days 90] [--json] — CTL/ATL/TSB",
        "body": "Get fitness (CTL), fatigue (ATL), and form (TSB) data.\n\n# Last 90 days (default)\npython3 scripts/tp.py fitness\n\n# Full season\npython3 scripts/tp.py fitness --days 365\n\n# JSON for charts\npython3 scripts/tp.py fitness --json\n\nShows a summary with current CTL/ATL/TSB and status interpretation, plus a 14-day daily table."
      },
      {
        "title": "peaks <sport> <pr_type> [--days 3650] [--json] — Personal Records",
        "body": "Get ranked personal records by sport and metric.\n\n# Best 20-minute power (all time)\npython3 scripts/tp.py peaks Bike power20min\n\n# 5K running PRs from last year\npython3 scripts/tp.py peaks Run speed5K --days 365\n\n# 5-second max power\npython3 scripts/tp.py peaks Bike power5sec\n\nValid PR types:\n\nSportTypesBikepower5sec, power1min, power5min, power10min, power20min, power60min, power90min, hR5sec, hR1min, hR5min, hR10min, hR20min, hR60min, hR90minRunhR5sec–hR90min, speed400Meter, speed800Meter, speed1K, speed1Mi, speed5K, speed5Mi, speed10K, speed10Mi, speedHalfMarathon, speedMarathon, speed50K"
      },
      {
        "title": "Token Management",
        "body": "Bearer tokens are cached in ~/.trainingpeaks/token.json\nTokens expire in ~1 hour; auto-refreshed from stored cookie\nCookie lasts weeks; stored in ~/.trainingpeaks/cookie\nIf the cookie expires, you'll get a clear error to re-authenticate"
      },
      {
        "title": "File Locations",
        "body": "FilePurpose~/.trainingpeaks/cookieStored Production_tpAuth cookie~/.trainingpeaks/token.jsonCached OAuth Bearer token + expiry~/.trainingpeaks/config.jsonCached athlete ID and account info"
      },
      {
        "title": "Notes",
        "body": "All dates use YYYY-MM-DD format\nMaximum workout query range: 90 days\nRate limiting: 150ms minimum between API requests\nTP_AUTH_COOKIE environment variable overrides stored cookie\nDefault output is human-readable; --json gives raw API responses"
      }
    ],
    "body": "TrainingPeaks Skill\n\nCLI access to the TrainingPeaks internal API. Pure Python stdlib — no pip dependencies.\n\nSetup: Getting Your Auth Cookie\nLog in to TrainingPeaks in your browser\nOpen DevTools → Application → Cookies → app.trainingpeaks.com\nFind the cookie named Production_tpAuth\nCopy its value (long encoded string)\n\nThen authenticate:\n\npython3 scripts/tp.py auth \"<paste_cookie_value_here>\"\n\n\nOr set the environment variable (useful for CI/scripts):\n\nexport TP_AUTH_COOKIE=\"<cookie_value>\"\n\n\nCredentials are stored in ~/.trainingpeaks/ with 0600 permissions.\n\nCommands\nauth <cookie> — Authenticate\n\nStore and validate a Production_tpAuth cookie. Exchanges it for a Bearer token and caches the athlete ID.\n\npython3 scripts/tp.py auth \"eyJhbGci...\"\n# ✓ Authenticated successfully!\n#   Account: user@example.com\n#   Athlete ID: 12345\n#   Token expires in: 60 minutes\n\nauth-status — Check Authentication\npython3 scripts/tp.py auth-status\n# Cookie: stored (file)\n# Token: valid (42m remaining)\n# Athlete ID: 12345\n# ✓ Ready\n\nprofile [--json] — Athlete Profile\npython3 scripts/tp.py profile\n# Profile\n# ════════════════════════════════════════\n#   Name:        Ruben Example\n#   Email:       ruben@example.com\n#   Athlete ID:  12345\n#   Account:     Premium\n#   Bike FTP:    280 W\n\nworkouts <start> <end> [--filter all|planned|completed] [--json]\n\nList workouts in a date range (max 90 days).\n\n# All workouts this week\npython3 scripts/tp.py workouts 2026-01-26 2026-02-01\n\n# Only completed workouts\npython3 scripts/tp.py workouts 2026-01-01 2026-01-31 --filter completed\n\n# Raw JSON for scripting\npython3 scripts/tp.py workouts 2026-01-26 2026-02-01 --json\n\n\nOutput columns: Date, Title, Sport, Status (✓/○), Planned duration, Actual duration, TSS, Distance.\n\nworkout <id> [--json] — Workout Detail\n\nGet full details for a single workout including description, coach comments, and all metrics.\n\npython3 scripts/tp.py workout 123456789\n# Workout: Tempo Intervals 3x10min\n# ══════════════════════════════════════════════════\n#   Date:         2026-01-28\n#   Sport:        Bike\n#   Status:       Completed ✓\n#   ...\n\nfitness [--days 90] [--json] — CTL/ATL/TSB\n\nGet fitness (CTL), fatigue (ATL), and form (TSB) data.\n\n# Last 90 days (default)\npython3 scripts/tp.py fitness\n\n# Full season\npython3 scripts/tp.py fitness --days 365\n\n# JSON for charts\npython3 scripts/tp.py fitness --json\n\n\nShows a summary with current CTL/ATL/TSB and status interpretation, plus a 14-day daily table.\n\npeaks <sport> <pr_type> [--days 3650] [--json] — Personal Records\n\nGet ranked personal records by sport and metric.\n\n# Best 20-minute power (all time)\npython3 scripts/tp.py peaks Bike power20min\n\n# 5K running PRs from last year\npython3 scripts/tp.py peaks Run speed5K --days 365\n\n# 5-second max power\npython3 scripts/tp.py peaks Bike power5sec\n\n\nValid PR types:\n\nSport\tTypes\nBike\tpower5sec, power1min, power5min, power10min, power20min, power60min, power90min, hR5sec, hR1min, hR5min, hR10min, hR20min, hR60min, hR90min\nRun\thR5sec–hR90min, speed400Meter, speed800Meter, speed1K, speed1Mi, speed5K, speed5Mi, speed10K, speed10Mi, speedHalfMarathon, speedMarathon, speed50K\nToken Management\nBearer tokens are cached in ~/.trainingpeaks/token.json\nTokens expire in ~1 hour; auto-refreshed from stored cookie\nCookie lasts weeks; stored in ~/.trainingpeaks/cookie\nIf the cookie expires, you'll get a clear error to re-authenticate\nFile Locations\nFile\tPurpose\n~/.trainingpeaks/cookie\tStored Production_tpAuth cookie\n~/.trainingpeaks/token.json\tCached OAuth Bearer token + expiry\n~/.trainingpeaks/config.json\tCached athlete ID and account info\nNotes\nAll dates use YYYY-MM-DD format\nMaximum workout query range: 90 days\nRate limiting: 150ms minimum between API requests\nTP_AUTH_COOKIE environment variable overrides stored cookie\nDefault output is human-readable; --json gives raw API responses"
  },
  "trust": {
    "sourceLabel": "tencent",
    "provenanceUrl": "https://clawhub.ai/rubengarciam/trainingpeaks",
    "publisherUrl": "https://clawhub.ai/rubengarciam/trainingpeaks",
    "owner": "rubengarciam",
    "version": "1.0.1",
    "license": null,
    "verificationStatus": "Indexed source record"
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/trainingpeaks",
    "downloadUrl": "https://openagent3.xyz/downloads/trainingpeaks",
    "agentUrl": "https://openagent3.xyz/skills/trainingpeaks/agent",
    "manifestUrl": "https://openagent3.xyz/skills/trainingpeaks/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/trainingpeaks/agent.md"
  }
}