public class StreamServiceImpl extends StravaServiceImpl implements StreamService
Implementation of StreamService
api, requestRate, requestRateDailyaccessTokenIsValid, future, getToken, requestRateDailyPercentage, requestRatePercentagepublic static StreamService instance(Token token)
Returns an instance of segment effort services
Instances are cached so that if 2 requests are made for the same token, the same instance is returned
token - The Strava access token to be used in requests to the Strava
APIpublic void clearCache()
StravaServiceClear any and all cached data entries
Primarily used when revoking/deauthorising a token so that there are no entries remaining that are associated with the token that could mistakenly get returned
clearCache in interface StravaServiceStravaService.clearCache()public List<StravaStream> getActivityStreams(Integer activityId)
StreamServiceStreams represent the raw data of the uploaded file. External applications may only access this information for activities owned by the authenticated athlete.
While there are a large number of stream types, they may not exist for all activities. If a stream type does not exist for the
activity, it will be ignored.
All streams for a given activity will be the same length and the values at a given index correspond to the same time. For example, the time from the time stream can be correlated to the lat/lng or watts streams.
Privacy Zones
StravaStream requests made using a public access_token will be cropped with the user's privacy zones, regardless if the requesting athlete owns the requested activity. To fetch the complete stream data use an access_token with view_private permissions.
URL GET https://www.strava.com/api/v3/activities/:id/streams/:types
getActivityStreams in interface StreamServiceactivityId - The id of the activity for which streams are to be retrievednull if the activity doesn't existStreamService.getActivityStreams(java.lang.Integer)public List<StravaStream> getActivityStreams(Integer activityId, StravaStreamResolutionType resolution, StravaStreamSeriesDownsamplingType seriesType, StravaStreamType... types)
StreamServiceStreams represent the raw data of the uploaded file. External applications may only access this information for activities owned by the authenticated athlete.
While there are a large number of stream types, they may not exist for all activities. If a stream type does not exist for the
activity, it will be ignored.
All streams for a given activity will be the same length and the values at a given index correspond to the same time. For example, the time from the time stream can be correlated to the lat/lng or watts streams.
Privacy Zones
StravaStream requests made using a public access_token will be cropped with the user's privacy zones, regardless if the requesting athlete owns the requested activity. To fetch the complete stream data use an access_token with view_private permissions.
URL GET https://www.strava.com/api/v3/activities/:id/streams/:types
getActivityStreams in interface StreamServiceactivityId - The id of the activity for which streams are to be retrievedresolution - (Optional) low (100), medium (1000) or high (10000), default is all, indicates desired number of data points, streams will only be down
sampledseriesType - (Optional) relevant only if using resolution. Either "time" or "distance", default is "distance", used to index the streams if the stream is
being reducedtypes - List of types, if the activity does not have that stream it will not be included in the responsenull if the activity doesn't existStreamService.getActivityStreams(Integer,
StravaStreamResolutionType, StravaStreamSeriesDownsamplingType,
StravaStreamType...)public CompletableFuture<List<StravaStream>> getActivityStreamsAsync(Integer activityId)
StreamServiceStreams represent the raw data of the uploaded file. External applications may only access this information for activities owned by the authenticated athlete.
While there are a large number of stream types, they may not exist for all activities. If a stream type does not exist for the
activity, it will be ignored.
All streams for a given activity will be the same length and the values at a given index correspond to the same time. For example, the time from the time stream can be correlated to the lat/lng or watts streams.
Privacy Zones
StravaStream requests made using a public access_token will be cropped with the user's privacy zones, regardless if the requesting athlete owns the requested activity. To fetch the complete stream data use an access_token with view_private permissions.
URL GET https://www.strava.com/api/v3/activities/:id/streams/:types
getActivityStreamsAsync in interface StreamServiceactivityId - The id of the activity for which streams are to be retrievednull if the activity doesn't existStreamService.getActivityStreamsAsync(java.lang.Integer)public CompletableFuture<List<StravaStream>> getActivityStreamsAsync(Integer activityId, StravaStreamResolutionType resolution, StravaStreamSeriesDownsamplingType seriesType, StravaStreamType... types)
StreamServiceStreams represent the raw data of the uploaded file. External applications may only access this information for activities owned by the authenticated athlete.
While there are a large number of stream types, they may not exist for all activities. If a stream type does not exist for the
activity, it will be ignored.
All streams for a given activity will be the same length and the values at a given index correspond to the same time. For example, the time from the time stream can be correlated to the lat/lng or watts streams.
Privacy Zones
StravaStream requests made using a public access_token will be cropped with the user's privacy zones, regardless if the requesting athlete owns the requested activity. To fetch the complete stream data use an access_token with view_private permissions.
URL GET https://www.strava.com/api/v3/activities/:id/streams/:types
getActivityStreamsAsync in interface StreamServiceactivityId - The id of the activity for which streams are to be retrievedresolution - (Optional) low (100), medium (1000) or high (10000), default is all, indicates desired number of data points, streams will only be down
sampledseriesType - (Optional) relevant only if using resolution. Either "time" or "distance", default is "distance", used to index the streams if the stream is
being reducedtypes - List of types, if the activity does not have that stream it will not be included in the responsenull if the activity doesn't existStreamService.getActivityStreamsAsync(java.lang.Integer, javastrava.api.v3.model.reference.StravaStreamResolutionType, javastrava.api.v3.model.reference.StravaStreamSeriesDownsamplingType, javastrava.api.v3.model.reference.StravaStreamType[])public List<StravaStream> getEffortStreams(Long effortId)
StreamService
A segment effort represents an attempt on a segment. This resource returns a subset of the
activity streams that correspond to that effort.
All streams for a given segment effort will be the same length and the values at a given index correspond to the same time.
This resource is available for all public efforts.
URL GET https://www.strava.com/api/v3/segment_efforts/:id/streams/:types
getEffortStreams in interface StreamServiceeffortId - The id of the segment effort for which streams are to be retrievedStreamService.getEffortStreams(java.lang.Long)public List<StravaStream> getEffortStreams(Long effortId, StravaStreamResolutionType resolution, StravaStreamSeriesDownsamplingType seriesType, StravaStreamType... types)
StreamService
A segment effort represents an attempt on a segment. This resource returns a subset of the
activity streams that correspond to that effort.
All streams for a given segment effort will be the same length and the values at a given index correspond to the same time.
This resource is available for all public efforts.
URL GET https://www.strava.com/api/v3/segment_efforts/:id/streams/:types
getEffortStreams in interface StreamServiceeffortId - The id of the segment effort for which streams are to be retrievedresolution - (Optional) low (100), medium (1000) or high (10000), default is all, indicates desired number of data points, streams will only be down
sampledseriesType - (Optional) relevant only if using resolution. Either "time" or "distance", default is "distance", used to index the streams if the stream is
being reducedtypes - List of types, if the effort does not have that stream it will not be included in the responseStreamService.getEffortStreams(Long,
StravaStreamResolutionType, StravaStreamSeriesDownsamplingType,
StravaStreamType...)public CompletableFuture<List<StravaStream>> getEffortStreamsAsync(Long effortId)
StreamService
A segment effort represents an attempt on a segment. This resource returns a subset of the
activity streams that correspond to that effort.
All streams for a given segment effort will be the same length and the values at a given index correspond to the same time.
This resource is available for all public efforts.
URL GET https://www.strava.com/api/v3/segment_efforts/:id/streams/:types
getEffortStreamsAsync in interface StreamServiceeffortId - The id of the segment effort for which streams are to be retrievedStreamService.getEffortStreamsAsync(java.lang.Long)public CompletableFuture<List<StravaStream>> getEffortStreamsAsync(Long effortId, StravaStreamResolutionType resolution, StravaStreamSeriesDownsamplingType seriesType, StravaStreamType... types)
StreamService
A segment effort represents an attempt on a segment. This resource returns a subset of the
activity streams that correspond to that effort.
All streams for a given segment effort will be the same length and the values at a given index correspond to the same time.
This resource is available for all public efforts.
URL GET https://www.strava.com/api/v3/segment_efforts/:id/streams/:types
getEffortStreamsAsync in interface StreamServiceeffortId - The id of the segment effort for which streams are to be retrievedresolution - (Optional) low (100), medium (1000) or high (10000), default is all, indicates desired number of data points, streams will only be down
sampledseriesType - (Optional) relevant only if using resolution. Either "time" or "distance", default is "distance", used to index the streams if the stream is
being reducedtypes - List of types, if the effort does not have that stream it will not be included in the responseStreamService.getEffortStreamsAsync(java.lang.Long, javastrava.api.v3.model.reference.StravaStreamResolutionType, javastrava.api.v3.model.reference.StravaStreamSeriesDownsamplingType, javastrava.api.v3.model.reference.StravaStreamType[])public List<StravaStream> getSegmentStreams(Integer segmentId)
StreamService
Retrieve detailed geographical information streams about a specific StravaSegment.
Only distance, altitude and latlng stream types are available.
URL GET https://www.strava.com/api/v3/segments/:id/streams/:types
getSegmentStreams in interface StreamServicesegmentId - The id of the segment for which streams are to be retrievedStreamService.getSegmentStreams(java.lang.Integer)public List<StravaStream> getSegmentStreams(Integer segmentId, StravaStreamResolutionType resolution, StravaStreamSeriesDownsamplingType seriesType, StravaStreamType... types)
StreamService
Retrieve detailed geographical information streams about a specific StravaSegment.
Only distance, altitude and latlng stream types are available.
URL GET https://www.strava.com/api/v3/segments/:id/streams/:types
getSegmentStreams in interface StreamServicesegmentId - The id of the segment for which streams are to be retrievedresolution - (Optional) low (100), medium (1000) or high (10000), default is all, indicates desired number of data points, streams will only be down
sampledseriesType - (Optional) relevant only if using resolution. Either "time" or "distance", default is "distance", used to index the streams if the stream is
being reducedtypes - List of types, if the segment does not have that stream it will not be included in the responseStreamService.getSegmentStreams(Integer,
StravaStreamResolutionType, StravaStreamSeriesDownsamplingType,
StravaStreamType...)public CompletableFuture<List<StravaStream>> getSegmentStreamsAsync(Integer segmentId)
StreamService
Retrieve detailed geographical information streams about a specific StravaSegment.
Only distance, altitude and latlng stream types are available.
URL GET https://www.strava.com/api/v3/segments/:id/streams/:types
getSegmentStreamsAsync in interface StreamServicesegmentId - The id of the segment for which streams are to be retrievedStreamService.getSegmentStreamsAsync(java.lang.Integer)public CompletableFuture<List<StravaStream>> getSegmentStreamsAsync(Integer segmentId, StravaStreamResolutionType resolution, StravaStreamSeriesDownsamplingType seriesType, StravaStreamType... types)
StreamService
Retrieve detailed geographical information streams about a specific StravaSegment.
Only distance, altitude and latlng stream types are available.
URL GET https://www.strava.com/api/v3/segments/:id/streams/:types
getSegmentStreamsAsync in interface StreamServicesegmentId - The id of the segment for which streams are to be retrievedresolution - (Optional) low (100), medium (1000) or high (10000), default is all, indicates desired number of data points, streams will only be down
sampledseriesType - (Optional) relevant only if using resolution. Either "time" or "distance", default is "distance", used to index the streams if the stream is
being reducedtypes - List of types, if the segment does not have that stream it will not be included in the responseStreamService.getSegmentStreamsAsync(java.lang.Integer, javastrava.api.v3.model.reference.StravaStreamResolutionType, javastrava.api.v3.model.reference.StravaStreamSeriesDownsamplingType, javastrava.api.v3.model.reference.StravaStreamType[])Copyright © 2016 Dan Shannon. All rights reserved.