Daily summaries

Required scope: activity

Get daily activity summaries for user, including step count, distance and duration for each activity (if applicable).
Final summary for a particular date will only be available at earliest after midnight in the user’s current timezone.

Single day

 GET /user/summary/daily/<date>[?updatedSince=<updatedSince>][&timeZone=<timeZone>]

Required parameter:

  • date: date in yyyyMMdd or yyyy-MM-dd format

Specific week

Uses ISO8601 week-numbering.

 GET /user/summary/daily/<week>[?updatedSince=<updatedSince>][&timeZone=<timeZone>]

Required parameter:

  • week: week in yyyy-’W’ww format, for example 2013-W09

Specific month

 GET /user/summary/daily/<month>[?updatedSince=<updatedSince>][&timeZone=<timeZone>]

Required parameter:

  • month: month in yyyyMM or yyyy-MM format

Date range

Maximum range in one query between from and to date is 31 days.

GET /user/summary/daily?from=<from>&to=<to>[&updatedSince=<updatedSince>][&timeZone=<timeZone>]

Required parameter:

  • from: range start in yyyyMMdd or yyyy-MM-dd format
  • to: range end in yyyyMMdd or yyyy-MM-dd format

Past days

Maximum range is 31 days in on query.

GET /user/summary/daily?pastDays=<pastDays>[&updatedSince=<updatedSince>][&timeZone=<timeZone>]

Required parameter:

  • pastDays: how many past days to return, including today (in users current time zone)

Optional parameters:

  • updatedSince: if true, return only days which data has been updated since given timestamp in ISO 8601 (yyyyMMdd’T’HHmmssZ) format
  • timeZone: use the given time zone ID for the date period and timestamps, overriding the users current time zone

Response

All the daily summary API calls return a JSON array of dates and summaries.

[{
    "date": "20130315",
    "summary": [
        {
            "activity": "walking",
            "group": "walking",
            "duration": 2133,
            "distance": 1847,
            "steps": 2500,
            "calories": 60
        },
        {
            "activity": "running",
            "group": "running",
            "duration": 254,
            "distance": 436,
            "steps": 624,
            "calories": 99
        },
        {
            "activity": "cycling",
            "group": "cycling",
            "duration": 2688,
            "distance": 4049,
            "calories": 999
        },
        {
            "activity": "transport",
            "group": "transport",
            "duration": 500,
            "distance": 15000
        },
        {
            "activity": "bus",
            "group": "transport",
            "duration": 600,
            "distance": 10000
        },
        {
            "activity": "underground",
            "group": "transport",
            "duration": 300,
            "distance": 5000
        },
        {
            "activity": "zumba",
            "duration": 1200,
            "calories": 500
        }
    ],
    "caloriesIdle": 1785,
    "lastUpdate": "20130317T121143Z"
},
{
    "date": "20130316",
    "summary": [
        {
            "activity": "walking",
            "group": "walking",
            "duration": 3333,
            "distance": 2222,
            "steps": 1999,
            "calories": 120
        },
        {
            "activity": "running",
            "group": "running",
            "duration": 123,
            "distance": 345,
            "steps": 456,
            "calories": 60
        }
    ],
    "caloriesIdle": 1785,
    "lastUpdate": "20130317T121143Z"
},
{
    "date": "20130317",
    "summary": null,
    "caloriesIdle": 1785
}]
  • date: summary date, in format yyyyMMdd
  • summary: JSON array of daily activity summaries or null if there is no summary available for the date
    • activity: specific name of the activity. See Activity list API for list of currently supported activities.
    • group (optional): a more generic activity supergroup to which the action belongs to. If defined, one of: walking, running, cycling or transport. Note that there can be additional groups in the future.
    • duration: duration of the activity in seconds
    • distance (optional): distance for the activity in meters (if applicable)
    • steps (optional): step count for the activity (if applicable)
    • calories (optional): calories burn for the activity (if applicable) in kcal, on top of the idle burn. Available if user has at least once enabled calories
  • caloriesIdle (optional): daily idle burn in kcal. Available if user has at least once enabled calories
  • lastUpdate (optional): when the summary data was last updated in ISO 8601 (yyyyMMdd’T’HHmmssZ) format, always in UTC