Overview
There are two broad resource categories provided by Junction:- A Summary type is a summarization of a specific calendar day or a session.
- A Timeseries type is a time-ordered collection of data samples.
- Fitbit provides daily activity summaries, as well as some high-frequency activity timeseries data.
- Oura provides only a daily activity summary, without any complementary high-frequency activity timeseries data.
- The existence of a
sleep_efficiencysummary field does not imply that there is a correspondingsleep_efficiencytimeseries. - The existence of a Glucose Timeseries type does not imply that there is a corresponding
glucosesummary field. - A Timeseries type could derive multiple summary fields, e.g., heart rate statistics and HR zones.
Summary types
Discrete Timeseries types
Each value is associated with a single point in time.Interval Timeseries types
Each value is associated with a half-open time interval ([start, end)).
Timeseries Data Sampling Rates
Junction records and forwards timeseries data from the data provider, without any upsampling or downsampling applied. Even within the same data provider, these data may come from different devices or data sources with varying sampling rates. Because of this, you should not make assumptions about any particular timeseries resource having a fixed sampling rate. For technical design and capacity planning purposes, you may model after the following three categories of timeseries resources:Very High Frequency Timeseries
Second-level peak sampling rate; typically 1000s to low 10000s samples per day.
Resources that fall into this category:
High Frequency Timeseries
Minute-level peak sampling rate; typically 100s samples per day.
Resources that fall into this category:
Sparse Timeseries
All timeseries resources not specified as (Very) High Frequency fall into this category.
Summary types by providers
Timeseries types by providers
Fetching via the API
For example,Workouts is made up of fields specific to a workout, like calories, distance and duration. When you make a request to /summary/workouts/<user_id> you get the following fields:
Heartrate on the other hand, is a timeseries resource. You can fetch it via timeseries/<user_id>/heartrate and it looks like this:
Glucose as a resource.
Fields by Provider
Resources alone are not the whole story. Depending on the provider, a field might not be available. For example, both Garmin and Strava provideWorkouts, yet the former doesn’t have elev_high or elev_low.
Providers marked with
* mean that Junction calculates the field’s value. In some cases, they might come as null, since we weren’t able to make the calculation.