Browse files

Fetch ride 'stream' data from Strava. Stream data contains collection…

…s of all the ride raw data (altitude, watts, distance, etc).
  • Loading branch information...
1 parent 6ece846 commit 6f065d581748850795fd3fabf0759e3c46c67a09 @anolson anolson committed Mar 27, 2011
Showing with 9 additions and 0 deletions.
  1. +4 −0 lib/strava-api/ride.rb
  2. +5 −0 lib/strava-api/rides.rb
View
4 lib/strava-api/ride.rb
@@ -51,5 +51,9 @@ def show
def efforts
@connection.ride_efforts(self.id)
end
+
+ def streams
+ @connection.ride_streams(self.id)
+ end
end #class Ride
end
View
5 lib/strava-api/rides.rb
@@ -35,5 +35,10 @@ def ride_efforts(id)
result["efforts"].collect {|effort| Effort.new(self, effort)}
end
+
+ def ride_streams(id)
+ result = call("streams/#{id}", nil, {})
+ Streams.new(self, result.to_hash)
+ end
end
end

0 comments on commit 6f065d5

Please sign in to comment.