Skip to main content
Glama
Intervals.icu MCP Server

Intervals.icu MCP Server

by jakub-m-arch

Intervals.icu MCP Server

CI License: MIT

A Model Context Protocol (MCP) server for Intervals.icu. It lets Claude and other MCP-compatible AI assistants read your training data and help you plan training.

WARNING

Pre-1.0. Tools and output formats may still change between minor versions. See the roadmap below.

Quick start

You need an Intervals.icu API key: Settings → Developer Settings → Generate API key.

Client

Install

Claude Desktop

One-click .mcpb bundle from the latest release

Claude Code

claude mcp add

Cursor, VS Code

JSON config with npx

Any MCP client

npx -y @jakub-m-arch/intervals-icu-mcp (stdio), or the Docker image

Every client needs Node.js ≥ 22.12 for the npx route, except the .mcpb bundle (Claude Desktop ships its own Node) and Docker.

Claude Desktop

Download intervals-icu-mcp.mcpb from the latest release and open it (or drag it into Settings → Extensions). Claude Desktop asks for your API key and stores it securely; write mode and toolsets are optional fields with safe defaults.

Prefer a manual config? Open Settings → Developer → Edit Config and add:

{
  "mcpServers": {
    "intervals-icu": {
      "command": "/absolute/path/to/npx",
      "args": ["-y", "@jakub-m-arch/intervals-icu-mcp"],
      "env": { "INTERVALS_ICU_API_KEY": "your-key" }
    }
  }
}

Use the absolute path to npx (see which npx). Claude Desktop does not inherit your shell's PATH, so a plain "npx" often fails, especially with nvm. Quit the app (Cmd+Q) and start it again to load the server.

Claude Code

claude mcp add intervals-icu -e INTERVALS_ICU_API_KEY=your-key -- npx -y @jakub-m-arch/intervals-icu-mcp

Cursor

Add to ~/.cursor/mcp.json (or .cursor/mcp.json in a project):

{
  "mcpServers": {
    "intervals-icu": {
      "command": "npx",
      "args": ["-y", "@jakub-m-arch/intervals-icu-mcp"],
      "env": { "INTERVALS_ICU_API_KEY": "your-key" }
    }
  }
}

VS Code

Add to .vscode/mcp.json (or run MCP: Open User Configuration). VS Code prompts for the key once and keeps it out of the file:

{
  "inputs": [
    { "type": "promptString", "id": "intervals-key", "description": "Intervals.icu API key", "password": true }
  ],
  "servers": {
    "intervals-icu": {
      "type": "stdio",
      "command": "npx",
      "args": ["-y", "@jakub-m-arch/intervals-icu-mcp"],
      "env": { "INTERVALS_ICU_API_KEY": "${input:intervals-key}" }
    }
  }
}

Docker

docker run -i --rm -e INTERVALS_ICU_API_KEY=your-key ghcr.io/jakub-m-arch/intervals-icu-mcp

Use it as the command (docker) with run -i --rm -e INTERVALS_ICU_API_KEY … as args in any of the configs above. The image is multi-arch (amd64 and arm64).

TIP

Want to look around first without any risk of changes? SetINTERVALS_ICU_WRITE_MODE=read-only in env.

NOTE

This is an independent open-source project. It isnot affiliated with, endorsed by, or sponsored by Intervals.icu.

Related MCP server: garmin-mcp

Goals

  • Full API coverage without flooding the model's context. Tools are hand-designed and grouped into toolsets you can switch on or off.

  • Typed from the source. The API client is generated from the official Intervals.icu OpenAPI spec. CI detects when the spec changes.

  • Runner-friendly output. Pace is shown in min/km or min/mi, together with GAP, zones and durations that are easy for humans to read.

  • Safe by default. Delete operations are only available when you enable them explicitly.

  • Works locally and remotely. stdio for Claude Desktop, Claude Code, Cursor and similar clients; later, Streamable HTTP with OAuth for claude.ai on web and mobile.

Tools

47 tools: 42 in the default toolsets, and 5 opt-in via INTERVALS_ICU_TOOLSETS (e.g. default,raw). All 149 Intervals.icu API operations are accounted for: 48 have dedicated tools, 49 more can be read through api_get, and 52 are deliberately excluded with a documented reason. See docs/coverage.md and the generated tool reference in docs/tools.md.

Toolset

Read

Write (safe, default)

Delete (full only)

athlete

get_athlete_profile, get_fitness_summary

activities

list_activities, search_activities, get_activity, list_activity_comments

update_activity, create_manual_activity

delete_activity

analysis

get_activity_streams, get_activity_histogram, get_activity_best_efforts, get_activity_segment_stats, search_intervals

curves

get_athlete_curves

wellness

get_wellness

update_wellness

calendar

list_events, get_event

create_events, update_event, mark_event_done, duplicate_events, apply_plan

delete_events

library

list_workout_library, get_workout, get_training_plan

create_folder, update_folder, create_workouts, update_workout, duplicate_workouts

delete_workout, delete_folder

gear

list_gear

create_gear, update_gear, add_gear_reminder, update_gear_reminder

delete_gear, delete_gear_reminder

settings (opt-in)

update_sport_settings, apply_sport_settings

chats (opt-in)

add_activity_comment

raw (opt-in)

list_api_endpoints, api_get (any read endpoint)

Prompts (ready-made analysis templates; see how to use them): weekly-review, analyze-activity, recovery-check, plan-next-week, race-prep.

Resources: intervals://athlete/profile, intervals://guides/workout-syntax.

Safety

  • Tools outside the write mode are not registered at all. In the default safe mode, the assistant can create and edit, but cannot delete. Set INTERVALS_ICU_WRITE_MODE=read-only to only read, or full to also allow deletions.

  • Tools are annotated as read-only, write or destructive, so MCP clients can ask before running them.

  • Planned workouts are checked after saving. The server reports how Intervals.icu parsed the workout text and warns about common mistakes, e.g. 400m means 400 minutes.

  • create_events skips duplicates: entries with the same date, category and name.

  • Delete tools resolve every id first. If any id is unknown, nothing is deleted.

Configuration

Variable

Required

Default

Description

INTERVALS_ICU_API_KEY

yes

–

Intervals.icu → Settings → Developer Settings

INTERVALS_ICU_ATHLETE_ID

no

0

0 means the owner of the API key

INTERVALS_ICU_TOOLSETS

no

default

Comma-separated toolsets, default or all

INTERVALS_ICU_WRITE_MODE

no

safe

read-only, safe (create/update) or full (also delete)

--athlete-id, --toolsets and --write-mode CLI flags override the environment variables. The API key can only be set through the environment, because command-line arguments are visible to other processes. Details: docs/configuration.md.

Running from source

To run an unreleased version, build the server locally and point your client at dist/index.mjs instead of npx:

git clone https://github.com/jakub-m-arch/intervals-icu-mcp.git
cd intervals-icu-mcp
npm install && npm run build
claude mcp add intervals-icu -e INTERVALS_ICU_API_KEY=your-key -- node "$PWD/dist/index.mjs"

Try it without an AI client: npm run inspect opens the MCP Inspector, where you can call each tool by hand. It reads the API key from .env.

Everyday use

See docs/usage.md. It covers a daily and weekly routine (recovery check, session analysis, weekly review), planning workouts that sync to your watch, and troubleshooting.

Roadmap

Version

Scope

0.1

Foundation: typed API client, config, first tools (athlete profile, activities, fitness)

0.2

Core read tools: activity analysis, curves, wellness, calendar, workout library, gear

0.3

Safe writes: plan workouts on the calendar, manage the workout library, log wellness

0.4

Full API coverage via opt-in toolsets, coverage report, weekly spec-drift PRs

1.0

Stable release: npm, MCP Bundle for Claude Desktop, MCP Registry, Docker image

1.x

Remote mode: Streamable HTTP with Intervals.icu OAuth

Development

Requirements: Node.js ≥ 22.12 (see .nvmrc).

npm install
npm run check      # lint + typecheck + tests + build
npm run inspect    # open the server in the MCP Inspector (reads .env)
npm run test:live  # read-only smoke tests against the real API (needs .env)

See CONTRIBUTING.md, docs/development.md (tests, releases) and docs/architecture.md for details.

License

MIT

Available Tools

36 tools
add_gear_reminderAdd a gear reminderA

Add a replacement or maintenance reminder to gear, e.g. "replace shoes after 600 km". Set at least one limit.

Inputs: name (required), gear_id (required), days, hours, +2 more. Returns: gear

apply_planPut a training plan on the calendarA

Copy all workouts of a training plan from the library (a PLAN folder, see list_workout_library) onto the calendar, starting on a date. Each workout lands on start date + its plan day. Adds many events: confirm the plan and start date first.

Inputs: plan_id (required), start_date (required). Returns: plan, workouts, start_date

create_eventsAdd events to the calendarA

Add planned workouts, races, notes or holidays/sickness to the athlete calendar (up to 50 per call). Planned workouts sync to the athlete's watch when their device integration is enabled. Show the plan to the user and get agreement before calling. An entry with the same date, category and name as an existing one is skipped unless allow_duplicates is true. Check workout_check in the result and fix any warnings with update_event.

Workout text syntax (Intervals.icu): one step per line starting with "- ", e.g. "- 10m Z2 Pace", "- 1.5km 7:00/km Pace", "- 90s 85% Pace", "- 10m Ramp 60-80% HR", "- 5m Z2 HR". Durations: 30s, 90s, 1m30, 10m, 1h. Distances: 400mtr (meters!), 1.5km, 2mi — "400m" means 400 MINUTES. Repeats: a line ending in "Nx" (e.g. "Main set 4x") followed by its steps, then a blank line. Section lines like "Warmup"/"Cooldown" are labels. Text before the duration labels a step ("- Strides 20s Z5 Pace"). Power (rides): "75%" (of FTP), "200w", "150-180w", "Z2". Bpm ranges like "140-150bpm" are NOT supported; use HR zones or % HR.

Inputs: events (required), allow_duplicates. Returns: created, skipped

create_folderCreate a library folder or planA

Create a folder (or a training plan) in the workout library to hold reusable workouts.

Inputs: name (required), kind, description. Returns: folder

create_gearAdd gearB

Add gear such as a new pair of running shoes, optionally with distance already covered. Activities are linked to gear by the device sync or manually in Intervals.icu.

Inputs: name (required), type (required), notes, purchased, +1 more. Returns: gear

create_manual_activityLog a manual activityA

Log an activity that was not recorded by a device (e.g. a treadmill run without a watch). Today or past dates only. It counts towards training load; confirm details with the user first.

Inputs: date (required), name (required), type (required), duration (required), +5 more. Returns: activity

create_workoutsAdd workouts to the libraryA

Save reusable workouts in a library folder or plan (up to 50 per call). Check workout_check in the result and fix warnings with update_workout.

Workout text syntax (Intervals.icu): one step per line starting with "- ", e.g. "- 10m Z2 Pace", "- 1.5km 7:00/km Pace", "- 90s 85% Pace", "- 10m Ramp 60-80% HR", "- 5m Z2 HR". Durations: 30s, 90s, 1m30, 10m, 1h. Distances: 400mtr (meters!), 1.5km, 2mi — "400m" means 400 MINUTES. Repeats: a line ending in "Nx" (e.g. "Main set 4x") followed by its steps, then a blank line. Section lines like "Warmup"/"Cooldown" are labels. Text before the duration labels a step ("- Strides 20s Z5 Pace"). Power (rides): "75%" (of FTP), "200w", "150-180w", "Z2". Bpm ranges like "140-150bpm" are NOT supported; use HR zones or % HR.

Inputs: workouts (required), folder_id (required). Returns: created

duplicate_eventsRepeat events in later weeksA

Copy calendar events to later weeks, e.g. repeat this week's workouts for the next 3 weeks. Confirm with the user first.

Inputs: ids (required), copies (required), weeks_between. Returns: created

duplicate_workoutsRepeat plan workouts in later weeksA

Copy workouts inside a training plan to later weeks of the plan, e.g. repeat week 1 for weeks 2–4.

Inputs: ids (required), copies (required), weeks_between. Returns: created

get_activityGet activity detailsA
Read-onlyIdempotent

Get details of one activity: summary metrics, description, time in heart-rate and pace zones, aerobic decoupling, HR recovery, fitness/fatigue after the session and, optionally, the list of intervals/laps with pace and HR. Activity ids look like "i123456789" (see list_activities).

Inputs: id (required), include_raw, include_intervals. Returns: raw, activity, intervals

get_activity_best_effortsFind best efforts in an activityA
Read-onlyIdempotent

Find the best efforts inside one activity: fastest pace over a distance (e.g. best 1 km), highest average heart rate or power over a duration (e.g. best 5 min). Returns when each effort happened. For all-time or period bests across activities use get_athlete_curves.

Inputs: id (required), metric (required), count, distance_m, +1 more. Returns: metric, target, efforts

get_activity_histogramGet activity time distributionA
Read-onlyIdempotent

Get how much time was spent at each heart rate, pace or power level in one activity (a histogram with ranges, time and % of total). Finer-grained than time in zones.

Inputs: id (required), metric (required), bucket_size. Returns: metric, buckets

get_activity_segment_statsGet stats for part of an activityA
Read-onlyIdempotent

Get pace, heart rate, cadence and intensity for a chosen part of an activity, e.g. "from 10:00 to 20:00". Use it to compare the first and second half or a climb.

Inputs: id (required), end (required), start (required). Returns: end, start, stats

get_activity_streamsGet activity time seriesA
Read-onlyIdempotent

Get second-by-second data of one activity (heart rate, pace/speed, cadence, altitude, distance, power), downsampled to a compact table: each row averages a time window. Use it to analyse pacing, HR drift or how effort changed during the session. GPS coordinates are only included when "latlng" is requested explicitly.

Inputs: id (required), end, start, types, +1 more. Returns: rows, columns, rows_count, activity_id, +2 more

get_athlete_curvesGet personal bests curvesA
Read-onlyIdempotent

Get personal bests for a sport over one or more periods: best times and paces at standard distances (pace), or highest average heart rate / power for standard durations. Pace curves include critical speed, a good estimate of threshold pace. Use it for PRs, race predictions and fitness progress (compare periods such as 42d vs 1y).

Inputs: metric (required), sport, periods, distances_m, +1 more. Returns: sport, curves, metric

get_athlete_profileGet athlete profileA
Read-onlyIdempotent

Get the athlete profile: time zone, units, weight, resting HR and per-sport settings (threshold HR/pace/power and training zones). Use it to interpret zones and paces or before planning workouts.

Inputs: no named parameters. Returns: sports, athlete

get_eventGet calendar eventA
Read-onlyIdempotent

Get one calendar event (planned workout, race or note) by id, including the full workout description.

Inputs: id (required). Returns: event

get_fitness_summaryGet fitness, fatigue and formA
Read-onlyIdempotent

Get training fitness (CTL, 42-day load), fatigue (ATL, 7-day load) and form (TSB = fitness − fatigue) with the Intervals.icu form zone, a daily series, and weekly totals by sport. Defaults to the last 6 weeks. Use it for questions about training load, freshness or trends.

Inputs: newest, oldest. Returns: daily, weekly, current

get_training_planGet current training planA
Read-onlyIdempotent

Get the training plan the athlete is currently following (if any): plan name, start date and its workouts by day.

Inputs: no named parameters. Returns: plan, active, start_date, last_applied

get_wellnessGet wellness and recovery dataA
Read-onlyIdempotent

Get daily wellness data: resting HR, HRV, sleep (duration, score), weight, steps, readiness and subjective ratings (soreness, fatigue, stress, mood, motivation on the Intervals.icu 1–4 scales), plus period averages. Defaults to the last 14 days. Use it for recovery and readiness questions.

Inputs: newest, oldest. Returns: days, range, averages

get_workoutGet library workoutA
Read-onlyIdempotent

Get one workout from the library, including its steps in Intervals.icu text format.

Inputs: id (required). Returns: workout

list_activitiesList activitiesA
Read-onlyIdempotent

List completed activities (runs, rides, etc.) in a date range, newest first, with distance, time, pace/GAP, heart rate and training load, plus totals per activity type. Defaults to the last 30 days. Use get_activity for details of one activity.

Inputs: type, limit, newest, oldest. Returns: count, range, truncated, activities, +1 more

list_activity_commentsList activity commentsA
Read-onlyIdempotent

List comments and notes (e.g. from a coach or the athlete) on one activity.

Inputs: id (required). Returns: comments

list_eventsList calendar eventsA
Read-onlyIdempotent

List calendar entries: planned workouts (with the workout steps as text), races, notes, holidays, sickness and injuries. Defaults to today and the next 2 weeks. Use it to see what is planned or to compare the plan with completed activities.

Inputs: newest, oldest, categories, include_descriptions. Returns: count, range, events

list_gearList gearA
Read-onlyIdempotent

List gear such as running shoes and bikes with accumulated distance, time and number of activities, plus maintenance/replacement reminders (e.g. shoes at 600 km).

Inputs: type, include_retired. Returns: gear

list_workout_libraryList workout libraryA
Read-onlyIdempotent

List the athlete's workout library: folders and training plans with their workouts (name, sport, duration, load). Use get_workout for the steps of a workout.

Inputs: folder_id. Returns: folders

mark_event_doneMark a planned workout as doneA

Mark a planned workout as completed without a recorded file: creates a manual activity matching the plan (for sessions done without a watch). Only for today or past dates.

Inputs: id (required). Returns: activity

search_activitiesSearch activitiesA
Read-onlyIdempotent

Search all activities by name (case-insensitive substring) or by tag (start the query with #, e.g. "#race"). Use it to find specific sessions regardless of date.

Inputs: query (required), limit. Returns: count, activities

search_intervalsFind workouts with matching intervalsA
Read-onlyIdempotent

Find past activities containing intervals of a given duration and intensity, e.g. "4–6 minute reps at 95–105% of threshold". Intensity is % of threshold (FTP, threshold pace or LTHR depending on the metric).

Inputs: max_intensity (required), min_intensity (required), max_duration_s (required), min_duration_s (required), +3 more. Returns: count, activities

update_activityUpdate an activityA
Idempotent

Edit a completed activity: name, description/notes, sport type, perceived exertion (RPE), feel, tags, or race/commute flags. Only the fields you pass are changed.

Inputs: id (required), rpe, feel, name, +5 more. Returns: activity

update_eventUpdate a calendar eventA
Idempotent

Change a calendar event: move it to another date, rename it, or rewrite the workout steps. Only the fields you pass are changed. Confirm the change with the user first.

Workout text syntax (Intervals.icu): one step per line starting with "- ", e.g. "- 10m Z2 Pace", "- 1.5km 7:00/km Pace", "- 90s 85% Pace", "- 10m Ramp 60-80% HR", "- 5m Z2 HR". Durations: 30s, 90s, 1m30, 10m, 1h. Distances: 400mtr (meters!), 1.5km, 2mi — "400m" means 400 MINUTES. Repeats: a line ending in "Nx" (e.g. "Main set 4x") followed by its steps, then a blank line. Section lines like "Warmup"/"Cooldown" are labels. Text before the duration labels a step ("- Strides 20s Z5 Pace"). Power (rides): "75%" (of FTP), "200w", "150-180w", "Z2". Bpm ranges like "140-150bpm" are NOT supported; use HR zones or % HR.

Inputs: id (required), date, name, time, +7 more. Returns: event

update_folderRename a library folderC
Idempotent

Rename a workout library folder or plan, or change its description.

Inputs: id (required), name, description. Returns: id, name, description

update_gearUpdate or retire gearA
Idempotent

Rename gear, change its notes, or retire it (e.g. worn-out shoes; then add the new pair with create_gear). Only the fields you pass are changed.

Inputs: id (required), name, notes, retired. Returns: gear

update_gear_reminderReset, snooze or change a gear reminderA

Reset a gear reminder after doing the maintenance (starts counting again), snooze it, or change its limits.

Inputs: gear_id (required), reminder_id (required), days, name, +3 more. Returns: gear

update_wellnessLog wellness dataA
Idempotent

Log or correct wellness data for one day: weight, resting HR, HRV, sleep, subjective ratings and comments. Only the fields you pass are changed. Measurements (weight, HR, HRV, sleep) cannot be removed once set, only overwritten; ratings are cleared with 0 and comments with "".

Inputs: date (required), mood, steps, injury, +11 more. Returns: day

update_workoutUpdate a library workoutA
Idempotent

Change a library workout (name, steps, sport, folder). Only the fields you pass are changed.

Workout text syntax (Intervals.icu): one step per line starting with "- ", e.g. "- 10m Z2 Pace", "- 1.5km 7:00/km Pace", "- 90s 85% Pace", "- 10m Ramp 60-80% HR", "- 5m Z2 HR". Durations: 30s, 90s, 1m30, 10m, 1h. Distances: 400mtr (meters!), 1.5km, 2mi — "400m" means 400 MINUTES. Repeats: a line ending in "Nx" (e.g. "Main set 4x") followed by its steps, then a blank line. Section lines like "Warmup"/"Cooldown" are labels. Text before the duration labels a step ("- Strides 20s Z5 Pace"). Power (rides): "75%" (of FTP), "200w", "150-180w", "Z2". Bpm ranges like "140-150bpm" are NOT supported; use HR zones or % HR.

Inputs: id (required), day, name, tags, +4 more. Returns: workout

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.7/5.0

    Scored across 36 tools

    Disambiguation5/5

    Each tool targets a distinct resource and action: list/search/get/update on activities, calendar events, and library workouts are clearly separated, and the analytics tools (streams, histogram, best efforts, segment stats) each have unique outputs. Even near-pairs like create_events vs create_workouts and create_manual_activity vs mark_event_done are disambiguated by their descriptions.

    Naming Consistency5/5

    Tool names follow a consistent snake_case verb_noun pattern (list_*, get_*, create_*, update_*, duplicate_*), with only minor multi-word variants like mark_event_done and add_gear_reminder that remain predictable. The naming convention makes it easy to anticipate what each tool does.

    Tool Count2/5

    36 tools is beyond the 25+ threshold for 'too many' in the calibration, making this a heavy tool set even though the server covers a broad training platform. Many tools are narrow and could be consolidated (e.g. activity analytics) or omitted for a more focused MCP surface.

    Completeness3/5

    The set covers most core workflows across athlete profile, activities, calendar planning, workout library, wellness, and gear, with read/create/update operations for most resources. However, there are no delete tools for activities, events, workouts, or folders, leaving lifecycle dead ends and making the CRUD coverage incomplete.

    Maintenance

    ActivitySlowing
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers