/** * Tool: get_weekly_summary * * Fetches recovery, sleep, workout, and cycle data for a 7-day period * and returns computed aggregates including averages, totals, and trends. * * Uses fetchAllPages with serialized endpoint calls to respect rate limits. * Filters unscored records. Returns partial results with warnings if some * endpoints fail; throws only if ALL 4 endpoints fail. */ import type { WhoopClient } from "../api/client.js"; import type { TrendDirectionResult } from "./stats-utils.js"; /** Input parameters for get_weekly_summary */ export interface WeeklySummaryParams { /** ISO 8601 start of week, or date expression. Defaults to most recent Monday. */ week_start?: string; } /** Output shape for get_weekly_summary */ export interface WeeklySummary { week_start: string; week_end: string; recovery: { average_score: number; min_score: number; max_score: number; average_hrv: number; average_rhr: number; trend: TrendDirectionResult; }; sleep: { average_duration_hours: number; average_performance_pct: number; average_efficiency_pct: number; }; workouts: { count: number; total_strain: number; total_calories_kj: number; sport_breakdown: Record; }; strain: { average_daily_strain: number; max_daily_strain: number; }; warnings?: string[]; } /** * Get a summarized health report for a given week. * * Fetches recovery, sleep, workout, and cycle data, then computes: * - Average/min/max recovery score, HRV, RHR * - Recovery trend (improving/declining/stable) * - Average sleep duration, performance, efficiency * - Workout count, total strain, calories, sport breakdown * - Average and max daily strain * * Returns partial results with warnings if 1-3 endpoints fail. * Throws if ALL 4 endpoints fail. */ export declare function getWeeklySummary(client: WhoopClient, params: WeeklySummaryParams): Promise; //# sourceMappingURL=get-weekly-summary.d.ts.map