Beeminder Forum

Python script reading Strava updating Beeminder via API


#1

So I now have a script that uses my very basic Beeminder Python (version 3) module and the Stravalib module to get my runs and rides from Strava and update 2 separate Beeminder goals (cycle 50 miles per week and run 5k per week).

It correctly uses the StravaId in the Beeminder RequestID so that you don’t get duplicate rides however many times you load them.

Many things still to do.

  • lots of code tidy up
  • hardcoded to look at last 15 activities (even though I won’t have that many that are new I do go back and update names of activities).
  • currently hardcoded to use KM for runs and Miles for Rides
  • needs to support ride counting as well as distance counting goals
  • needs a proper strava application id
  • needs a web page for the strava application
  • needs web page to handle strava authorisation for a user

Questions:

  1. Anyone else interested in running this themselves (puts you in control of getting data into beekeeper rather than the convoluted and slow garmin -> tapiriik -> runkeeper -> beeminder)?

  2. I’d be happy to look at adding stuff needed so that it could be included directly in beeminder if the team are interested and want to tell me what is needed.

  3. What other Strava stuff would people be interested in getting into Beeminder. For example weight? (my strava weight gets updated from garmin and would save me from needing to send the weight to fitbit for beeminder). Or time (to support goal to run for 1h a week?)

Code is at https://github.com/davew/bee42 under an Apache 2 license.


#2

Resurrecting this thread to say thanks so much for building and sharing this, Dave! And also to say that we now have:

Official Strava Integration!


If there's anything this script can/could do that the official integration doesn't, we definitely want to hear about that!

#3

I know :slight_smile: and I’m using the official integration. It is working well for me :slight_smile: