Skip to content

MCP server

gymgym speaks the Model Context Protocol at https://gymgym.club/mcp (Streamable HTTP). Assistants sign in with OAuth 2.1 in the browser: the user picks one of their accounts and allows the app, and can remove it at any time in Settings → Connected apps. To use another account, connect again and pick it. Setup for Claude, ChatGPT, Codex and other clients is in CLI and AI agents.

The server is an OAuth-protected resource. A request without a valid token gets 401 with a WWW-Authenticate header pointing at its metadata; clients follow it, sign the user in and come back with a token bound to the server. These values are read from the running configuration:

Protected resource metadata /.well-known/oauth-protected-resource/mcp
Resource (token audience) https://gymgym.club/mcp
Authorization server https://gymgym.club/api/auth
Authorization endpoint https://gymgym.club/api/auth/oauth2/authorize
Token endpoint https://gymgym.club/api/auth/oauth2/token
Client ID Metadata Documents supported (preferred)
Dynamic client registration https://gymgym.club/api/auth/oauth2/register
PKCE S256 (required)
Grants authorization_code, refresh_token
Scopes openid, profile, email, offline_access
Token types Bearer, or DPoP-bound (EdDSA, ES256, ES512, PS256, RS256)

Access ends as soon as the user removes the app in Settings; tokens it still holds stop working on the next request. The OAuth endpoints are part of the Auth REST API.

Weights are in the account’s unit (kg or lb).

The account in use: weight unit (kg or lb), time zone and today’s date (read-only)

Show the settings, or change them: weight unit, default rest, effort rating per set, language, week start, rest timer, where planned sessions start

Parameter Type Description
unit? kg | lb Weight unit for everything read and written
rest? string Default rest between sets: “90”, “90s” or “1:30”
effort? off | rir | rpe Rate each set as reps in reserve or RPE
language? en | de | es | fr | it | pt | pt-BR | pl | tr | ru | uk | hu | zh | ko | hi | th | ar App language
weekStart? monday | sunday First day of the week
restTimer? boolean Automatic rest after each set
sessionStart? plan | last Planned sessions without progression start from the plan, or from that routine’s last session

The weekly plan (routine per weekday, null = rest) and all routines (read-only)

Put a routine on a weekday, or make it a rest day

Parameter Type Description
weekday string mon … sun
routine string Routine name, unique start of a name, or id; “rest” for a rest day

A day’s planned routine with the next target for every exercise (progression applied) (read-only)

Parameter Type Description
date? string YYYY-MM-DD; default today in the account time zone

One routine as a routine document (edit it and pass it to apply_routine) (read-only)

Parameter Type Description
routine string Routine name, unique start of a name, or id

Create a routine from a routine document, or replace the routine its “id” names. Returns the saved document.

Takes a whole routine document as its arguments; see Routine and workout documents.

Delete a routine; its weekdays become rest days and logged workouts stay (destructive)

Parameter Type Description
routine string Routine name, unique start of a name, or id

Logged workouts, newest first (read-only)

Parameter Type Description
from? string YYYY-MM-DD
to? string YYYY-MM-DD
limit? integer Default 20

One logged workout as a workout document (edit it and pass it to apply_workout to correct it) (read-only)

Parameter Type Description
workout string Workout id (or its start or end), a date YYYY-MM-DD, or “last”

Log a finished workout from a workout document, or correct the workout its “id” names. Returns the saved document and any new personal records.

Takes a whole workout document as its arguments; see Routine and workout documents.

Record sets of one exercise without a routine; they join that day’s “Quick log” workout

Parameter Type Description
exercise string Exercise id or name (see search_exercises)
sets string[] Like “80x5”, “x12”, “45s”, optionally “@8”
date? string YYYY-MM-DD; default today

Delete a logged workout (destructive)

Parameter Type Description
workout string Workout id (or its start or end), a date YYYY-MM-DD, or “last”

Save a body-weight reading in the account unit (one per day; a second one replaces it)

Parameter Type Description
weight number
date? string YYYY-MM-DD; default today

Body-weight readings of the last days, in the account unit, and the goal weight (read-only)

Parameter Type Description
days? integer Default 90

Search exercises by name (all terms must match): your own first, then the library (read-only)

Parameter Type Description
query string Words in the name, e.g. “incline dumbbell”
limit? integer
URI Description
gymgym://schema/routine JSON Schema of routine documents
gymgym://schema/workout JSON Schema of workout documents
gymgym://example/routine An example routine document
gymgym://example/workout An example workout document