Integrating Strava’s API

After lots of experimentation and several errors later, I managed to successfully integrate Strava’s API into my website. The official documentation can be found here –, for further support I used this PHP specific Github repository (

When users register to my site they are directed to this page stating when their chosen plan starts as well as the link to connect to Strava…

Screen Shot 2016-05-27 at 21.36.20

Logging in to Strava will then direct users to this authorisation page. If the user accepts the authorisation, their Strava access token is stored in my database and I am able to access their activity data…Screen Shot 2016-05-27 at 21.38.21

I access users Strava data at the end of each week, comparing their weekly total to the required total of selected plan. If users run enough then they receive a tip and can progress to the next week. However, if not, they are prompted to run more! From feedback, my target audience preferred that it checks at the end of the week rather than each day, as this allows users more flexibility with the training.

Screen Shot 2016-05-27 at 21.39.49Screen Shot 2016-05-27 at 21.45.20

Snippet of my integration of Strava’s API:

Screen Shot 2016-05-31 at 12.23.56.png