Hevy MCP Server
Provides tools for managing workout data through the Hevy API, including creating and updating workouts, managing routine folders, accessing exercise templates, and configuring webhook subscriptions for fitness tracking.
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., "@Hevy MCP Servershow my recent workouts"
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.
hevy-api-mcp
MCP server for the Hevy API
Installation
Clone the repository and navigate to the directory:
git clone https://github.com/jcjiron/hevy-mcp.git cd hevy-mcpInstall dependencies and build:
npm install npm run build
Related MCP server: hevy-mcp
Usage with npx
You can run the MCP server using npx (locally or globally, if published to npm):
npx hevy-api-mcpOr from your MCP config:
{
"mcpServers": {
"hevy-api-mcp": {
"command": "npx",
"args": ["-y", "hevy-api-mcp"],
"env": {
"HEVY_API_KEY": "<YOUR_API_KEY>"
}
}
}
}Environment variables
HEVY_API_KEY: Your Hevy API key (required).
You can use a .env file for local development:
HEVY_API_KEY=your_api_keyExposed tools
Raw 1:1 API wrappers:
getWorkouts, getWorkoutById, createWorkout, updateWorkout
getRoutineFolders, getRoutineFolderById, createRoutineFolder
getRoutines, getRoutineById, createRoutine, updateRoutine
getExerciseTemplates, getExerciseTemplateById
getWebhookSubscription, createWebhookSubscription, deleteWebhookSubscription
Catalog-scale tools, for operating on many routines at once without blowing past an agent's context window or risking silent data loss on a routine's sets/weights/reps (see Catalog operations below):
listRoutines— the whole routine catalog in one call, with a size-controlled projection (summary/exercises/structure/sets)getExerciseTemplatesByIds— batch-resolve exercise template IDs instead of onegetExerciseTemplateByIdcall per IDpatchRoutine— change a routine's title/notes or specific exercise fields without resending the whole routinesetRoutineSupersets— regroup a routine's exercises into supersets in one callexportRoutines/importRoutines— back up routines to a local file and restore them; runexportRoutinesbefore any bulk changemoveRoutineToFolder— always returns{ unsupported: true }(see below)listDeletionCandidates— finds routines with identical structure (likely duplicates) for manual review; there is nodeleteRoutine
What the Hevy API doesn't support
Confirmed against the API's OpenAPI spec, not guessed:
No
DELETEfor routines or routine folders. There is no way to delete a routine or a folder through the API.listDeletionCandidatesidentifies likely duplicates for you to remove by hand in the app.PUT /v1/routines/{id}does not acceptfolder_id. A routine can't be moved between folders without recreating it under a new ID (which loses its history), somoveRoutineToFolderrefuses to do that automatically and just reportsunsupported.A routine's own
notesfield is write-only.GETresponses for a routine never include it, onlyPOST/PUTaccept it.patchRoutineandimportRoutinescan't round-trip it — if you don't passnotesexplicitly, it's left out of the request rather than guessed at.pageSizefor/v1/routinesmaxes out at 10 server-side.listRoutines/exportRoutines/listDeletionCandidatespage through this internally so callers never have to.
Catalog operations (v2)
getRoutines/updateRoutine mirror the Hevy API 1:1: reading the full
catalog means paging through it yourself, and writing means resending a
routine's entire exercise/set payload even to change one field. That's
fine for one routine, but breaks down at real scale (tested against a
77-routine, ~1,400-set catalog): downloading everything to answer "what
routines do I have" cost ~760KB of JSON where the answer needed about 7%
of that, and a naive rename-by-resend risks dropping a weight or a
custom_metric value nobody meant to touch - or, if the payload is built
by spreading validated input instead of an explicit allowlist, sending a
field the Routines API doesn't recognize at all (rep_range/rpe belong
to workout sets; POST/PUT /v1/routines reject them outright with a
400 per set, which is exactly what happened here before it was fixed).
The tools above exist to make that safe:
listRoutinesnever returns more than the projection you asked for.patchRoutineandsetRoutineSupersetsread the current routine server-side and merge your change in, so every field you didn't mention survives the round trip unchanged (weights included, down to full floating-point precision — the source is never rounded, only the JSONlistRoutinesreturns for display is). Both are all-or-nothing: if an exercise match is ambiguous, or one of the routine's exercises isn't covered by any group, nothing is written and you get an error naming the problem.Both support
dryRun: trueto preview the exact write body first.exportRoutinesis the safety net for all of the above — run it before any bulk change so a bad edit can be reverted withimportRoutines.
Usage example
You can test the server locally:
HEVY_API_KEY=your_api_key npx hevy-api-mcpOr using the .env file:
npx hevy-api-mcpFor questions or suggestions, open an issue in the repository.
This server cannot be deployed
Maintenance
Related MCP Connectors
Create Hevy routines and analyze your training from chat. Unofficial; BYO Hevy PRO API key.
Training analytics over your Hevy log: e1RM, PRs, volume, consistency, bodyweight.
Read your workouts, history, and stats; create and schedule new workouts. Writes are additive only.
Manage fitness coaching clients, workouts, programs, chats and funnels from your assistant.
Related MCP Servers
- AlicenseNot gradedqualityFmaintenanceEnables AI assistants to interact with the Hevy fitness tracking API for logging workouts, managing routines, and tracking fitness progress.10 npm32MIT
- AlicenseBqualityDmaintenanceEnables AI agents to interact with the Hevy Workout Tracker API to manage workouts, routines, exercises, and user data.2310 npmMIT
- AlicenseNot gradedqualityDmaintenanceExposes the Hevy workout API to Claude, enabling users to manage workouts, routines, exercise templates, body measurements, and user info via natural language.53,090 npmMIT
- AlicenseNot gradedqualityBmaintenanceEnables AI assistants to interact with the Hevy fitness tracking API, allowing users to log workouts, manage routines, browse exercises, and track fitness progress through natural language.10 npmMIT