Closed simonneutert closed 1 year ago
Thanks, care to PR an update?
I'll start a draft :v:
An enumeration of the sport types an activity may have. Distinct from ActivityType in that it has new types (e.g. MountainBikeRide)
May be one of the following values: AlpineSki, BackcountrySki, Canoeing, Crossfit, EBikeRide, Elliptical, EMountainBikeRide, Golf, GravelRide, Handcycle, Hike, IceSkate, InlineSkate, Kayaking, Kitesurf, MountainBikeRide, NordicSki, Ride, RockClimbing, RollerSki, Rowing, Run, Sail, Skateboard, Snowboard, Snowshoe, Soccer, StairStepper, StandUpPaddling, Surfing, Swim, TrailRun, Velomobile, VirtualRide, VirtualRun, Walk, WeightTraining, Wheelchair, Windsurf, Workout, Yoga
Details taken from the Strava Support Page: https://support.strava.com/hc/en-us/articles/216919407-Supported-Sport-Types-on-Strava (2022-07-31 at 09-40-45)
I made some good progress and the new attribute comes in for older activities as expected.
Here's a shortened JSON response for an activity.
{
"resource_state": 3,
"athlete": { "id": 24776507, "resource_state": 1 },
"name": "Pimmel Party Buddytag der Tarmac Boys",
"distance": 92137.5,
"moving_time": 13297,
"elapsed_time": 15395,
"total_elevation_gain": 138.0,
"type": "Ride",
"sport_type": "Ride",
"workout_type": 10,
// ...
}
If you so wish I would put in the effort and write all cassette based checks from scratch 🥵
or you let me add the sport_type
next to type
for Activity
cassettes 💪
please, check the little work (link below), before I open a PR and let me know what your expectations for the _vcrcassettes are @dblock
I think we definitely need at least some new K7s that show a complete new response, but I don't think you need to try and update all of them from scratch unless you feel super motivated.
Cheers, sometimes work needs to be done, whether it's fun or not.
I will put the elbow grease in 🤝
@simonneutert Anything else needed here after https://github.com/dblock/strava-ruby-client/pull/63?
@dblock we could as a next step:
type
as an attribute from the code baseUpgrading.md
Readme.md
where needed That works! Please?
The replacing attribute will be
sport_type
.https://developers.strava.com/docs/changelog/