openGym MCP Bridge
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., "@openGym MCP Bridgeshow me my recent workouts and current plan"
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.
openGym MCP Bridge
A community-maintained, self-hosted MCP bridge for openGym. This is not an official openGym project.
Reads the openGym account through its supported web/API interface and a dedicated paired token.
Offers MCP tools for status, plan/history reads, official exercise-name search, guarded plan changes, and guarded historical workout logging.
Supports confirmed, preview-first writes when
OPENGYM_ALLOW_WRITES=1.Ships as a Docker image through GitHub Actions and GitHub Container Registry (GHCR).
This project is experimental. Back up your openGym data and inspect every write preview before confirming it.
Docker image
ghcr.io/nirvana-z777/opengym-mcp-bridge:0.3.1The image is built from this repository by .github/workflows/publish-image.yml. Pushing to main publishes the main tag. Pushing a version tag such as v0.3.1 publishes 0.3.1 and latest. GitHub Actions runs npm test before publishing.
Images target linux/amd64. Pin 0.3.1 for a release deployment; main tracks development and latest tracks the most recent stable release. The Dockerfile contains runtime source, package metadata and the MIT license; test fixtures and local configuration are excluded from its build context.
Related MCP server: garmin-mcp
Security first
Never commit or bake any of the following into the repository or image:
secrets/,opengym-token.json,mcp-access-token,openai-runtime-key.env, personal tunnel IDs/configuration, personal IP addresses or private workout exportsstore/or other user data
The repository ignores local secret/data paths. The Docker build context also excludes them. Keep the Bridge behind the Docker network and do not publish its MCP port directly to the Internet. The example Compose file does not map a host port.
Quick deployment reference
Copy
.env.exampleto.envand setOPENGYM_BASE_URLto the openGym address reachable from the Bridge container.Copy
docker-compose.example.yamlto your localdocker-compose.yaml.Create
secrets/andstore/locally. Pair the Bridge with openGym using its supported pairing flow; never paste pairing codes or tokens into public issues.If using OpenAI Secure MCP Tunnel, copy
tunnel-client.example.yamlto the localtunnel-client.yaml, replace the tunnel ID, and place the restricted runtime key and Bridge token in the expected files undersecrets/.Keep
OPENGYM_ALLOW_WRITES=0until you are ready to use the write tools. When enabled, every write still requires a short-lived preview and explicit confirmation.Deploy with Docker Compose. The Bridge uses the GHCR image, not
build: ..
The example files are templates, not a ready-to-run configuration. Do not publish your locally customized .env, docker-compose.yaml, tunnel-client.yaml, or secrets/.
MCP tools
Read-only tools include get_status, get_summary, get_plan, get_recent_workouts, and search_exercises. Writes are preview-first: preview_plan_change / apply_plan_change and preview_workout_log / log_workout. The apply/log tools are hidden when OPENGYM_ALLOW_WRITES is not 1.
Historical workout logging accepts real recorded dates and actual per-set data. For each set, provide exactly one of reps or seconds; do not invent unknown dates, weights, repetitions, or durations.
Local development
Requires Node.js 22 or newer. The bridge has no npm runtime dependencies.
npm ci --ignore-scripts
npm test
npm startAll test identities, pairing codes, dates, body weights and per-set values are deliberately synthetic. Tests use mocked clients or temporary local files and never read personal secrets or contact a real openGym account. CI rejects a test run that executes zero tests. MCP initialization reports the version from package.json.
Release process
Update the version in
package.json, regeneratepackage-lock.jsonwithnpm install --package-lock-only --ignore-scripts, and update the pinned image in this README anddocker-compose.example.yaml.Run
npm testlocally.Commit and push to
mainto publish amainimage for testing.Create and push a tag such as
v0.3.2to publish0.3.2andlatest. CI verifies that the tag matchespackage.json; a failed test prevents publication.After the first package publication, set the GHCR package visibility to Public in the package settings if GitHub created it as private by default.
The workflow authenticates with the automatically provided GITHUB_TOKEN. Its test job has contents: read; only the publishing job also receives packages: write. No PAT, runtime API key, pairing token or tunnel credential is required for image publication. Actions are pinned to reviewed commit SHAs; update those pins when adopting an upstream release.
After making the package public, verify a pull without stored registry credentials on a machine with Docker:
anonymous_config=$(mktemp -d)
docker --config "$anonymous_config" pull --platform linux/amd64 ghcr.io/nirvana-z777/opengym-mcp-bridge:0.3.1
docker --config "$anonymous_config" pull --platform linux/amd64 ghcr.io/nirvana-z777/opengym-mcp-bridge:latest
rmdir "$anonymous_config"License
MIT. See LICENSE.
This server cannot be deployed
Maintenance
Related MCP Connectors
Read your workouts, history, and stats; create and schedule new workouts. Writes are additive only.
Remote MCP server for training, nutrition, wellness, and performance data with OAuth 2.0.
- MyoAmigoOAuthcom.myoamigo
Agent-first strength-training platform across iOS, Web & MCP: read & write workouts, PRs & plans.
Authenticated MCP for a user's care circle: read CareEvents, list loved ones, inspect workspace.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceEnables MCP clients like Codex and Claude Code to securely read and manage a personal Cronometer account, including food logs, nutrient summaries with missing-data awareness, food search, biometrics, and export analysis.MIT
- AlicenseAqualityBmaintenanceEnables creating, previewing, scheduling, and managing Garmin Connect workouts, plus reading activities and health metrics, all through a local MCP server.11MIT
- AlicenseNot gradedqualityBmaintenanceEnables MCP clients to connect to a privacy-first, self-hostable workout planning and training log, allowing coaching agents to preview and apply program changes while accessing training data through OAuth-protected endpoints.AGPL 3.0
- AlicenseNot gradedqualityCmaintenanceEnables querying a Tonal fitness account for workout history with per-set weights, muscle readiness, strength scores, and lifetime stats through a remote MCP endpoint.MIT