后端与数据库

strava

okou-ai/okou-skills

Strava API for fitness activities. Use when user mentions "Strava", "running", "cycling", "activity", or asks about fitness tracking.

  • 584 次安装
  • 81 星标
  • 收录于

安装命令

npx skills add https://github.com/okou-ai/okou-skills --skill strava

SKILL.md

Troubleshooting

If requests fail, run zero doctor check-connector --env-name STRAVA_TOKEN or zero doctor check-connector --url https://www.strava.com/api/v3/athlete --method GET

Athlete

Get Authenticated Athlete Profile

curl -s "https://www.strava.com/api/v3/athlete" --header "Authorization: Bearer $STRAVA_TOKEN" | jq '{id, firstname, lastname, city, country, sex, premium, created_at, follower_count, friend_count}'

Get Athlete Statistics

Replace <athlete-id> with the id from the athlete profile above:

curl -s "https://www.strava.com/api/v3/athletes/<athlete-id>/stats" --header "Authorization: Bearer $STRAVA_TOKEN" | jq '{recent_run_totals, recent_ride_totals, ytd_run_totals, ytd_ride_totals, all_run_totals, all_ride_totals}'