polar-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@polar-mcp show my Polar activities from April 1 to April 7"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
polar-accesslink
polar-accesslink is a shared Polar AccessLink core with two adapters:
polar-mcpfor LLM and MCP-compatible clientspolar-clifor cronjobs, exports, and simple automation
Current scope includes activities, cardio-load, and exercises.
Architecture
polar_accesslink.serviceandpolar_accesslink.clientcontain the shared core.polar_accesslink.mcp_serverexposes the core through MCP tools.polar_accesslink.cliexposes the same operations through a terminal command.
Related MCP server: Polar MCP
Supported Operations
activities_range(from_date, to_date, include_samples=false)activity_by_date(date, include_samples=false)cardio_load_recent(days=30)cardio_load_by_date(date)exercises_recent(include_samples=false, include_zones=false, include_route=false, include_tcx_metadata=false)exercise_by_id(exercise_id, include_samples=false, include_zones=false, include_route=false, include_tcx_metadata=false)
Both adapters return structured JSON envelopes:
status:ok|no_data|errorquerydatameta.generated_atmeta.sourcemeta.rate_limit
Requirements
Python
3.11+Polar AccessLink
access_tokenPolar AccessLink client credentials only if you use the one-time OAuth bootstrap helper
Quickstart
python3 -m venv .venv
source .venv/bin/activate
pip install -e .[dev]
export POLAR_ACCESS_TOKEN="your-access-token"MCP
polar-mcpCompatibility wrapper:
python3 run_polar_mcp.pyCLI
polar-cli activities-range --from-date 2026-04-01 --to-date 2026-04-07 --pretty
polar-cli exercises-recent --output jsonl --out data/exercises.jsonlMCP Configuration Example
{
"mcpServers": {
"polar": {
"command": "python3",
"args": ["/absolute/path/to/run_polar_mcp.py"],
"env": {
"POLAR_ACCESS_TOKEN": "your-access-token"
}
}
}
}Cron Example
0 6 * * * cd /absolute/path/to/polar-accesslink && . .venv/bin/activate && POLAR_ACCESS_TOKEN=your-access-token polar-cli exercises-recent --output json --out data/exercises.jsonOAuth Bootstrap Helper
polar_auth.py is now a thin wrapper over scripts/polar_auth.py, which remains a standalone one-time helper to:
Start a callback server on
127.0.0.1:3000Open Polar auth URL
Exchange code for token
Optionally register user with
POST /v3/users
Before running it, create a Polar AccessLink client and configure your redirect URL using the official Polar docs:
Example:
export POLAR_CLIENT_ID='your-client-id'
export POLAR_CLIENT_SECRET='your-client-secret'
export POLAR_REDIRECT_URI='http://127.0.0.1:3000/auth/polar/callback'
export POLAR_MEMBER_ID='your-member-id'
python3 polar_auth.pyMigration Notes
Python package changed from
polar_mcptopolar_accesslink.Distribution name changed from
polar-mcptopolar-accesslink.polar-mcpstays as the MCP executable.run_polar_mcp.pystays as a compatibility wrapper, but now imports the renamed module.New automation entrypoint:
polar-cli.If you have direct Python imports, cronjobs, or MCP configs pinned to old module paths, update them before upgrading.
Privacy And Publishing
Do not commit
.envfiles or real Polar credentials.Do not post raw workout exports (
.tcx,.fit,.gpx) publicly unless you are comfortable sharing that data.exercise_by_id(..., include_tcx_metadata=true)may surface workout titles and notes from your TCX export.
Known Limitations
activitiesare day-level summaries/samples, not workout-session objects.cardio-loadis read-only load status/history data.exerciseJSON does not expose workouttitle/notes.include_tcx_metadata=truemakes an extra TCX request per exercise to enrichtitleandnotes.TCX
titleis limited to 15 characters — the Garmin TCX XSD schema definesPlan/NameasRestrictedToken_t(maxLength=15). Polar truncates longer titles to comply with the spec. Thenotesfield (xsd:string) has no length limit. If you need full exercise descriptions, put them in the Notes field in Polar Flow.GPXdata is only available when an exercise has route data.
TODO
Add raw export helpers for
FITandGPXwhen needed.
Available Tools
6 toolstool_activities_rangeTool Activities RangeD
Inputs: to_date (required), from_date (required), include_samples. Returns: object
tool_activity_by_dateTool Activity By DateD
Inputs: date (required), include_samples. Returns: object
tool_cardio_load_by_dateTool Cardio Load By DateD
Inputs: date (required). Returns: object
tool_cardio_load_recentTool Cardio Load RecentD
Inputs: days. Returns: object
tool_exercise_by_idTool Exercise By IdD
Inputs: exercise_id (required), include_route, include_zones, include_samples, +1 more. Returns: object
tool_exercises_recentTool Exercises RecentD
Inputs: include_route, include_zones, include_samples, include_tcx_metadata. Returns: object
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 6 tools
The names suggest three resource groups (activity, cardio load, exercises), but there is no description to clarify the distinction between activity and exercise or the boundaries of date/range queries. An agent can likely choose based on name alone, but overlapping query patterns create some ambiguity.
All tools use snake_case and a consistent resource_action/qualifier structure with a uniform tool_ prefix. Minor inconsistency appears in singular/plural forms (activity vs activities, exercise vs exercises).
Six tools is well-scoped for a focused read-only integration covering activity, cardio load, and exercise queries. Each tool appears to earn its place without obvious redundancy.
The surface covers recent and dated activity/cardio load data plus exercise retrieval, but notable gaps remain: no activity detail by ID, no exercise date-range query, and no cardio-load range. These are workable but limit full lifecycle coverage.
Related MCP Connectors
Governed data discovery, exact queries, decisions, simulations, and runtime utilities over MCP.
Your Map My Tracks rides, runs and walks: activities, totals, zones and training load. Read only.
Access New Relic observability data through MCP - query metrics, logs, traces, entities, and more
Query workouts, browse exercises, and explore fitness data from BearTrail
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceProvides raw Garmin Connect data access for training analysis, enabling retrieval of activity summaries, lap data, time-series streams, comments with lactate, wellness metrics, and personal records through an MCP interface.MIT
- FlicenseNot gradedqualityDmaintenanceEnables users to query Polar health data (activity, sleep, recovery, training sessions, heart rate) through MCP with secure authentication, redacted personal info, and bounded responses.-
- AlicenseNot gradedqualityBmaintenanceEnables MCP clients to query and explore self-hosted Apple Health data, including daily metrics, time series, workouts, ECG records, heart notifications, sleep sessions, trends, freshness, and schema resources through authenticated streamable HTTP.MIT
- AlicenseAqualityBmaintenanceEnables MCP clients to read a user's own Rouvy activities, including summaries and per-second data for splits, selected time-window analysis, and downsampled streams; optionally exports FIT or CSV files when configured.1150 npmMIT