Endomondo will be shut down by Under Armor by the end of 2020. As if the year hasn't been bad enough... By March 2021 UA will pull the plug on Endomondo's data as well. Bye-bye workout history.
Of course there's a great option to keep that data: sign up for UA's app, consent to their less-than-GDPR-friendly terms, and sync away. But what if I don't want to do that? Then there's the option to send in a request to have your data exported to a zip file. Good luck with that- I tried several times and never got an answer.
Then there's third-party tools. Tapiriik, for example, is a great service meant to syc data between apps, Dropbox, and what have you. I've been using it forever to keep Endomondo and Runkeeper in sync. Unfornatunaly it's been broken for at least 6 months.
So - time to get creative. I found an excellent API handler for Endomondo. Go check it out.
To run that JavaScript goodness and get some actual data out of Endomondo we need Node; I went down the Docker-route to get that set up. Using the latest node image based on Alpine worked great. If you don't want to roll your own then here's the image on Docker Hub
I wasn't quite happy with the filenames generated by the API-handler's example script. So I took the liberty to rewrite that a bit (note: I'm everything but a JavaScript developer - but it works). The filenames now reflect the time of the workout, the activity, distance, durations and kcal's spent. I'm thinking about making an extra script to export all that into a csv; we'll see.
So: here's the fruit of my efforts. A app.js script that does the hard lifting and a dockerfile used to build your own shiny container (using the app.js file from this repository). Of course you can also use the one I already build in my own dockerhub.
The Docker image has 4 environmental variables you can use:
ENDO_USER
should be set yo your Endomondo username.ENDO_PASS
should be set yo your Endomondo password.ENV ENDO_PATH
is where your gpx files will be written to. It defaults to/root/endoexport/gpx
. Make sure you have map something local into our container in this directory so you can retrieve the actual files.TZ
will set your timezone. Europe/Amsterdam is the default (go Orange!)
The image is multi-architecture, so it should run on most machines, including your trusty Pi.
So here's an example:
docker run --detach --volume <my/local/path/gpx>:/root/endoexport/gpx --env ENDO_USER="you@whatever.com" --env ENDO_PASS="yourverysecretpassword" sjambor/endoexport