health_get_activity_events
Retrieve activity events over a date range, including sedentary periods, altitude gains, and swim lengths, to analyze daily movement and trends.
Instructions
Get activity events over a date range: sedentary periods, altitude gains, swim lengths.
Each event's start and end (UTC), start_utc_offset for the local time, and the values Google sends with it, as sent: gainMillimeters for an altitude gain, strokeCount for a swim length, integers often as strings. Google counts altitude among its true zeros, so an interval with no gain field is a gain of none. Swim lengths are detected passively by the watch and need not belong to a swim workout. Sedentary periods are read from Google's merge of every source rather than from each source's own list.
Args: start_date: Start date as "YYYY-MM-DD", "YYYY-MM", or "7d". Default: 7 days back from the end date or today, whichever is earlier. end_date: End date as "YYYY-MM-DD", "YYYY-MM" (its last day), or "Nd". Default: today. live: If true, re-fetch this window from the API before reading the cache. include_records: If true, return each event's point exactly as Google sent it instead of its interval and values. Altitude and swim points carry their data source; Google's merged sedentary stream carries none.
Returns sedentary_periods, altitude_gains and swim_lengths, each a list of events with the local date it started on, and count, the events in all.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "health_get_activity_events"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| live | No | ||
| end_date | No | ||
| start_date | No | ||
| include_records | No |