
Automating Personalised Fitness Feedback with n8n, Strava & OpenAI
What if your Strava workouts could talk back?
Table Of Content
- 💡 The Vision: AI Coaching on Autopilot
- ⚙️ How It Works – A Tour of the Workflow
- 1️⃣ Telegram Trigger – Share Your Strava Link
- 2️⃣ Activity Type Check – Filter for What Matters
- 3️⃣ Get & Format Metrics
- 🧠 The Brain: The Fitness Coach AI Agent
- 📜 Full AI Agent Prompt
- 📤 Output: Telegram Delivery with Coaching Structure
- 📝 Example Output
- 🔮 What’s Next?
- ⚠️ Disclaimer: This Isn’t a Strava Replacement
- 💬 Final Thoughts
- 📩 Want to Try It or Build Your Own?
I’ve built a personalised AI coaching system that takes your running, cycling, or stand-up paddleboarding (SUP) data and transforms it into a fully tailored performance breakdown — complete with training insights, motivational tips, and next steps — all automated using n8n, Strava, Telegram, and OpenAI.
This post walks through how it works, what it does, and how you can build your own version or steal some ideas for your own setup.
💡 The Vision: AI Coaching on Autopilot
This all started with a simple goal: I wanted more than just numbers on Strava — I wanted context.
What does a good cadence mean?
Was my power consistent?
Should I be doing intervals next time?
Am I improving?
Coaching services exist, sure, but they’re often expensive, generic, or limited to a single sport. So I built my own system: a virtual triathlon coach that lives inside a Telegram chat, ready to analyse my Strava activities in seconds and return proper coaching feedback — structured, motivational, and actionable.
⚙️ How It Works – A Tour of the Workflow
Here’s the full n8n flow in action:
Let’s walk through it step-by-step:
1️⃣ Telegram Trigger – Share Your Strava Link
It all begins with a Strava link sent to a Telegram bot.
Since Strava share links often come in redirect format (strava.app.link/...
), the flow handles:
Extracting the final URL and resolving redirects
Pulling the Activity ID
Starting the main logic with the correct ID
2️⃣ Activity Type Check – Filter for What Matters
The system is built to analyse Rides, Runs, and SUP sessions — and ignore everything else.
Once the Activity ID is pulled, I grab the full activity details from Strava’s API and check the activity type. If it’s a meditation or stretching session, the bot gently says, “No coaching needed today 😉” and exits.
3️⃣ Get & Format Metrics
Next up: the real data. I pull key metrics like:
Distance, time, elevation gain
Pace/speed, cadence, power, heart rate
Device used, terrain, effort level
A code node then formats the metrics into a structured JSON payload, prepped for the OpenAI API.
🧠 The Brain: The Fitness Coach AI Agent
This is the heart of the whole system: a custom GPT agent that acts like a real-world coach.
It analyses your activity with nuance and domain-specific insight — it knows the difference between:
Open-water vs. flatwater SUP
FTP intervals vs. groove rides
Road running vs. trails
Casual rides vs. power-building sessions
📜 Full AI Agent Prompt
Here’s the core of what I pass to the AI:
You are a Triathlon Coach specializing in guiding the athlete on running, stand up paddle boarding, and cycling. Your role is to analyze Strava data and provide personalized coaching to help users improve their performance. Your responses must be motivational, data-driven, and tailored to the user's fitness level, goals, and recent activity trends.
### Key Abilities:
1. **Analyse Activity Data**
- Metrics: distance, pace, heart rate, power, cadence, stroke rate (SUP)
- Identify trends, strengths, and inefficiencies
2. **Provide Feedback**
- Break down performance by pacing, cadence, stroke rhythm, technique
- Highlight achievements and improvement areas
3. **Create Improvement Plans**
- Recommend workouts, recovery plans, drills
- Tailored to user's sport, terrain, and goals
4. **Set Goals and Challenges**
- Suggest short- and long-term objectives
- Weekly/monthly motivational challenges
5. **Motivational Coaching**
- Encourage, reinforce, and help avoid burnout
6. **Environmental Context Awareness**
- Differentiate between flatwater vs. open water SUP
- Adjust advice for wind, elevation, terrain, surface
7. **Cross-Discipline Insights**
- Brick workouts (e.g., SUP + Run)
- Balance recovery between sports
### Inputs You Will Receive:
- Strava activity data (JSON)
- User profile, fitness level, goals (optional)
### Output Format:
- **Performance Summary**
- **Insights**
- **Recommendations**
- **Motivation & Next Steps**
Use clear language, actionable advice, and explain reasoning. Avoid generic praise — make it specific and useful.
This ensures the output sounds like it’s coming from a knowledgeable, human coach — not a generic AI.
📤 Output: Telegram Delivery with Coaching Structure
Once OpenAI returns the result, the n8n flow:
Structures the response into Markdown
Formats it cleanly for Telegram
Sends it as a message to the user
No clunky UI. No fluff. Just a direct message with tailored coaching.
📝 Example Output
Here’s a real response I got from a 20-minute Peloton Groove Ride:
Performance Summary:
Distance: 9.94 km
Avg Power: 142.1 watts
Max Power: 437 watts
Avg Cadence: 83.7 rpm
Calories Burned: 229 kcal
Insights:
Solid cadence for endurance
Power spikes show short, intense efforts
Pacing improved through the ride
Recommendations:
Try 3×12-minute FTP intervals
Add 30-second cadence bursts
Check bike fit if fatigue is creeping in
Motivation & Next Steps:
Great foundation building! Layer in structured cadence drills and tempo blocks to build power and pedaling efficiency.
Honestly — it’s better than some human coaching I’ve paid for in the past.
🔮 What’s Next?
Here’s what I’m planning to explore next:
⚡ Auto-trigger after a Strava workout
I’ll likely use a webhook to trigger the flow immediately after a workout is logged — removing the Telegram step entirely.🌦 Add weather data to SUP sessions
Historical weather APIs can pull wind speed, temperature, and conditions at the exact time of the workout. I’ll feed this into the AI prompt and optionally update the Strava activity description with it.🗃️ Store all responses in a database + build a frontend
I’d love to build a dashboard to track performance trends over time, review old AI feedback, and visually compare sessions.
This could evolve into a proper virtual training platform.
⚠️ Disclaimer: This Isn’t a Strava Replacement
Just to be clear: this is not designed to replace or circumvent Strava Premium.
Strava Summit offers excellent features — live segments, advanced metrics, and great training tools. This project is simply a personal experiment in enhancing the way I use my data, using tools I already love.
Think of it like building your own bike computer — but for coaching feedback.
💬 Final Thoughts
This project scratches a lot of itches: fitness, data, automation, and fun. It’s something I actually use, and it makes my training more reflective, intentional, and motivating.
If you’re a fellow data geek with a Garmin watch and a GitHub repo full of half-finished automation scripts, this one’s for you.
📩 Want to Try It or Build Your Own?
Let me know! I can share:
The n8n JSON export
The exact OpenAI Agent setup
Weather data integration tips
Or just brainstorm cool features with you
Drop me a Strava link and I’ll show you what your AI coach thinks 😉
Please share this article if you like it!
I’m a fitness enthusiast and Peloton addict who loves challenging limits through races, paddleboarding, and life’s adventures. Here, I share milestones, reflections on Acoustic Neuroma, and stories of resilience and growth.
No Comment! Be the first one.