
Intervals Mcp
io.github.ljcl由 GitHub 帳號 ljcl 發布v2.19.0更新於 Nov 11, 2026
Remote MCP server for intervals.icu run data and analysis
概覽
單一使用者的遠端 MCP 伺服器,讓助理讀取並分析你在 intervals.icu 的跑步資料,並提供互動式 MCP Apps。
- 可以做什麼
- 讀取並分析 intervals.icu 的跑步紀錄與訓練資料
- 更新活動、健康(wellness)紀錄與裝備(僅較新用戶端支援寫入工具)
- 產生並儲存路線建議,可用本機 OpenStreetMap 索引計算過路次數
- 在文字工具之外提供互動式 MCP Apps
- 回報伺服器健康狀態與設定情形
- 適用情境
- 當你在 intervals.icu 記錄跑步,並希望助理幫你檢視訓練、調整活動或健康紀錄,或從常用起點推薦路線時使用。
- 執行需求
- 以本機 Docker 映像執行(也可用 Bun 從原始碼執行),透過 /mcp 端點的 Streamable HTTP 存取,通常需搭配 Tailscale Funnel 或 Cloudflare Tunnel 等 HTTPS 通道。需要 intervals.icu 個人 API 金鑰(INTERVALS_API_KEY);路線建議可選 ORS_API_KEY,過路統計需 OSM_EXTRACT_URL 與 HOME_START,保護端點可設 MCP_AUTH_TOKEN。
安裝
在 SourceWeft 中
- 開啟 儀表板中的 Intervals Mcp,將其新增到工作區。
- 為需要使用其工具的對話啟用該服務。
Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。
其他 MCP 客戶端
參照 儲存庫 中的啟動說明。
README
Intervals Extra (intervals-mcp)
[CI] [Storybook] [License: MIT]
A single-user remote MCP server for intervals.icu run data and analysis, with interactive MCP Apps.
All text tools and every MCP App talk to intervals.icu directly and
are verified against a real account; see docs/tools.md for
the full catalog. Configuration is checked at startup: a bad variable stops
the server with a message naming it, and the key's presence is reported on
/health.
History. This project began as strava-mcp and was migrated to intervals.icu as its data source; nothing in the server talks to Strava today.
Setup
1. Get an intervals.icu API key
- Log in to intervals.icu
- Go to Settings, Developer Settings
- Copy your personal API key
2. Configure environment
Edit .env with your values:
All variables are listed in docs/operations.md.
3. Run it
Local development (needs Bun):
Docker:
Prefer the prebuilt image? Pull ghcr.io/ljcl/intervals-mcp:latest, the
newest release (also on the
MCP registry as
io.github.ljcl/intervals-mcp), and point your compose image: at it instead
of building; you still supply your own API key. :edge tracks unreleased
main. Published images carry SBOM/provenance attestations you can verify; see
operations.md.
GET /health reports liveness without spending an intervals.icu API request;
with MCP_AUTH_TOKEN it also reports config and rate-limit state. Response
shapes and monitoring guidance: operations.md.
Point any client at http://localhost:3000/mcp. Repo layout, task runner,
tests, coverage gates, and Storybook workflow: docs/development.md.
Agent conventions live in AGENTS.md.
Connecting to AI Tools
Most AI tools (Claude Desktop, Claude Code, etc.) need an HTTPS URL to reach your MCP server. Since the server runs on your local network, you'll need a tunnel to expose it.
Tailscale Funnel (Recommended)
Tailscale Funnel exposes a local port to the internet over HTTPS with no configuration:
Set PUBLIC_URL in your .env to the resulting URL.
Cloudflare Tunnel
Securing the endpoint
A tunnel makes /mcp reachable by anyone who discovers the URL, so they can
use the intervals.icu API key configured on the server (the key itself is
never exposed to them). Set MCP_AUTH_TOKEN to a
long random secret (openssl rand -hex 32) and every /mcp request requires
Authorization: Bearer <token>; each client snippet below shows where the
header goes. The secret also gates the detailed half of /health. Full
details: operations.md.
Set it in .env alongside your API key; docker-compose.yml forwards it
automatically.
Client configuration
The server works with any MCP client that supports the Streamable HTTP
transport. In every snippet below, replace https://your-public-url with
your tunnel URL (or http://localhost:3000 for local development), and
include the Authorization header only if you set MCP_AUTH_TOKEN.
Claude Desktop
Add to your Claude configuration
(~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
Restart Claude Desktop to load the new configuration.
Claude Code
Cursor
Add to .cursor/mcp.json in your project (or ~/.cursor/mcp.json for all projects):
VS Code
Add to .vscode/mcp.json in your workspace (or run MCP: Add Server from the command palette):
Other clients (generic Streamable HTTP)
Any client that speaks Streamable HTTP can connect to the /mcp endpoint directly. The endpoint serves the 2026-07-28 revision: clients send stateless requests carrying the io.modelcontextprotocol/* envelope keys and the Mcp-Method/Mcp-Name headers (server/discover advertises capabilities). A 2025-era client (one that opens with initialize) is served statelessly too, because claude.ai loads MCP Apps that way, but it gets no write tool: update-activity, update-wellness and update-gear need a 2026-07-28 client. POST JSON-RPC messages with an Accept: application/json, text/event-stream header. Protocol details: docs/architecture.md.
Tools
The full tool catalog, prompts, permission behaviour, and example requests live in docs/tools.md. All text tools and every MCP App's data handler talk to intervals.icu directly.
Documentation
PRs are squash-merged and the PR title becomes the commit on main, so write it as a Conventional Commit (fix: patch, feat: minor, any ! or BREAKING CHANGE: footer major; chore:/docs:/refactor:/ci: release nothing). A CI check rejects non-conforming titles; see docs/releasing.md.
Troubleshooting
Server exits at startup: The message names the variable to fix, one line per bad variable. See operations.md.
AI tool can't reach the server — MCP requires an HTTPS URL. Use a tunnel (Tailscale Funnel or Cloudflare Tunnel) to expose your local server. See Connecting to AI Tools.
API key errors: Check /health first: api_key_configured tells you whether the server has a key set at all. If api_key_configured is true but calls still fail, the key may be wrong or revoked; generate a new one at intervals.icu, Settings, Developer Settings, and update INTERVALS_API_KEY. See operations.md.
Today's run is missing, or dates are a day off: Check time_zone and time_zone_source on /health. With TZ unset (or UTC), the server uses your intervals.icu time zone; set TZ to choose one. See operations.md.
"Cloudflare … answered with a challenge": Cloudflare, in front of intervals.icu, stopped the request before it reached intervals.icu, so this is not an API key problem. Wait a few minutes and retry. See operations.md.
Client can't connect (401 or unsupported protocol version): Each refused /mcp request writes one mcp_rejected line to the server log with its status, JSON-RPC code and, when the client sent it, its name. A 401 means the bearer token is missing or wrong. Code -32022 means the client's envelope names an MCP revision the server does not serve. See operations.md.
Is the server up and reachable? curl https://your-public-url/health. It answers without touching the intervals.icu API, so it works even when your rate limit is exhausted.
Client re-prompts for read tools after I granted them — A release likely renamed a tool or changed its input schema; grants are stored per tool identity, so that drops the grant. Releases say so in the changelog. Otherwise persistence lives in the client — check both connector-level and per-tool settings. See docs/tools.md.
License
MIT
來源:README.md,提交 6b6d990
工具
0版本歷史
15- v2.19.0最新Nov 11, 2026
- v2.17.1Nov 8, 2026
- v2.17.0Nov 8, 2026
- v2.16.0Nov 7, 2026
- v2.12.0Nov 3, 2026
- v2.9.3Nov 1, 2026
- v2.9.2Oct 29, 2026
- v2.7.0Oct 10, 2026
- v2.5.1Oct 9, 2026
- v2.4.0Oct 9, 2026
- v2.3.0Oct 5, 2026
- v2.2.0Oct 5, 2026
- v2.1.1Sep 27, 2026
- v2.0.0Sep 26, 2026
- v0.2.0Sep 26, 2026
評分
已滿足適用檢查項的 50%
該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。
- 近 30 天內可連通25 分
請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。
- 已宣告認證方式10 分
請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。
- 已列出工具15 分
請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。
- 描述必需15 分
- 圖示10 分
- 文件15 分
- 授權條款10 分