Skip to main content
Glama
mvilanova

Intervals.icu MCP Server

by mvilanova

add_or_update_event

Create or modify workout events in Intervals.icu by specifying activity details, structured workout steps, and athlete data for training management.

Instructions

Post event for an athlete to Intervals.icu this follows the event api from intervals.icu If event_id is provided, the event will be updated instead of created.

Many arguments are required as this MCP tool function maps directly to the Intervals.icu API parameters.

Args: athlete_id: The Intervals.icu athlete ID (optional, will use ATHLETE_ID from .env if not provided) api_key: The Intervals.icu API key (optional, will use API_KEY from .env if not provided) event_id: The Intervals.icu event ID (optional, will use event_id from .env if not provided) start_date: Start date in YYYY-MM-DD format (optional, defaults to today) name: Name of the activity workout_doc: steps as a list of Step objects (optional, but necessary to define workout steps) workout_type: Workout type (e.g. Ride, Run, Swim, Walk, Row) moving_time: Total expected moving time of the workout in seconds (optional) distance: Total expected distance of the workout in meters (optional)

Example: "workout_doc": { "description": "High-intensity workout for increasing VO2 max", "steps": [ {"power": {"value": "80", "units": "%ftp"}, "duration": "900", "warmup": true}, {"reps": 2, "text": "High-intensity intervals", "steps": [ {"power": {"value": "110", "units": "%ftp"}, "distance": "500", "text": "High-intensity"}, {"power": {"value": "80", "units": "%ftp"}, "duration": "90", "text": "Recovery"} ]}, {"power": {"value": "80", "units": "%ftp"}, "duration": "600", "cooldown": true} {"text": ""}, # Add comments or blank lines for readability ] }

Step properties: distance: Distance of step in meters {"distance": "5000"} duration: Duration of step in seconds {"duration": "1800"} power/hr/pace/cadence: Define step intensity Percentage of FTP: {"power": {"value": "80", "units": "%ftp"}} Absolute power: {"power": {"value": "200", "units": "w"}} Heart rate: {"hr": {"value": "75", "units": "%hr"}} Heart rate (LTHR): {"hr": {"value": "85", "units": "%lthr"}} Cadence: {"cadence": {"value": "90", "units": "rpm"}} Pace by ftp: {"pace": {"value": "80", "units": "%pace"}} Pace by zone: {"pace": {"value": "Z2", "units": "pace_zone"}} Zone by power: {"power": {"value": "Z2", "units": "power_zone"}} Zone by heart rate: {"hr": {"value": "Z2", "units": "hr_zone"}} Ranges: Specify ranges for power, heart rate, or cadence: {"power": {"start": "80", "end": "90", "units": "%ftp"}} Ramps: Instead of a range, indicate a gradual change in intensity (useful for ERG workouts): {"ramp": True, "power": {"start": "80", "end": "90", "units": "%ftp"}} Repeats: include the reps property and add nested steps {"reps": 3, "steps": [ {"power": {"value": "110", "units": "%ftp"}, "distance": "500", "text": "High-intensity"}, {"power": {"value": "80", "units": "%ftp"}, "duration": "90", "text": "Recovery"} ]} Free Ride: Include free to indicate a segment without ERG control, optionally with a suggested power range: {"free": true, "power": {"value": "80", "units": "%ftp"}} Comments and Labels: Add descriptive text to label steps: {"text": "Warmup"}

How to use steps: - Set distance or duration as appropriate for step - Use "reps" with nested steps to define repeat intervals (as in example above) - Define one of "power", "hr" or "pace" to define step intensity

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
workout_typeYes
nameYes
athlete_idNo
api_keyNo
event_idNo
start_dateNo
workout_docNo
moving_timeNo
distanceNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions the conditional create/update behavior based on event_id, which is useful. However, it doesn't describe important behavioral aspects like authentication requirements (though it mentions API key fallback), error handling, rate limits, or what happens on success/failure. The extensive step documentation compensates somewhat but focuses more on parameter usage than tool behavior.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is excessively long and poorly structured for an AI agent. While the parameter and step documentation is valuable, it should be more front-loaded with core purpose and usage, with detailed examples moved to a separate section. The current structure buries the essential information in lengthy examples and step property listings, making it inefficient for quick comprehension.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the complexity (9 parameters, nested workout_doc structure) and 0% schema coverage, the description provides substantial context. It thoroughly documents parameters and includes a rich example. With an output schema present, it doesn't need to explain return values. The main gap is lack of behavioral context like error conditions or authentication requirements, but the parameter coverage is comprehensive.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 0% schema description coverage, the description must fully compensate, which it does excellently. It provides detailed explanations for all 9 parameters, including optionality, default values, and environmental fallbacks. The extensive documentation of workout_doc structure, step properties, and usage examples adds significant semantic value beyond what the bare schema provides, making parameter understanding comprehensive.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Post event for an athlete to Intervals.icu' with the conditional update behavior when event_id is provided. It specifies the resource (event/athlete) and the action (post/update). However, it doesn't explicitly differentiate from sibling tools like 'get_event_by_id' or 'delete_event' beyond mentioning the update condition.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides minimal usage guidance. It mentions that if event_id is provided, the event will be updated instead of created, which gives some context for when to use it for updates versus creation. However, it doesn't explain when to use this tool versus alternatives like 'delete_event' or 'get_events', nor does it mention prerequisites or typical use cases beyond the technical mapping to the API.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/mvilanova/intervals-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server