Skip to main content
Glama

WHOOP Sleep Trend

whoop_sleep_trend
Read-onlyIdempotent

Aggregate WHOOP sleep over recent days to reveal trend direction for performance, duration, and efficiency, answering if sleep is improving or degrading.

Instructions

Aggregate WHOOP sleep over the last N days (default 30) into a per-metric trend for sleep performance percentage, sleep duration (hours) and sleep efficiency percentage.

Each metric returns { avg, min, max, slope, direction, n_valid } where slope is a least-squares fit over the chronologically ordered scored sleeps (oldest to newest) and direction is rising, falling, stable or insufficient_data. Use this to answer "is my sleep improving or degrading?" without paging the raw collection yourself. Read-only; fetches recent WHOOP v2 records, computes statistics, stores nothing. Not medical advice.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
daysNoNumber of days to aggregate into the trend. Minimum 2 (slope needs two points), maximum 30. Defaults to 30.
timezoneNoIANA timezone reserved for display, e.g. America/New_York.UTC
response_formatNomarkdown

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
kindYes
metricsYes
diagnosticYes
data_qualityYes
generated_atYes
lookback_daysYes
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false, so the description's added 'Read-only; fetches recent WHOOP v2 records, computes statistics, stores nothing' reinforces and expands on the safe, non-mutating nature. It also discloses the least-squares slope computation and the direction values, adding context beyond the annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two short paragraphs. The first states the aggregation scope and metrics; the second explains the output structure and a concrete use case. Every sentence contributes meaningful information without redundant or promotional language.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema is present, so the description does not need to detail return fields beyond the summary it gives. It covers what the tool does, how it computes results, when to use it, safety characteristics, and even a disclaimer ('Not medical advice'). This is complete for a read-only aggregation tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema descriptions cover 67% of parameters (days and timezone), and the response_format enum is self-explanatory. The description mentions the default of 30 days, which repeats the schema default. It does not add new explanatory value beyond what the schema already provides for parameters, so a baseline score of 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description uses a specific verb ('Aggregate') and clearly identifies the resource ('WHOOP sleep') and scope ('over the last N days'). It lists the specific metrics computed (sleep performance percentage, duration, efficiency) and explicitly differentiates from raw sleep listing by stating it computes trends to answer 'is my sleep improving or degrading?' without paging the raw collection.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides a clear use case: 'Use this to answer "is my sleep improving or degrading?"' It also implies an alternative (raw collection paging) with the phrase 'without paging the raw collection yourself.' However, it does not explicitly name sibling tools like whoop_list_sleeps or whoop_recovery_trend, nor does it state when not to use this tool.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/davidmosiah/whoop-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server