strava-ruby-client 2.3.0 → 3.0.0.pre.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +60 -48
- data/LICENSE.md +1 -1
- data/README.md +100 -80
- data/bin/strava-activities.rb +2 -0
- data/bin/strava-oauth-token +43 -35
- data/bin/strava-refresh-token +32 -0
- data/lib/strava/api/client.rb +46 -6
- data/lib/strava/api/cursor.rb +26 -2
- data/lib/strava/api/endpoints/activities.rb +10 -7
- data/lib/strava/api/endpoints/athletes.rb +2 -2
- data/lib/strava/api/endpoints/clubs.rb +5 -5
- data/lib/strava/api/endpoints/gears.rb +1 -1
- data/lib/strava/api/endpoints/segment_efforts.rb +2 -2
- data/lib/strava/api/endpoints/segments.rb +3 -3
- data/lib/strava/api/pagination.rb +1 -2
- data/lib/strava/models/achievement.rb +1 -0
- data/lib/strava/models/activity_stats.rb +1 -0
- data/lib/strava/models/activity_total.rb +5 -9
- data/lib/strava/models/activity_zone.rb +4 -1
- data/lib/strava/models/base_stream.rb +12 -0
- data/lib/strava/models/club_activity.rb +22 -0
- data/lib/strava/models/{club_member.rb → club_athlete.rb} +5 -2
- data/lib/strava/models/club_event.rb +6 -4
- data/lib/strava/models/comment.rb +7 -2
- data/lib/strava/models/destination.rb +12 -0
- data/lib/strava/models/{activity.rb → detailed_activity.rb} +51 -103
- data/lib/strava/models/{athlete.rb → detailed_athlete.rb} +20 -14
- data/lib/strava/models/{club.rb → detailed_club.rb} +10 -3
- data/lib/strava/models/{gear.rb → detailed_gear.rb} +10 -7
- data/lib/strava/models/{photo.rb → detailed_photo.rb} +13 -5
- data/lib/strava/models/{photos.rb → detailed_photos.rb} +2 -1
- data/lib/strava/models/{segment.rb → detailed_segment.rb} +18 -24
- data/lib/strava/models/{segment_effort.rb → detailed_segment_effort.rb} +23 -17
- data/lib/strava/models/explorer_segment.rb +8 -5
- data/lib/strava/models/heart_rate_zone_ranges.rb +1 -0
- data/lib/strava/models/kudoser.rb +1 -0
- data/lib/strava/models/lap.rb +18 -16
- data/lib/strava/models/lat_lng.rb +46 -0
- data/lib/strava/models/local_legend.rb +16 -0
- data/lib/strava/models/meta_activity.rb +13 -0
- data/lib/strava/models/meta_athlete.rb +14 -0
- data/lib/strava/models/meta_club.rb +12 -0
- data/lib/strava/models/mixins/{time.rb → average_speed.rb} +6 -29
- data/lib/strava/models/mixins/elapsed_time.rb +20 -0
- data/lib/strava/models/mixins/elevation_difference.rb +39 -0
- data/lib/strava/models/mixins/elevation_gain.rb +39 -0
- data/lib/strava/models/mixins/estimated_moving_time.rb +20 -0
- data/lib/strava/models/mixins/moving_time.rb +20 -0
- data/lib/strava/models/mixins/sport_type.rb +73 -0
- data/lib/strava/models/mixins/time_in_hours.rb +26 -0
- data/lib/strava/models/mixins/{elevation.rb → total_elevation_gain.rb} +1 -1
- data/lib/strava/models/photos_summary.rb +12 -0
- data/lib/strava/models/photos_summary_primary.rb +15 -0
- data/lib/strava/models/power_zone_ranges.rb +1 -0
- data/lib/strava/models/route.rb +14 -13
- data/lib/strava/models/similar_activities.rb +2 -0
- data/lib/strava/models/split.rb +8 -6
- data/lib/strava/models/stats_visibility.rb +11 -0
- data/lib/strava/models/stream_set.rb +2 -1
- data/lib/strava/models/summary_activity.rb +71 -0
- data/lib/strava/models/summary_athlete.rb +31 -0
- data/lib/strava/models/summary_club.rb +34 -0
- data/lib/strava/models/summary_gear.rb +18 -0
- data/lib/strava/models/summary_pr_segment_effort.rb +16 -0
- data/lib/strava/models/summary_segment.rb +34 -0
- data/lib/strava/models/summary_segment_effort.rb +16 -0
- data/lib/strava/models/timed_zone_range.rb +1 -0
- data/lib/strava/models/token.rb +1 -1
- data/lib/strava/models/trend.rb +1 -0
- data/lib/strava/models/updatable_activity.rb +16 -0
- data/lib/strava/models/upload.rb +2 -0
- data/lib/strava/models/waypoint.rb +15 -0
- data/lib/strava/models/xoms.rb +13 -0
- data/lib/strava/models/zone_range.rb +1 -0
- data/lib/strava/models/zones.rb +1 -0
- data/lib/strava/version.rb +1 -1
- data/lib/strava/webhooks/models/event.rb +1 -1
- data/lib/strava-ruby-client.rb +55 -30
- metadata +47 -18
- data/lib/strava/api/endpoints/running_races.rb +0 -20
- data/lib/strava/models/club_admin.rb +0 -15
- data/lib/strava/models/running_race.rb +0 -35
- data/lib/strava/models/segment_stats.rb +0 -17
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 853c9b6f6a2956a00884c62f9ee3e6a91cde864d357623edd92642c32569bcdf
|
|
4
|
+
data.tar.gz: b2472b823d7204f5cfe735675e2cf29e543c9ca6ecf277c242fb2b84fbed4103
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b03e4cd64e82466eab1d7691ce6f4108d81b5e88f192aaaec611a8d419df31f3d088c11eebc18c3fb4f39c70147b3aae38d3aab8c4419e5ac812774ed02e5bd1
|
|
7
|
+
data.tar.gz: 8b7d71b869998eaaf43b23f6e6ef673eec7efd50d610d8af3d184d7abf340ff63fb648d8ba73a822b859620e2e3acc72b0e535a2046b0e44b49de136387272ea
|
data/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
### 3.0.0 (Next)
|
|
2
|
+
|
|
3
|
+
* [#96](https://github.com/dblock/strava-ruby-client/pull/96): Updates and refactors models to spec - [@dblock](https://github.com/dblock).
|
|
4
|
+
* [#98](https://github.com/dblock/strava-ruby-client/pull/98): Changes all `latlng` properties to return an instance of `Strava::Models::LatLng` - [@dblock](https://github.com/dblock).
|
|
5
|
+
* [#94](https://github.com/dblock/strava-ruby-client/pull/94): Adds video fields to `Strava::Models::Photo` - [@dblock](https://github.com/dblock).
|
|
6
|
+
* [#99](https://github.com/dblock/strava-ruby-client/pull/99): Adds support for `page_size` on `activity_comments` and adds `limit` - [@dblock](https://github.com/dblock).
|
|
7
|
+
* [#97](https://github.com/dblock/strava-ruby-client/pull/97): Adds `bin/strava-refresh-token` - [@dblock](https://github.com/dblock).
|
|
8
|
+
* [#92](https://github.com/dblock/strava-ruby-client/pull/92): Fixes `Hashie::Trash` serialization warning for `object_id` of `Strava::Webhooks::Models::Event` - [@simonneutert](https://github.com/simonneutert).
|
|
9
|
+
* [#95](https://github.com/dblock/strava-ruby-client/pull/95): Fixes `club_events` returning `Strava::Models::ClubEvent` with an empty string in `created_at` - [@dblock](https://github.com/dblock).
|
|
10
|
+
* [#93](https://github.com/dblock/strava-ruby-client/pull/93): Updates GitHub Actions workflows - [@simonneutert](https://github.com/simonneutert).
|
|
11
|
+
* Your contribution here.
|
|
12
|
+
|
|
1
13
|
### 2.3.0 (2025/10/16)
|
|
2
14
|
|
|
3
15
|
* [#91](https://github.com/dblock/strava-ruby-client/pull/91): Respects `Faraday::Response::RaiseError::DEFAULT_OPTIONS` when raising errors - [@dblock](https://github.com/dblock).
|
|
@@ -16,86 +28,86 @@
|
|
|
16
28
|
|
|
17
29
|
### 2.0.0 (2023/6/22)
|
|
18
30
|
|
|
19
|
-
* [#77](https://github.com/dblock/strava-ruby-client/pull/77): Drops unsupported
|
|
31
|
+
* [#77](https://github.com/dblock/strava-ruby-client/pull/77): Drops unsupported `activity_photos` - [@simonneutert](https://github.com/simonneutert).
|
|
20
32
|
* [#62](https://github.com/dblock/strava-ruby-client/pull/68): Drops `Activity#type` attribute as it is being deprecated by Strava, dropping `Activity#type_emoji` with it - [@simonneutert](https://github.com/simonneutert).
|
|
21
|
-
* [#23](https://github.com/dblock/strava-ruby-client/pull/23):
|
|
33
|
+
* [#23](https://github.com/dblock/strava-ruby-client/pull/23): Raises `Strava::Errors::UploadError` on failed uploads - [@ylecuyer](https://github.com/ylecuyer), [@simonneutert](https://github.com/simonneutert).
|
|
22
34
|
* [#69](https://github.com/dblock/strava-ruby-client/pull/69): Raises `Strava::Api::RatelimitError`, when API ratelimit exceeded - [@simonneutert](https://github.com/simonneutert).
|
|
23
35
|
* [#74](https://github.com/dblock/strava-ruby-client/pull/74): Fixes serialization causing `stack level too deep` - [@simonneutert](https://github.com/simonneutert).
|
|
24
36
|
* [#75](https://github.com/dblock/strava-ruby-client/pull/75): Fixes DangerBot deprecation warning for `check` of TOC - [@simonneutert](https://github.com/simonneutert).
|
|
25
37
|
|
|
26
38
|
### 1.0.0 (2022/12/29)
|
|
27
39
|
|
|
28
|
-
* [#48](https://github.com/dblock/strava-ruby-client/pull/55):
|
|
29
|
-
* [#56](https://github.com/dblock/strava-ruby-client/pull/56):
|
|
30
|
-
* [#58](https://github.com/dblock/strava-ruby-client/pull/58):
|
|
31
|
-
* [#58](https://github.com/dblock/strava-ruby-client/pull/58):
|
|
32
|
-
* [#58](https://github.com/dblock/strava-ruby-client/pull/58):
|
|
33
|
-
* [#59](https://github.com/dblock/strava-ruby-client/pull/59):
|
|
34
|
-
* [#63](https://github.com/dblock/strava-ruby-client/pull/63):
|
|
40
|
+
* [#48](https://github.com/dblock/strava-ruby-client/pull/55): Removes `client.running_races` - [@simonneutert](https://github.com/simonneutert).
|
|
41
|
+
* [#56](https://github.com/dblock/strava-ruby-client/pull/56): Removes `client.segment_leaderboard` - [@simonneutert](https://github.com/simonneutert).
|
|
42
|
+
* [#58](https://github.com/dblock/strava-ruby-client/pull/58): Updates Faraday to `>= 2.0` - [@schinery](https://github.com/schinery).
|
|
43
|
+
* [#58](https://github.com/dblock/strava-ruby-client/pull/58): Removes support for Ruby 2.5 and 2.6 - [@schinery](https://github.com/schinery).
|
|
44
|
+
* [#58](https://github.com/dblock/strava-ruby-client/pull/58): Upgrades Robocop to 1.3.0 - [@schinery](https://github.com/schinery).
|
|
45
|
+
* [#59](https://github.com/dblock/strava-ruby-client/pull/59): Removes deprecated `athlete.email` field - [@francordie](https://github.com/francordie).
|
|
46
|
+
* [#63](https://github.com/dblock/strava-ruby-client/pull/63): Adds `activity.sport_type` for Strava API V3 specifications - [@simonneutert](https://github.com/simonneutert).
|
|
35
47
|
* [#61](https://github.com/dblock/strava-ruby-client/pull/61): Adds ratelimit as a property of model(s) - [@simonneutert](https://github.com/simonneutert), [@adamwolf](https://github.com/adamwolf).
|
|
36
48
|
|
|
37
49
|
### 0.4.3 (2022/03/21)
|
|
38
50
|
|
|
39
|
-
* [#51](https://github.com/dblock/strava-ruby-client/pull/51):
|
|
40
|
-
* [#53](https://github.com/dblock/strava-ruby-client/pull/53):
|
|
41
|
-
* [#46](https://github.com/dblock/strava-ruby-client/pull/46):
|
|
51
|
+
* [#51](https://github.com/dblock/strava-ruby-client/pull/51): Ensures support for large Integer IDs - [@simonneutert](https://github.com/simonneutert).
|
|
52
|
+
* [#53](https://github.com/dblock/strava-ruby-client/pull/53): Upgrades to RuboCop 1.26.0 - [@dblock](https://github.com/dblock).
|
|
53
|
+
* [#46](https://github.com/dblock/strava-ruby-client/pull/46): Adds missing `activity:read` scope from `strava-oauth-token` - [@xaviershay](https://github.com/xaviershay).
|
|
42
54
|
|
|
43
55
|
### 0.4.2 (2021/10/03)
|
|
44
56
|
|
|
45
|
-
* [#45](https://github.com/dblock/strava-ruby-client/pull/45):
|
|
57
|
+
* [#45](https://github.com/dblock/strava-ruby-client/pull/45): Adds `Gear#frame_type` `#retired` `#weight` - [@deuber](https://github.com/deuber).
|
|
46
58
|
|
|
47
59
|
### 0.4.1 (2021/07/11)
|
|
48
60
|
|
|
49
|
-
* [#37](https://github.com/dblock/strava-ruby-client/pull/38):
|
|
50
|
-
* [#34](https://github.com/dblock/strava-ruby-client/pull/34):
|
|
61
|
+
* [#37](https://github.com/dblock/strava-ruby-client/pull/38): Adds `Club#club_events` - [@simonneutert](https://github.com/simonneutert).
|
|
62
|
+
* [#34](https://github.com/dblock/strava-ruby-client/pull/34): Adds `Athlete#ftp` - [@virae](https://github.com/virae).
|
|
51
63
|
|
|
52
64
|
### 0.4.0 (2020/05/09)
|
|
53
65
|
|
|
54
|
-
* [#29](https://github.com/dblock/strava-ruby-client/pull/29):
|
|
55
|
-
* [#30](https://github.com/dblock/strava-ruby-client/pull/30):
|
|
66
|
+
* [#29](https://github.com/dblock/strava-ruby-client/pull/29): Caches `Faraday::Connection` for persistent adapters - [@dblock](https://github.com/dblock).
|
|
67
|
+
* [#30](https://github.com/dblock/strava-ruby-client/pull/30): Requires Faraday >= 1.0 - [@dblock](https://github.com/dblock).
|
|
56
68
|
|
|
57
69
|
### 0.3.2 (2020/03/28)
|
|
58
70
|
|
|
59
|
-
* [#26](https://github.com/dblock/strava-ruby-client/pull/26):
|
|
60
|
-
* Automatically
|
|
61
|
-
* [#18](https://github.com/dblock/strava-ruby-client/pull/18):
|
|
62
|
-
* [#18](https://github.com/dblock/strava-ruby-client/pull/18):
|
|
63
|
-
* [#21](https://github.com/dblock/strava-ruby-client/pull/21):
|
|
71
|
+
* [#26](https://github.com/dblock/strava-ruby-client/pull/26): Corrects `Strava::Webhooks.config.endpoint` - [@dblock](https://github.com/dblock).
|
|
72
|
+
* Automatically converts `before` and `after` arguments of `Strava::Api::Client#athlete_activities` from `Time` to `Integer` - [@dblock](https://github.com/dblock).
|
|
73
|
+
* [#18](https://github.com/dblock/strava-ruby-client/pull/18): Adds testing against Ruby 2.5.3 and 2.6.0 - [@lucianosousa](https://github.com/lucianosousa).
|
|
74
|
+
* [#18](https://github.com/dblock/strava-ruby-client/pull/18): Upgrades Rubocop to 0.61.1 - [@lucianosousa](https://github.com/lucianosousa).
|
|
75
|
+
* [#21](https://github.com/dblock/strava-ruby-client/pull/21): Includes headers in error response - [@jameschevalier](https://github.com/jameschevalier).
|
|
64
76
|
|
|
65
77
|
### 0.3.1 (2018/12/05)
|
|
66
78
|
|
|
67
|
-
*
|
|
68
|
-
* [#2](https://github.com/dblock/strava-ruby-client/issues/2):
|
|
69
|
-
* [#15](https://github.com/dblock/strava-ruby-client/issues/15):
|
|
70
|
-
*
|
|
71
|
-
*
|
|
79
|
+
* Adds `Strava::Api::Client#activity_photos` - [@dblock](https://github.com/dblock).
|
|
80
|
+
* [#2](https://github.com/dblock/strava-ruby-client/issues/2): Adds `Strava::Api::Client#deauthorize` - [@dblock](https://github.com/dblock).
|
|
81
|
+
* [#15](https://github.com/dblock/strava-ruby-client/issues/15): Adds `strava-oauth-token` and `strava-webhooks` to gem executables - [@dblock](https://github.com/dblock).
|
|
82
|
+
* Fixes `Strava::Models::Activity#total_elevation_gain` no returns blank for negative and zero elevation differences - [@dblock](https://github.com/dblock).
|
|
83
|
+
* Fixes `Strava::Models::Split#distance` and `total_elevation_gain` incorrect for `Strava::Models::Activity#splits_standard` - [@dblock](https://github.com/dblock).
|
|
72
84
|
|
|
73
85
|
### 0.3.0 (2018/12/03)
|
|
74
86
|
|
|
75
|
-
*
|
|
76
|
-
*
|
|
77
|
-
*
|
|
78
|
-
*
|
|
79
|
-
*
|
|
80
|
-
*
|
|
81
|
-
*
|
|
82
|
-
*
|
|
83
|
-
*
|
|
84
|
-
*
|
|
85
|
-
* [#9](https://github.com/dblock/strava-ruby-client/issues/9): All methods that take `id` can take it directly or via options hash - [@dblock](https://github.com/dblock).
|
|
87
|
+
* Adds webhooks support - [@dblock](https://github.com/dblock).
|
|
88
|
+
* Adds `Strava::Api::Client#athlete_zones`, `athlete_stats` and `update_athlete` - [@dblock](https://github.com/dblock).
|
|
89
|
+
* Adds `Strava::Api::Client#club`, `club_admins` and `club_members` - [@dblock](https://github.com/dblock).
|
|
90
|
+
* Adds `Strava::Api::Client#gear` - [@dblock](https://github.com/dblock).
|
|
91
|
+
* Adds `Strava::Api::Client#route`, `athlete_routes`, `export_route_gpx` and `export_route_tcx` - [@dblock](https://github.com/dblock).
|
|
92
|
+
* Adds `Strava::Api::Client#running_race` and `running_races` - [@dblock](https://github.com/dblock).
|
|
93
|
+
* Adds `Strava::Api::Client#segment_effort` and `segment_efforts` - [@dblock](https://github.com/dblock).
|
|
94
|
+
* Adds `Strava::Api::Client#explore_segments`, `segment_leaderboard`, `starred_segments`, `segment` and `star_segment` - [@dblock](https://github.com/dblock).
|
|
95
|
+
* Adds `Strava::Api::Client#activity_streams`, `segment_effort_streams` and `segment_streams` - [@dblock](https://github.com/dblock).
|
|
96
|
+
* Adds `Strava::Api::Client#create_upload` and `upload` - [@dblock](https://github.com/dblock).
|
|
97
|
+
* [#9](https://github.com/dblock/strava-ruby-client/issues/9): All methods that take `id` can take it directly or via `options` hash - [@dblock](https://github.com/dblock).
|
|
86
98
|
|
|
87
99
|
### 0.2.0 (2018/11/27)
|
|
88
100
|
|
|
89
|
-
*
|
|
90
|
-
*
|
|
91
|
-
*
|
|
92
|
-
*
|
|
93
|
-
*
|
|
94
|
-
*
|
|
95
|
-
*
|
|
96
|
-
*
|
|
97
|
-
* [#5](https://github.com/dblock/strava-ruby-client/issues/5):
|
|
98
|
-
* [#6](https://github.com/dblock/strava-ruby-client/issues/6):
|
|
101
|
+
* Adds `Strava::Api::Client#activity` with segments, photos, similar activities, trends, laps and gear - [@dblock](https://github.com/dblock).
|
|
102
|
+
* Adds `Activity#type_emoji` and `Activity#strava_url` - [@dblock](https://github.com/dblock).
|
|
103
|
+
* Adds `Athlete#name` and `Athlete#strava_url` - [@dblock](https://github.com/dblock).
|
|
104
|
+
* Adds `Strava::Api::Client#athlete_clubs` - [@dblock](https://github.com/dblock).
|
|
105
|
+
* Adds `Strava::Api::Client#club_activities` - [@dblock](https://github.com/dblock).
|
|
106
|
+
* Adds `Strava::Api::Client#create_activity` and `Strava::Api::Client#update_activity` - [@dblock](https://github.com/dblock).
|
|
107
|
+
* Adds `Strava::Api::Client#activity_comments`, `activity_kudos`, `activity_zones` and `activity_laps` - [@dblock](https://github.com/dblock).
|
|
108
|
+
* Adds support for converting and displaying activity distance, elevation, speed and pace - [@dblock](https://github.com/dblock).
|
|
109
|
+
* [#5](https://github.com/dblock/strava-ruby-client/issues/5): Adds support for pagination - [@dblock](https://github.com/dblock).
|
|
110
|
+
* [#6](https://github.com/dblock/strava-ruby-client/issues/6): Renames the `strava-oauth-token` tool and handles the redirect in the browser - [@dblock](https://github.com/dblock).
|
|
99
111
|
|
|
100
112
|
### 0.1.0 (2018/11/23)
|
|
101
113
|
|
data/LICENSE.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
MIT License
|
|
2
2
|
|
|
3
|
-
Copyright (c) 2018 Daniel Doubrovkine and Contributors
|
|
3
|
+
Copyright (c) 2018-2025 Daniel Doubrovkine and Contributors
|
|
4
4
|
|
|
5
5
|
Permission is hereby granted, free of charge, to any person obtaining
|
|
6
6
|
a copy of this software and associated documentation files (the
|