Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 15 additions & 15 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ Unlike other clients, including [strava-api-v3](https://github.com/jaredholdcrof
- [Get Athlete Stats](#get-athlete-stats)
- [Update Athlete](#update-athlete)
- [Clubs](#clubs)
- [List Club Events](#list-club-events)
- [Get Club](#get-club)
- [List Athlete Clubs](#list-athlete-clubs)
- [Get Club](#get-club)
- [List Club Events](#list-club-events)
- [Gears](#gears)
- [Get Equipment](#get-equipment)
- [Routes](#routes)
Expand Down Expand Up @@ -382,19 +382,20 @@ See [Strava::Models::DetailedAthlete](lib/strava/models/detailed_athlete.rb) for

Strava removed the Club Activities, Club Members, and Club Admins endpoints on September 1, 2026 (see the [Strava API changelog](https://developers.strava.com/docs/changelog/)). The corresponding `club_activities`, `club_members`, and `club_admins` methods have been removed from this gem.

#### List Club Events
#### List Athlete Clubs

Retrieve recent Events from a specific club.
Returns a list of the clubs whose membership includes the authenticated athlete.

```ruby
events = client.club_events(108605) # => Array[Strava::Models::ClubEvent]
clubs = client.athlete_clubs # => Array[Strava::Models::SummaryClub]

event = events.first # => Strava::Models::ClubEvent
club = clubs.first # => Strava::Models::SummaryClub

event.title # => 'First Group Event Ever! Yippieh!'
activity.name # => 'NYRR'
activity.strava_url # => 'https://www.strava.com/clubs/nyrr'
```

See [Strava::Models::ClubEvent](lib/strava/models/club_event.rb) for all available properties.
See [Strava::Models::SummaryClub](lib/strava/models/summary_club.rb) for all available properties.

#### Get Club

Expand All @@ -408,20 +409,19 @@ club.name # => 'NYRR'

See [Strava::Models::DetailedClub](lib/strava/models/detailed_club.rb) for all available properties.

#### List Athlete Clubs
#### List Club Events

Returns a list of the clubs whose membership includes the authenticated athlete.
Retrieve recent Events from a specific club.

```ruby
clubs = client.athlete_clubs # => Array[Strava::Models::SummaryClub]
events = client.club_events(108605) # => Array[Strava::Models::ClubEvent]

club = clubs.first # => Strava::Models::SummaryClub
event = events.first # => Strava::Models::ClubEvent

activity.name # => 'NYRR'
activity.strava_url # => 'https://www.strava.com/clubs/nyrr'
event.title # => 'First Group Event Ever! Yippieh!'
```

See [Strava::Models::SummaryClub](lib/strava/models/summary_club.rb) for all available properties.
See [Strava::Models::ClubEvent](lib/strava/models/club_event.rb) for all available properties.

### Gears

Expand Down
30 changes: 15 additions & 15 deletions lib/strava/api/endpoints/clubs.rb
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,15 @@ module Endpoints
#
module Clubs
#
# List club / group events.
# List logged-in athlete clubs.
#
# @param id_or_options [String, Integer, Hash] Either a club ID or a hash of options including :id
# @param options [Hash] Additional options (if first parameter is an ID)
# @option options [Integer] :page Page number
# @option options [Integer] :per_page Number of items per page. Defaults to 30
# @option options [Integer] :page
# Page number.
# @option options [Integer] :per_page
# Number of items per page. Defaults to 30.
#
def club_events(id_or_options, options = {}, &block)
id, options = parse_args(id_or_options, options)
paginate "clubs/#{id}/group_events", options, Strava::Models::ClubEvent, &block
def athlete_clubs(options = {}, &block)
paginate 'athlete/clubs', options, Strava::Models::SummaryClub, &block
end

#
Expand All @@ -41,15 +40,16 @@ def club(id_or_options, options = {})
end

#
# List logged-in athlete clubs.
# List club / group events.
#
# @option options [Integer] :page
# Page number.
# @option options [Integer] :per_page
# Number of items per page. Defaults to 30.
# @param id_or_options [String, Integer, Hash] Either a club ID or a hash of options including :id
# @param options [Hash] Additional options (if first parameter is an ID)
# @option options [Integer] :page Page number
# @option options [Integer] :per_page Number of items per page. Defaults to 30
#
def athlete_clubs(options = {}, &block)
paginate 'athlete/clubs', options, Strava::Models::SummaryClub, &block
def club_events(id_or_options, options = {}, &block)
id, options = parse_args(id_or_options, options)
paginate "clubs/#{id}/group_events", options, Strava::Models::ClubEvent, &block
end
end
end
Expand Down
Loading