Skip to content
Decoding OTF Data
Share
Explore
Decoding OTF Data

icon picker
Ep 4: Data To Go

Entry Date:
7/23/2022

Idea

Based on , and ’s code, create a Coda doc to export data from Orangetheory without running Python script.

tl;dr

🟢 Copy , follow the instructions on the doc, and you can download your workout summary data as CSV.

Legend

💡 = Insight 🟢 = Do-able by anyone 🟡 = Hack by running Javascript via Chrome Debugger 🔴 = Hack that requires some level of Web coding experience

What’s next?

Build better visualization around exported data from Orangetheory.

Raw Notes

In theory, I can port the code over to Node, and then create a Coda pack out of it.
Hours passed by in coding, testing & verifying different approaches.
Couple of insights:
💡 It requires two calls to AWS Cognito endpoint to fetch memberUuid .
It’s not the worst, but workable.
💡 To fetch Treadmill and Rower data from Orangetheory, we’ll need to call the performance endpoint:
This endpoint provides a lot of information - Treadmill average speed, max incline, etc. I’m not going to explore this just yet - But the logic is setup to get it working.
💔 Coda’s Pack SDK does not allow you to connect to multiple domains at the same time - I’ve to request for permission.
I worked around this by splitting the authentication logic to one Pack ((Calling AWS Cognito service) from the Orangetheory API logic.
This is pretty bad from a Dev UX perspective, but workable for now.
💡 Coda allows you to download data directly from a table - This should really help OTFam who wants to explore data without running a single line of Python script.
💡 Ironically, OTF’s workout summary endpoint provides us with minute-by-minute heart rate, but it does not provide the same information when you call the workout details API.
I’ve to stitch it together .
There are a lot more I can do to make the visualization better. Maybe Episode 5.
OK. This is probably a good stopping point:
Created & published 2 OTF packs (Written for Coda’s Packs SDK & TypeScript)
OTF: Data Extractor -
Created a published doc, allowing OTFam to export data directly from Orangetheory’s API without running Python:

🎉 🎉 🎉 If you have read this far, check out all the related work other OTFam has done! 🎉 🎉 🎉
Jupyter (Google’s Colab):

Feedback? Got ideas? Found a bug?

Let me know on this .

Want to print your doc?
This is not the way.
Try clicking the ⋯ next to your doc name or using a keyboard shortcut (
CtrlP
) instead.