Skip to main content
Glama

get_fitness

Retrieve CTL, ATL, and TSB fitness time series data from intervals.icu to analyze athletic performance trends and monitor training load over specified date ranges.

Instructions

Get CTL/ATL/TSB fitness time series.

Args: oldest: Start date in YYYY-MM-DD format (inclusive). newest: End date in YYYY-MM-DD format (inclusive).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
oldestNo
newestNo

Implementation Reference

  • main.py:66-81 (handler)
    The get_fitness tool handler function. Takes optional oldest/newest date parameters and returns CTL/ATL/TSB fitness time series data by calling the wellness endpoint.
    def get_fitness(
        oldest: str | None = None,
        newest: str | None = None,
    ) -> list:
        """Get CTL/ATL/TSB fitness time series.
    
        Args:
            oldest: Start date in YYYY-MM-DD format (inclusive).
            newest: End date in YYYY-MM-DD format (inclusive).
        """
        params: dict[str, Any] = {}
        if oldest:
            params["oldest"] = oldest
        if newest:
            params["newest"] = newest
        return _get(f"/athlete/{ATHLETE_ID}/wellness", params)
  • main.py:65-65 (registration)
    The @mcp.tool() decorator that registers get_fitness as an MCP tool.
    @mcp.tool()
  • main.py:18-22 (helper)
    Helper function _get used by get_fitness to make authenticated HTTP GET requests to the Intervals.icu API.
    def _get(path: str, params: dict[str, Any] | None = None) -> Any:
        with _client() as client:
            r = client.get(path, params=params)
            r.raise_for_status()
            return r.json()
Behavior2/5

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

With no annotations provided, the description carries full behavioral burden but offers minimal disclosure. While it identifies the return as a 'time series,' it fails to specify the data structure, frequency of data points, or what occurs when optional date parameters are omitted (default behavior). No mention of calculation methodology or data availability limits.

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?

Extremely efficient with zero redundancy. Front-loads the core purpose in the first sentence, followed by concise Args documentation. Every sentence earns its place despite the brevity.

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

Completeness2/5

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

Inadequate given the lack of output schema and annotations. While parameters are documented, the description omits the return value structure entirely—critical information for a time series endpoint. Should describe the temporal resolution, data fields returned (CTL/ATL/TSB values), and null-parameter behavior.

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

Parameters4/5

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

Compensates effectively for 0% schema description coverage by providing critical format details (YYYY-MM-DD) and boundary semantics (inclusive) for both date parameters. Deducted one point because it does not clarify that both parameters are optional (default null) or explain the behavior when date ranges are not specified.

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

Purpose4/5

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

Clearly states it retrieves CTL/ATL/TSB fitness time series with specific verb 'Get' and identifies the domain (fitness metrics vs activities/athletes in siblings). Deducted one point because it assumes familiarity with CTL/ATL/TSB acronyms without explaining they refer to Chronic Training Load, Acute Training Load, and Training Stress Balance metrics.

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

Usage Guidelines2/5

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

Provides no guidance on when to use this versus sibling tools like get_activities or get_wellness. Does not explain what fitness insights this provides compared to raw activity data, nor does it mention prerequisites like requiring historical activity data to calculate these metrics.

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/ryansheppard/intervals.mcp'

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