strava-api

Manage Strava fitness data via OAuth, CLI, and Python client.

24|2|Updated Nov 5, 2025
One-click install
npx skills add https://github.com/kdoronin/claude_code_skills --skill strava-api
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: strava-api
Source: https://github.com/kdoronin/claude_code_skills/tree/main/strava-api
Command: npx skills add https://github.com/kdoronin/claude_code_skills --skill strava-api

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires requests, and includes scripts (resource) and references (resource) components.

What problem does it solve?

Provides a secure, developer-friendly way to access and manage Strava fitness data while preventing secret exposure to AI agents or logs. It centralizes OAuth setup, token refresh, and API calls so users and scripts can retrieve athlete profiles, activities, segments, routes, and related training data without manual token juggling.

Core Features & Use Cases

  • Interactive OAuth Setup: Guided flow to create a Strava application, obtain an authorization code, and exchange it for tokens.
  • Secure Credential Handling: Stores client credentials and tokens in the system keychain or Linux secret service so secrets are not exposed to AI or logs.
  • Automatic Token Management: Refreshes access tokens transparently and persists non-secret metadata locally.
  • CLI and Python Client: Ready-to-use CLI commands and a StravaClient class to get athlete profiles, list and create activities, explore segments, export routes, and fetch activity streams.
  • Use Case: Validate configuration, fetch your athlete profile, list recent activities, and export a route as GPX for external analysis.

Quick Start

Get my athlete profile and list my 20 most recent activities to verify Strava is configured and returning data.

Frequently Asked Questions about strava-api

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate fetching Strava activities using Python?

Automate fetching Strava activities in Python by using the provided StravaClient class or CLI commands to retrieve athlete profiles and activity lists, with automatic OAuth token management and JSON response handling.

What's the best way to manage Strava API OAuth tokens securely?

Manage Strava API OAuth tokens securely by storing client credentials and access tokens in the system keychain or Linux secret service, preventing exposure to AI agents or logs while supporting automatic transparent token refresh.

Does this Python Strava integration support exporting activity routes as GPX?

Yes, this Python Strava integration supports exporting routes as GPX files. You can retrieve activity streams and routes via the API client for external analysis, mapping, or fitness tracking applications.

Can I use CLI commands to retrieve athlete profiles and explore Strava segments?

Yes, you can use ready-to-use CLI commands to retrieve athlete profiles, list activities, explore segments, and fetch activity streams from Strava without writing custom Python scripts for each request.

What are the Strava API v3 rate limits and how are they handled?

The Strava API v3 enforces rate limits on requests, and this integration adheres to those limits while managing JSON responses. It applies to workflows involving fetching, creating, updating, and exporting fitness data within the allowed quotas.

Do I need to manually refresh Strava API access tokens during long automation workflows?

No, you do not need to manually refresh Strava API access tokens. The integration provides automatic token refresh support, transparently persisting non-secret metadata locally so long-running Python automation workflows continue uninterrupted.