I like tracking personal productive time and that includes when I’m doing some sort of workout activity. Tracking it manually though, that's not for me.
Previously, I had created and posted about a serverless function to automatically sync Fitbit workouts to Toggl.
This was all working well until I decided to ditch the Fitbit and start wearing an Apple Watch instead. Being in the Apple ecosystem the watch has many features that I enjoy.
The only problem being, Apple is very fussy about having stuff access your health data (I genuinely appreciate this). Which meant my existing function couldn’t be modified to sync my Apple Workouts to Toggl. Booo.
This was a bit of a bummer and I explored some options, unfortunately, all of the ways I could come up with required more time and effort than I was willing to put into it.
Fast forward a couple of months and Daniel tells me about Toolbox Pro during one of our Relatively Productive podcast recordings.
One of the things it can do (and there are many) is get your workout data securely and privately, locally on your device. Exactly what I wanted.
A couple of coffees later and my Sync Workouts Shortcut was ready.
I decided to have the Shortcut sync all workouts for the current day as that makes the most sense to me.
Get the Shortcut
If you would like to use it, you can download the Shortcut here:
- iOS 14 version (try this one first as it includes further improvements)
- iOS 13 version
You need to have Toolbox Pro installed on your device(s) running the Shortcut.
Then you need two things from your Toggl account to fill into the Shortcut when you import it. Don’t worry, this is a one-time setup.
First, go to https://toggl.com/app/profile and get your API token.
Then, you need a Toggl project ID for where you want the workouts to be tracked into. The project where you would manually track workouts, for example.
With the project selected on the Toggl website you can see the ID in the URL. Look for the numbers after
/edit/ in the address bar.
Finally, when you import the Shortcut you will be asked for your time zone offset from GMT/UTC. Enter this in a two-digit format. E.g. South Africa is GMT +2 so enter 02.
If you have a negative time zone offset check in the Shortcut for full instructions as you need to do an additional minor tweak.
With all the questions answered you should be good to go.
You are now ready to sync your Apple Workouts to Toggl using Siri Shortcuts! So simple.
Try playing around with the Shortcuts Automation to see if you can find a location or time-based trigger to automate the sync action.
I built the Shortcut so it won’t add the same workout to Toggl if it’s already there, so you can run the Shortcut as often as you like.
Let me know what you come up with.
Update: Seems like people really like the Shortcut with a common request to have a bit of back-sync from workouts to Toggl as well.
With that in mind, I've created a Back Sync Workouts Shortcut. It will sync the latest 100 workouts from the past 31 days to your specified Toggl project. It's meant to be run as a one-time task, so run with care as it does not check for existing Toggl time entries and will create duplicates.
Thanks for stopping by.