How to Connect Gemini to TrainingDojo MCP
Add TrainingDojo as a Gemini Spark custom app with browser sign-in; advanced users can also configure Gemini CLI.
Eligible Gemini Spark users can add TrainingDojo as a custom app in Gemini on the web. Gemini handles TrainingDojo sign-in; Google requires manual confirmation for write actions. Gemini CLI remains an advanced alternative.
Before You Connect
- An active TrainingDojo Pro subscription.
- At least one platform connected in Settings.
- The TrainingDojo MCP endpoint:
https://trainingdojo.app/api/mcp.
Your TrainingPeaks, Intervals.icu, and Strava credentials stay encrypted in TrainingDojo and are never sent to the AI app. The normal browser flow does not require you to create or handle a developer key. The AI app and provider you choose handle all conversation inference and generation under your provider account. TrainingDojo MCP never calls TrainingDojo's AI models or uses TrainingDojo AI credits. TrainingDojo receives authenticated tool inputs and returns data or action results, not the rest of your provider conversation. TrainingDojo's separate web AI features remain TrainingDojo-hosted.
Connect TrainingDojo to Gemini Web
Before starting, confirm all of these requirements:
- An eligible Gemini Spark account on a personal Google account.
- You are 18 or older, in the US, and using Gemini in English.
- Keep Activity is turned on in Gemini settings.
- You are completing setup in the Gemini web app.
- Open Settings & help → Connected Apps.
- Under Custom apps for Spark, choose Add a custom app.
- Paste
https://trainingdojo.app/api/mcp, choose Next, then sign in and approve access.
Google currently limits custom apps to eligible Gemini Spark users who are 18+, in the US, using English, a personal Google account, and Keep Activity turned on. You add the app on the web; once connected, Google says it can be used in Gemini Spark on the web and mobile.
Advanced: Connect TrainingDojo to Gemini CLI
Generate a developer key in the Advanced section of MCP setup, then put it in an environment variable so the literal value is not saved in shell history:
# macOS or Linux
export TRAININGDOJO_MCP_KEY="<your-trainingdojo-key>"
gemini mcp add --transport http \
--scope user \
--header "Authorization: Bearer $TRAININGDOJO_MCP_KEY" \
trainingdojo https://trainingdojo.app/api/mcpIn PowerShell, use:
$env:TRAININGDOJO_MCP_KEY = "<your-trainingdojo-key>"
gemini mcp add --transport http --scope user --header "Authorization: Bearer $env:TRAININGDOJO_MCP_KEY" trainingdojo https://trainingdojo.app/api/mcpGemini expands the header and stores it in your user-level ~/.gemini/settings.jsonfile. User scope keeps the key out of a project's shareable .gemini/settings.json, but the user settings file is still sensitive: protect it, never commit or share it, and revoke the developer key from TrainingDojo when you no longer need it.
Verify the Connection
gemini mcp listThe server should show as connected. Inside Gemini CLI, use /mcp list or/mcp schema to inspect the tools. Leave trust disabled so Gemini asks before running tools, especially calendar writes and deletions.
A Useful First Coaching Session
Start with a read-only check before asking the AI to write anything:
Use TrainingDojo to list my connected platforms. Then review my last
six weeks of training and my next 14 days. Summarize volume, intensity,
recovery signals, and the three biggest risks in my current schedule.
Do not change or publish anything yet.Once the summary looks right, ask for a draft plan, review its dates and workload, and only then approve a publish tool. TrainingDojo labels read, write, and destructive tools; the AI client controls whether and when it asks for approval, so review that client's permission settings before enabling writes.
Why Gemini CLI Works Well for This
- Streamable HTTP and custom authorization headers are supported directly.
- The CLI exposes connection status and tool schemas for straightforward troubleshooting.
- Default tool confirmations provide a useful safety boundary around writes.
- User scope keeps this account-level connection out of project configuration.
Troubleshooting
- 401: the key is missing, malformed, or revoked.
- 403: the TrainingDojo account does not have an active Pro subscription.
- 429: the operational MCP safety limit was reached; wait and retry.
- No platform data: reconnect the source in TrainingDojo Settings.
Frequently Asked Questions
What settings does a Gemini custom app require?
Gemini custom apps currently require an eligible Gemini Spark account, Keep Activity turned on, and setup in the Gemini web app. Google may ask you to confirm write actions manually.
Does Gemini CLI support the TrainingDojo authentication header?
Yes. Gemini CLI supports Streamable HTTP MCP servers and custom headers, including an Authorization bearer token.
Should I enable Gemini CLI trust for TrainingDojo?
Leave trust disabled initially. Default confirmation prompts provide a useful safety checkpoint before platform writes, updates, or deletions.
How do I verify the connection?
Run gemini mcp list, then use /mcp list or /mcp schema inside Gemini CLI to inspect the server and its tools.