Stride

Search Documentation

Search for articles, guides, and more

← API overview

Search the workout library

GET/v1/workoutsrequires workouts.read

The catalogue of reusable structured workouts: the public Stride library plus the athlete's own, their teams' and their partner teams'.

query is matched semantically against name, description and tags, so plain language works well - "short sweet spot intervals", "threshold swim set". Tag filters are ANDed, so each extra tag narrows sharply; one or two is usually right. Call GET /v1/workouts/filters for the valid tag slugs and the number of workouts behind each.

Results are summaries. Call GET /v1/workouts/{workout_id} for the interval structure.

Query parameters

  • querystring

    Free-text search, matched semantically against name, description and tags.

    e.g. short sweet spot intervals

  • tagsstring

    Comma-separated tag slugs. All must match.

    e.g. threshold,vo2-max

  • activity_typeenum

    Sport filter. The library holds RIDE, RUN and SWIM workouts.

    RIDE · RUN · SWIM

  • min_duration_minutesinteger

    Minimum duration in minutes.

  • max_duration_minutesinteger

    Maximum duration in minutes.

  • min_distance_kminteger

    Minimum distance in kilometres. Only distance-based workouts carry one, which excludes most rides and swims.

  • max_distance_kminteger

    Maximum distance in kilometres. Same caveat as min_distance_km.

  • officialboolean

    True for only workouts curated by Stride, false for only community and team workouts. Omit for both.

  • owner_athlete_idstring

    Only workouts created by this athlete. Their private workouts are included only if the caller administers a team they belong to.

  • team_idstring

    Only workouts owned by this team. Private team workouts are included only for teams the caller administers.

  • sort_byenum

    Result ordering. Defaults to relevance when `query` is set and most-recent otherwise.

    AUTOMATIC · LENGTH_ASC · LENGTH_DESC · CREATED_AT_DESC · CREATED_AT_ASC · NAME_ASC · NAME_DESC · DISTANCE_ASC · DISTANCE_DESC · TRAINING_SCORE_ASC · TRAINING_SCORE_DESC

  • pageinteger

    Zero-based page number. Page through with `has_next_page`; the search backend does not return a total count, so there is no page total to report.

  • per_pageinteger

    Results per page. Defaults to 20, maximum 50.

Example

bash
curl -X GET "https://api.stride.is/v1/workouts" \
  -H "Authorization: Bearer $STRIDE_TOKEN"

Response 200

Success.

  • has_next_pagebooleanalways present
  • pageintegeralways present
  • per_pageintegeralways present
  • workoutsobject[]always present
    • descriptionstring
    • dominant_zonestring
    • idstringalways present
    • namestringalways present
    • officialbooleanalways present
    • owner_team_idstring
    • owner_user_idstring
    • slugstring
    • summarystring
    • tagsstring[]
    • total_distance_metersinteger
    • total_duration_secondsinteger
    • training_scoreinteger
    • typestring

Errors

Every error is an RFC 9457 problem document. Branch on its code, which is stable; detail is prose and may be reworded.

  • 400The request was malformed: an unparseable date, an unknown enum value, or a parameter combination that cannot be satisfied.
  • 401No access token was supplied, or it is not valid for this API.
  • 402The Stride account the token belongs to has no active subscription or trial.
  • 403The token does not hold the scope this endpoint requires, or may not act on the athlete or team named.
  • 404No such resource, or it is not visible to this token. The two are deliberately indistinguishable.
  • 405The path exists but does not serve this method. The Allow header lists the ones it does.
  • 429A rate limit was exceeded. Retry after the period in the Retry-After header.
  • 500Something failed on Stride's side. The failure is logged with a trace ID.