Model#

Athletes#

AthleteStats(*[, all_ride_totals, ...])

Summary totals for rides, runs and swims, as shown in an athlete's public profile.

MetaAthlete(*[, bound_client, id, ...])

Represents an identifiable athlete with lazily loaded property to obtain this athlete's summary stats.

SummaryAthlete(*[, bound_client, id, city, ...])

The Summary Athlete object.

DetailedAthlete(*[, bound_client, id, city, ...])

Represents high level athlete information including their name, email, clubs they belong to, bikes, shoes, etc.

AthletePrEffort(*[, effort_count, ...])

An object that holds athlete PR effort attributes.

AthleteSegmentStats(*[, activity_id, ...])

A structure being returned for segment stats for current athlete.

Activities#

MetaActivity(*[, bound_client, id])

Represents an identifiable activity with lazily loaded properties to collect this activity's comments, zones, kudos and photos.

SummaryActivity(*[, bound_client, id, ...])

The Activity object that contains high level summary activity for an activity.

DetailedActivity(*[, bound_client, id, ...])

Represents an activity (ride, run, etc.).

ClubActivity(*[, athlete, distance, ...])

Represents an activity returned from a club.

ActivityTotals(*[, achievement_count, ...])

Contains a set of total values for an activity including elapsed time, moving time, distance and elevation gain.

Lap(*[, bound_client, activity, athlete, ...])

An object that represents an Activity lap.

Split(*[, average_speed, distance, ...])

A split -- may be metric or standard units (which has no bearing on the units used in this object, just the binning of values).

RelaxedActivityType([root])

This object supports allowing an array of Literal values to be used for Activity Type.

RelaxedSportType([root])

A class that extends the list of Literal values allowed for Sport Types that are defined in the generated strava_model module.

ActivityZone(*[, bound_client, ...])

Base class for activity zones.

TimedZoneDistribution(*[, max, min, time])

A single distribution bucket object, used for activity zones.

Activity Photos#

Note: the activity photo classes are defined differently in the Strava spec. This section will likely need to be updated. These endpoints are not well documented.

ActivityPhotoPrimary(*[, id, source, urls, ...])

Represents the primary photo for an activity.

ActivityPhoto(*[, activity_id, ...])

A full photo record attached to an activity.

Clubs#

MetaClub(*[, bound_client, id, name, ...])

Represents an identifiable club with lazily loaded properties to obtain this club's members and activities.

SummaryClub(*[, bound_client, id, name, ...])

Represents a single club with detailed information about the club including the club's location, activity types, etc.

DetailedClub(*[, bound_client, id, name, ...])

The detailed club object contains all of the club data available to the authenticated Athlete.

Routes and Segments#

LatLon([root])

Stores lat / lon values or None.

SummarySegment(*[, bound_client, ...])

Contains summary information for a specific segment

Segment(*[, bound_client, activity_type, ...])

Represents a single Strava segment.

SegmentExplorerResult(*[, bound_client, ...])

Represents a segment result from the segment explorer feature.

Map(*[, id, polyline, summary_polyline])

Pass through object.

Route(*[, bound_client, athlete, ...])

Represents a spatial route created by an athlete.

Stream(*[, original_size, resolution, ...])

Stream of readings from the activity, effort or segment.

Segment Efforts#

Split(*[, average_speed, distance, ...])

A split -- may be metric or standard units (which has no bearing on the units used in this object, just the binning of values).

BaseEffort(*[, activity_id, distance, ...])

Base class for a best effort or segment effort.

BestEffort(*[, activity_id, distance, ...])

Class representing a best effort (e.g. best time for 5k).

SegmentEffort(*[, activity_id, distance, ...])

Class representing a best effort on a particular segment.

SegmentEffortAchievement(*[, rank, type, ...])

An undocumented structure being returned for segment efforts.

SummarySegmentEffort(*[, activity_id, ...])

Returns summary information for a segment in an activity.

Webhook Subscriptions#

Subscription(*[, id, application_id, ...])

Represents a Webhook Event Subscription.

SubscriptionCallback(*[, hub_mode, ...])

Represents a Webhook Event Subscription Callback.

SubscriptionUpdate(*[, subscription_id, ...])

Represents a Webhook Event Subscription Update.

Custom Types#

Distance([x])

A class for representing distances as quantities (using meter as unit, which is the implicit default of Strava).

Duration

A class that calculates the duration or time elapsed for an activity, activity segment, or activity lap.

Timezone

A class to represent and manipulate time zone information.

Velocity([x])

A class for representing velocities as quantities (using meters per second as unit, which is the implicit default of Strava). These quantities can then

Stravalib helpers#

BoundClientEntity(*[, bound_client])

A class that bounds the Client object to the model.

naive_datetime(value)

Utility helper that parses a datetime value provided in JSON, string, int or other formats and returns a datetime.datetime object.

lazy_property(fn)

Should be used to decorate the functions that return a lazily loaded entity (collection), e.g., the members of a club.

check_valid_location(location)

Validate a list of location xy values.