Strava MCP Server

by r-huijts

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
STRAVA_CLIENT_IDYesYour Strava Application Client ID
ROUTE_EXPORT_PATHNoAbsolute path for saving exported route files
STRAVA_ACCESS_TOKENYesYour Strava API access token (generated during setup)
STRAVA_CLIENT_SECRETYesYour Strava Application Client Secret
STRAVA_REFRESH_TOKENYesYour Strava API refresh token (generated during setup)

Schema

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Tools

Functions exposed to the LLM to take actions

NameDescription
get-athlete-profile

Fetches the profile information for the authenticated athlete, including their unique numeric ID needed for other tools like get-athlete-stats.

get-athlete-stats

Fetches the activity statistics (recent, YTD, all-time) for a specific athlete using their ID. Requires the athleteId obtained from the get-athlete-profile tool.

get-activity-details

Fetches detailed information about a specific activity using its ID.

get-recent-activities

Fetches the most recent activities for the authenticated athlete.

list-athlete-clubs

Lists the clubs the authenticated athlete is a member of.

list-starred-segments

Lists the segments starred by the authenticated athlete.

get-segment

Fetches detailed information about a specific segment using its ID.

explore-segments

Searches for popular segments within a given geographical area.

star-segment

Stars or unstars a specific segment for the authenticated athlete.

get-segment-effort

Fetches detailed information about a specific segment effort using its ID.

list-segment-efforts

Lists the authenticated athlete's efforts on a specific segment, optionally filtering by date.

list-athlete-routes

Lists the routes created by the authenticated athlete, with pagination.

get-route

Fetches detailed information about a specific route using its ID.

export-route-gpx

Exports a specific Strava route in GPX format and saves it to a pre-configured local directory.

export-route-tcx

Exports a specific Strava route in TCX format and saves it to a pre-configured local directory.

get-activity-streams

Retrieves detailed time-series data streams from a Strava activity. Perfect for analyzing workout metrics, visualizing routes, or performing detailed activity analysis.

Key Features:

  1. Multiple Data Types: Access various metrics like heart rate, power, speed, GPS coordinates, etc.
  2. Flexible Resolution: Choose data density from low (100 points) to high (10000 points)
  3. Smart Pagination: Get data in manageable chunks or all at once
  4. Rich Statistics: Includes min/max/avg for numeric streams
  5. Formatted Output: Data is processed into human and LLM-friendly formats

Common Use Cases:

  • Analyzing workout intensity through heart rate zones
  • Calculating power metrics for cycling activities
  • Visualizing route data using GPS coordinates
  • Analyzing pace and elevation changes
  • Detailed segment analysis

Output Format:

  1. Metadata: Activity overview, available streams, data points
  2. Statistics: Summary stats for each stream type (max/min/avg where applicable)
  3. Stream Data: Actual time-series data, formatted for easy use

Notes:

  • Requires activity:read scope
  • Not all streams are available for all activities
  • Older activities might have limited data
  • Large activities are automatically paginated to handle size limits
get-activity-laps

Retrieves detailed lap data for a specific Strava activity.

Use Cases:

  • Get complete lap data including timestamps, speeds, and metrics
  • Access raw values for detailed analysis or visualization
  • Extract specific lap metrics for comparison or tracking

Parameters:

  • id (required): The unique identifier of the Strava activity.

Output Format: Returns both a human-readable summary and complete JSON data for each lap, including:

  1. A text summary with formatted metrics
  2. Raw lap data containing all fields from the Strava API:
    • Unique lap ID and indices
    • Timestamps (start_date, start_date_local)
    • Distance and timing metrics
    • Speed metrics (average and max)
    • Performance metrics (heart rate, cadence, power if available)
    • Elevation data
    • Resource state information
    • Activity and athlete references

Notes:

  • Requires activity:read scope for public/followers activities, activity:read_all for private activities
  • Returns complete data as received from Strava API without omissions
  • All numeric values are preserved in their original precision
get-athlete-zones

Retrieves the authenticated athlete's configured heart rate and power zones.

Output includes both a formatted summary and the raw JSON data.

ID: u4gauiqvik