list_daily_activity
Retrieve daily activity summaries including steps, calories, and heart rate for a date range. Omits days without synced data.
Instructions
Returns 24/7 activity summaries for each day in [from, to] inclusive, ordered chronologically. Each entry: { date, steps, activeCalories, totalCalories, avgHeartRate, minHeartRate, maxHeartRate, restingHeartRate }. Days where the watch did not sync are omitted from the result. Use get_daily_activity for a single day. Requires Activity API subscription on apizone; returns 404 without it. Read-only.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | Yes | Start date YYYY-MM-DD, inclusive. Must be ≤ to. Days without synced data are silently omitted, not 404. | |
| to | Yes | End date YYYY-MM-DD, inclusive. Future dates are accepted but produce no entries. Prefer ranges ≤ 30 days for responsiveness. |
Implementation Reference
- src/api.ts:140-144 (handler)The `listDailyActivity` method on the SuuntoClient class executes the core logic: it constructs a URL with `from` and `to` query parameters, calls the Suunto API endpoint `/v2/activity`, and sorts results chronologically by the `date` field.
async listDailyActivity(from: string, to: string) { const q = new URLSearchParams({ from, to }); const res = await this.json<any>(`${this.dailyPrefix()}/activity?${q.toString()}`); return sortByDate(res); } - src/index.ts:171-199 (schema)MCP tool schema registration for `list_daily_activity`: defines the tool description and inputSchema with `from` (required start date) and `to` (required end date) parameters, both YYYY-MM-DD format.
{ name: "list_daily_activity", description: "Returns 24/7 activity summaries for each day in [from, to] inclusive, ordered chronologically. Each entry: { date, steps, activeCalories, totalCalories, avgHeartRate, minHeartRate, maxHeartRate, restingHeartRate }. Days where the watch did not sync are omitted from the result. Use get_daily_activity for a single day. Requires Activity API subscription on apizone; returns 404 without it. Read-only.", inputSchema: { type: "object", properties: { from: { type: "string", format: "date", pattern: "^\\d{4}-\\d{2}-\\d{2}$", minLength: 10, maxLength: 10, examples: ["2026-04-01"], description: "Start date YYYY-MM-DD, inclusive. Must be ≤ to. Days without synced data are silently omitted, not 404.", }, to: { type: "string", format: "date", pattern: "^\\d{4}-\\d{2}-\\d{2}$", minLength: 10, maxLength: 10, examples: ["2026-04-30"], description: "End date YYYY-MM-DD, inclusive. Future dates are accepted but produce no entries. Prefer ranges ≤ 30 days for responsiveness.", }, }, required: ["from", "to"], }, }, - src/index.ts:345-348 (registration)MCP handler routing: the `list_daily_activity` case in the switch statement that calls `suunto.listDailyActivity(a.from, a.to)` and returns the JSON-stringified result.
case "list_daily_activity": return text( JSON.stringify(await suunto.listDailyActivity(a.from, a.to), null, 2), ); - src/cli.ts:111-121 (helper)CLI wrapper for `list-daily-activity`: parses `--from` and `--to` arguments and delegates to `suunto.listDailyActivity()`.
case "list-daily-activity": { const { values } = parseArgs({ args: rest, options: { from: { type: "string" }, to: { type: "string" }, }, }); if (!values.from || !values.to) die("Usage: list-daily-activity --from YYYY-MM-DD --to YYYY-MM-DD"); out(await suunto.listDailyActivity(values.from!, values.to!)); break;