360 Secure SkillHub
360 安全技能中心

Strava Python

通过 Python 与 stravalib 访问 Strava,提供 recent、stats、last 三个命令行子命令,分别查看近期活动、周期统计和最近一次训练记录;setup.py 提供交互式 OAuth 配置向导,凭证保存到本地文件。需自备 Strava API 凭证并受其速率限制约束。

abclark
abclark
热度 80.87
最近更新 2026-05-11 16:27:50
分类:生活依赖:代码执行 / 第三方 API / 读写文件应用场景:健康 / 数据处理

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add strava-python
Metadata
name
strava-python
version
1.0.0
description
Query Strava activities, stats, and workout data using Python/stravalib with interactive setup
homepage
https://www.strava.com
metadata
{"openclaw":{"emoji":"🏃","requires":{"bins":["python3"]},"install":[{"id":"pip","kind":"pip","package":"stravalib","label":"Install stravalib (pip)"}]}}

Strava Python

Query your Strava activities, stats, and workout data through OpenClaw using Python and stravalib.

Why this skill vs others: Uses Python/stravalib with an interactive setup wizard (vs curl-based skills requiring manual JSON configuration).

Requirements

  • Python 3.7+
  • stravalib package
  • Strava API credentials (free)

Setup

  1. Install dependencies:

    pip install stravalib
    
  2. Run setup:

    python3 setup.py
    

    This will:

    • Guide you through creating a Strava API app
    • Handle OAuth authentication
    • Save credentials to ~/.strava_credentials.json

Commands

Recent activities:

python3 strava_control.py recent

Weekly/monthly stats:

python3 strava_control.py stats

Last activity:

python3 strava_control.py last

Examples

Ask OpenClaw:

  • "Show my recent Strava activities"
  • "What are my Strava stats this week?"
  • "What was my last Strava workout?"

Files

  • strava_control.py - Main controller script
  • setup.py - Interactive setup wizard
  • SKILL.md - This file
  • ~/.strava_credentials.json - Credentials (auto-generated)

Notes

  • Requires Strava account (free)
  • API credentials are personal and should not be shared
  • Rate limits: 100 requests per 15 minutes, 1,000 daily