# Strava MCP

> Strava MCP Server connects your AI agent to all your fitness data. Use natural language commands to pull workout metadata, track athlete stats over time, and manage routes without leaving your chat window. It reads every activity log, segment detail, and profile metric you need for training analysis.

## Overview
- **Category:** industry-titans
- **Price:** Free
- **Tags:** activity-tracking, fitness-data, workout-logs, athlete-stats, route-planning, health-metrics

## Description

Look, this isn't some basic dashboard connection. This server plugs your AI client right into every corner of your Strava data. You can run complex queries and manage your whole fitness history using nothing but natural language commands. It's built for people who need the deep dive—the kind of analysis that separates good training from killer training.

Before you do anything else, remember to kick things off with `test_strava_auth` to make sure your connection and access token are legit. After that, here’s what you can actually get done.

**Checking Your Numbers and Profile**
You gotta know who you are before you analyze the runs. Use `get_athlete_profile` to pull all your core biographical data. For a big picture of how you've been performing over time, `get_athlete_statistics` calculates and pulls those overall performance metrics for the athlete. You can also see what clubs you belong to by calling `list_athlete_clubs`, giving you a quick rundown of where you fit in your athletic community.

**Digging into Activity History**
To view past workouts, call `list_athlete_activities` and it spits out every completed activity log. If you want the nitty-gritty on one specific workout—like how far you went, your heart rate data, or that elevation gain—you use `get_activity_details`. You can then take that detailed info and make sure it's right by calling `modify_activity` to update key details for an entry. If you did a workout but forgot to hit record, don’t sweat it; just run `create_manual_activity` to log the new effort.

**Mapping Out Routes and Segments**
Planning your next session? You can get all your saved paths listed by running `list_athlete_routes`, and then use `get_route_details` for specific info on any route you plan to hit. For race segments—those intense little stretches that count against your PR—you've got options too. Call `list_starred_segments` to see all the favorite sections marked in your profile, or if you need the precise metrics and details for one of those key spots, just run `get_segment_details`. 

**In Short:** You can list every single segment you've saved using `list_starred_segments`, check out everything about your overall performance with `get_athlete_statistics`, or pull detailed stats on a specific workout. It handles the entire lifecycle of your training data, from logging and viewing to planning and tracking community engagement.

## Tools

### create_manual_activity
Adds a new workout activity that you didn't record on Strava.

### get_activity_details
Retrieves detailed information for a specific past workout.

### get_athlete_profile
Pulls your core profile and biographical data from Strava.

### get_route_details
Gets specific information about a saved route you plan to run.

### get_segment_details
Retrieves metrics and details for a specific race segment.

### get_athlete_statistics
Calculates and retrieves overall performance statistics for the athlete.

### list_athlete_activities
Generates a list of all your completed athletic activities.

### list_athlete_clubs
Lists the names and details of all the clubs you are joined to on Strava.

### list_athlete_routes
Retrieves a list of routes you have saved or created.

### list_starred_segments
Lists all the race segments you've marked as favorites.

### test_strava_auth
Verifies that the API connection and access token are working correctly.

### modify_activity
Updates key details for an existing workout entry in your log.

## Prompt Examples

**Prompt:** 
```
List my last 5 activities on Strava.
```

**Response:** 
```
I've retrieved your recent activities. Your last 5 workouts include a 'Morning Run' (5.2 km), 'Evening Cycle' (20.5 km), and three others. Would you like the detailed stats for the run?
```

**Prompt:** 
```
Show me my training summary for the past week with distance, elevation, and heart rate zones.
```

**Response:** 
```
Weekly training summary (May 12-18). 6 activities logged. Running (3): 28.4 km total, 342m elevation, avg pace 5:12/km, avg HR 152 bpm. Cycling (2): 89.6 km, 890m elevation, avg speed 28.4 km/h, avg HR 142 bpm. Swimming (1): 2.4 km, 45 minutes, avg pace 1:52/100m. Total distance: 120.4 km. Total time: 8h 23m. Calories: 5,670. HR zones: Zone 1 (12%), Zone 2 (34%), Zone 3 (28%), Zone 4 (18%), Zone 5 (8%). Training load: 4.2/5 (optimal). Fitness trend: +3% vs last week.
```

**Prompt:** 
```
Compare my running performance this month versus last month with pace and distance trends.
```

**Response:** 
```
Running comparison: May vs April. May (so far): 12 runs, 98.4 km, avg pace 5:08/km, best pace 4:32/km, elevation 1,230m. April: 14 runs, 112 km, avg pace 5:22/km, best pace 4:45/km, elevation 980m. Improvements: avg pace -14 sec/km (2.7% faster), best pace -13 sec/km. On track to exceed April distance (projected 118 km). Longest run: May 10.2 km vs April 8.8 km. Consistency: May avg 3.2 runs/week vs April 3.5. Heart rate efficiency improved: same pace at 5 bpm lower avg HR.
```

## Capabilities

### View Activity History
Lists all past athletic activities and retrieves detailed metadata like distance, heart rate data, and elevation gain.

### Check Athlete Stats
Accesses your profile and performance metrics to track overall progress over time.

### Analyze Specific Routes/Segments
Pulls detailed information on available routes or starred segments for training planning.

### Update Workout Logs
Creates or modifies activities programmatically, ensuring your training records are always current.

### Track Community Engagement
Lists the clubs you belong to, giving a clear overview of your athletic community participation.

## Use Cases

### Quickly summarizing a training block
You just finished a marathon training week and need to know the total distance, elevation, and average heart rate. Instead of opening Strava's dashboard and clicking through logs, you prompt your agent: 'Show me my summary for last week.' The agent runs `list_athlete_activities` and compiles all the necessary stats into a single report.

### Checking a segment difficulty before an event
You're planning a race on a new hill. You don't know how tough it is until you get there. Instead, you ask your agent to check the stats for that specific stretch using `get_segment_details`. The agent pulls up its metrics, letting you gauge if you need extra training time.

### Updating a forgotten workout
You ran 10 miles yesterday but forgot to hit the 'Start' button. You don't want to mess with the Strava mobile app. Instead, you use `create_manual_activity` in your chat and input the distance and estimated time. Your log is fixed instantly.

### Comparing current performance to past goals
You're trying to break a personal best pace. You ask: 'How is my average running pace this month compared to last quarter?' The agent runs `get_athlete_statistics` and provides a detailed comparison of your metrics, showing exactly where you improved.

## Benefits

- Get immediate workout insights. Instead of navigating to the Activity tab, you simply ask your agent for details on a specific run using `get_activity_details`. You get the data instantly.
- Track progress with minimal effort. Use `get_athlete_statistics` to monitor how your overall performance changes over time—it pulls all the necessary metrics into one summary.
- Plan training paths accurately. Need to know the elevation gain on a specific stretch? Ask the agent using `get_segment_details`. It gives you precise measurements for route planning.
- Keep records current. If you forget to log a workout, use `create_manual_activity` or `modify_activity` to update your profile without leaving your chat interface.
- See your whole network at once. Use `list_athlete_clubs` to keep track of community involvement and activity across all your joined groups.

## How It Works

The bottom line is, your AI client handles all the API calls; you just talk to it.

1. First, subscribe to this server and provide your Strava Access Token (OAuth2) in the developer settings.
2. Next, prompt your AI client. You tell it exactly what you need—for example: 'What was my average pace last month?'
3. The agent calls the relevant tool (`get_athlete_statistics`) and returns a structured summary of your performance metrics.

## Frequently Asked Questions

**How do I check if the Strava MCP Server is working?**
Run the `test_strava_auth` tool. This confirms your API connection and access token are valid, letting you know immediately if there's an issue before running complex queries.

**What does list_athlete_activities do?**
It pulls a comprehensive list of all the athletic activities recorded on your account. This is the starting point for getting any historical data.

**Can I get segment details using get_segment_details?**
Yes, `get_segment_details` retrieves specific metrics and information about a race segment you are interested in tracking or planning around.

**What's the difference between list_athlete_activities and get_activity_details?**
Listing activities (`list_athlete_activities`) gives you a summary of many workouts. Getting details (`get_activity_details`) requires you to specify one workout ID, giving you all the granular data for just that single run.

**How do I use get_athlete_statistics?**
You prompt your agent and ask for a comparison or summary (e.g., 'Compare my stats this month to last'). The agent uses `get_athlete_statistics` to calculate the metrics you need.

**What does `test_strava_auth` do?**
It verifies your API credentials and connection status. Running this tool confirms that your Strava Access Token works correctly with the server before you attempt any data retrieval or modification. This is always a good first step to ensure full connectivity.

**How does `modify_activity` update my workout info?**
`modify_activity` allows you to change existing activity records programmatically. You can correct inaccurate data, add notes, or adjust parameters for a specific logged session. This is useful when your manual log needs refinement after the fact.

**What does `list_athlete_clubs` show me?**
`list_athlete_clubs` retrieves a list of all clubs you are currently joined to on Strava. It gives you an immediate overview of your athletic community involvement and the names associated with those groups.

**How do I find my Strava Access Token?**
Log in to [**Strava Developers**](https://www.strava.com/settings/api), create an API application, and you will find your Access Token in the settings. Note that you may need to use the OAuth flow to generate a long-lived or refreshed token.