Showing posts from March, 2018

Working with the Strava API's Activity data

In my last post I described how to set up your Strava API, make a simple request to obtain your Strava user data and display it on a web page.  In this post I'm going to get into the more fun stuff: activity data.

There are two types of activity request, these are:

getLoggedInAthleteActivities: Returns a list of the logged in user's activities along with a summary of basic details for each of them such as distance, moving time, etc.getActivityById: Returns a single activity with a high level of detail, including segment efforts, photos, etcFor this post I'm going to describe the process for obtaining the list of athlete activities with basic level data.  You may be thinking 'if there's a way of getting all of the activity detail, why wouldn't we just do that?' to explain why I need to first explain what 'Rate Limits' are.
You may have seen this in your Strava App settings page:
What this means is that the amount of requests you may make to Strava for da…

Getting access to the Strava API

This post describes how you can get access to the Strava API so that you can build an application.

For this you will need some basic level of coding with HTML, CSS, Javascript and PHP as well as a web host that runs PHP.  If you would like my recommendation for a good free web host I use  You will also need a Strava Account.
Step 1. Create the application in StravaHead over to the strava developers page at and click the button that looks like this: 

From here you will log in to Strava (if not already logged in) and then to your settings page where you can enter the details required to set up your app.
I should do the right thing here and mention that you should read the Strava API Agreement before you go too much further with this, just to make sure that what you are creating doesn't go against any of the Terms of Use

At this point you are just creating a webpage for your own use for building and testing, so you don't need to enter any…