Create a new Strava API application
Then in .dev.vars
STRAVA_CLIENT_ID=<client_id>
STRAVA_CLIENT_SECRET=<client_secret>
// e.g. openssl rand -hex 32
AUTH_SECRET_KEY=<random_string>
rwsdk emulates cloudflare in development automatically with vite environments
pnpm run dev-
Change the name of the worker and optionally the domain in
wrangler.jsonc -
Create a KV namespace for sessions and update the
idinwrangler.jsonc
pnpm wrangler kv namespace create SESSIONS- Add secrets to prod
pnpm wrangler secrets put STRAVA_CLIENT_ID
pnpm wrangler secrets put STRAVA_CLIENT_SECRET
pnpm wrangler secrets put AUTH_SECRET_KEY- Then deploy
pnpm run releaseThe app exposes an MCP endpoint at /mcp that lets Claude access your Strava running data.
- Log in to your deployed app at least once (this seeds the MCP auth tokens)
- In Claude, go to Settings > Connectors > Add Connector
- Enter your app's MCP URL:
https://<your-domain>/mcp - Ask Claude things like "What are my running stats this week?" or "Show me my last 5 runs"
Available tools:
- get_stats — weekly mileage, easy pace, easy HR, longest run (7d/28d)
- get_runs — list of recent runs with distance, pace, HR, and workout tag
- get_run_detail — full details for a specific run including splits, weather, laps, and notes