Strava

Интеграция Strava API с Model Context Protocol SDK
  • python

0

GitHub Stars

python

Language

7 months ago

First Indexed

3 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs

You can integrate Strava data with the Model Context Protocol (MCP) to analyze workouts, receive training recommendations, and manage token refreshes automatically. This server exposes Strava resources to your MCP client, enabling seamless querying of activities, zones, gear, and athlete data while applying rate limiting and analysis tools.

How to use

To use this MCP server, you run the MCP client against the Strava integration server and then access Strava resources through the common MCP API. You can read your activities, fetch details for a specific activity, retrieve training zones, and obtain recommendations based on your data. The server provides tools to analyze individual activities and whole training loads, returning structured results you can feed into dashboards or coaching logic.

How to install

Prerequisites you need on your machine before starting:

  • Python 3.10+
  • uv (recommended)
  • A Strava account
  • Claude Desktop (for testing or development)

Step 1 — Install the MCP client tooling and dependencies

# Clone the integration repository
git clone https://github.com/rbctmz/mcp-server-strava.git
cd mcp-server-strava

# Install the MCP client tooling (CLI) via uv
uv add "mcp[cli]"

# Install dependencies and the server package
uv pip install .

# Optional: install in development mode
uv pip install -e ".[dev]"

Step 2 — Prepare the Strava API and environment

# Create the environment file from a template
cp .env-template .env

# Obtain access tokens by running the helper script
python scripts/auth.py

# Verify the MCP server is reachable through the development entry point
mcp dev src/server.py
curl -X GET "http://localhost:8000/activities"

Additional setup and configuration

Configure Strava API access by creating an application with the following values:

  • Application Name: MCP Strava Integration
  • Category: Training Analysis
  • Website: http://localhost
  • Authorization Callback Domain: localhost

Environment and secrets to enable tokens and API access include the following values. These are typically supplied via a secure secret store or environment file.

STRAVA_CLIENT_ID=<client_id>
STRAVA_CLIENT_SECRET=<client_secret>
STRAVA_REFRESH_TOKEN=<refresh_token>

Security, secrets and tokens

Protect tokens and credentials by keeping the environment file out of version control. Use secret management in your CI/CD pipeline and apply rate limiting to API requests to avoid hitting Strava limits.

Recommended rate limit as a starting point: 100 requests per 15 minutes. Adapt this to your usage and Strava guidelines.

Tools and endpoints available

The server exposes these MCP endpoints and tooling to perform analysis and retrieve data.

Available tools

analyze_activity

Analyze a single Strava activity by its ID and return structured metrics such as type, distance, moving time, pace, and effort.

analyze_training_load

Analyze a collection of activities to produce a training load summary, including total distance, total time, and heart-rate zoning.

get_activity_recommendations

Provide recommendations based on analyzed activities and overall training load.

read_resource

Read Strava resources exposed through MCP, such as activities, zones, clubs, and gear.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational
Strava MCP Server - rbctmz/mcp-server-strava | VeilStrat