README.md in strava-ruby-client-2.1.0 vs README.md in strava-ruby-client-2.2.0

- old
+ new

@@ -12,10 +12,11 @@ - [Installation](#installation) - [Usage](#usage) - [Activities](#activities) - [Create an Activity](#create-an-activity) - [Get Activity](#get-activity) + - [List Activity Photos](#list-activity-photos) - [List Activity Comments](#list-activity-comments) - [List Activity Kudoers](#list-activity-kudoers) - [List Activity Laps](#list-activity-laps) - [List Athlete Activities](#list-athlete-activities) - [Get Activity Zones](#get-activity-zones) @@ -146,9 +147,34 @@ google_image_url = "https://maps.googleapis.com/maps/api/staticmap?maptype=roadmap&path=enc:#{map.summary_polyline}&key=#{google_maps_api_key}&size=800x800&markers=color:yellow|label:S|#{start_latlng[0]},#{start_latlng[1]}&markers=color:green|label:F|#{end_latlng[0]},#{end_latlng[1]}" ``` See [Strava::Models::Map](lib/strava/models/map.rb) for all available properties. + +#### List Activity Photos + +Returns the photos on the given activity. This API is undocumented in Strava's docs. But there is a discussion in the [strava community hub](https://communityhub.strava.com/t5/developer-discussions/download-all-photos-of-my-own-activities/m-p/11262). + +```ruby +photos = client.activity_photos(1982980795) # => Array[Strava::Models::Photo] +# in order to request a certain size (by default it will return the biggest size possible): +# photos = client.activity_photos(1982980795, {size: 1920}) # => Array[Strava::Models::Photo] + +photo = photos.first # => Strava::Models::Photo + +photo.id # => nil +photo.unique_id # => '65889142-538D-4EE5-96F5-3DC3B773B1E3' +photo.urls # => { '0' => 'https://dgtzuqphqg23d.cloudfront.net/eb4DMJ2hJW3k_g9URZEMfaJ8rZfHagrNlZRuEZz0osU-29x64.jpg' } +photo.athlete_id # => 26_462_176 +photo.activity_id # => 1_946_417_534 +photo.activity_name # => 'TCS NYC Marathon 2018' +photo.created_at # => Time +photo.uploaded_at # => Time +photo.sizes # => { '0' => [29, 64] } +photo.default_photo # => false +``` + +See [Strava::Models::Photo](lib/strava/models/photo.rb) for all available properties. #### List Activity Comments Returns the comments on the given activity.