This is the code for a very early (and not very efficient) Windows Phone 7.5 project for viewing Strava data.  Hoping that Strava will create a new API to return all segments for a given athlete which will speed this up no end.  Please bear in mind that this was my first WP7 app and I'm not really a C# coded!

I've moved my spare-time focus to a web based site offering similar functionality which can be found here: http://stravaviewer.com

The API's used in this app (and the website) are those found here Strava API documentation and those you can discover using Fiddler when accessing the Strava website.  The only APIs used that require authentication are the ones for ride map data although I think there are other APIs available that might return that without requiring authentication.  One of my fundamental principles for these projects (mainly the website) was to not make publicly available any data that requires authentication.

If you want to try out the source code then you'll need to change a number of currently hard-coded values for those authenticated calls to work.  They can be found at around line 1600 in MainViewModel.cs.  Change the values to match your details. The plan was to prompt the user for login and store these details based on that but I didn't get round to that:

IsolatedStorageSettings.ApplicationSettings["username"] = "username";            IsolatedStorageSettings.ApplicationSettings["userId"] = 0;            IsolatedStorageSettings.ApplicationSettings["email"] = "name@co.com";            IsolatedStorageSettings.ApplicationSettings["password"] = "pwd";            IsolatedStorageSettings.ApplicationSettings["token"] = "token";

The "token" value can be got using the authenticate API listed in the Strava API documentation.

These values are also hard-coded on local properties from line 228 onwards also in MainViewModel.  Not overly sure if they need to be here, it's been a long time since I've looked at this code and it is very much work-in-progress (although work has stopped!).

Last edited Jul 16, 2012 at 9:53 AM by dynoben, version 3