Skip to main content
Glama

get_activity_types

Retrieve the full list of activity types supported by Garmin Connect, such as running, cycling, and swimming, to categorize fitness activities.

Instructions

Get all available activity types (running, cycling, swimming, etc.)

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Registration and handler for the 'get_activity_types' tool. The tool handler calls client.getActivityTypes() and returns the result as JSON text.
    server.registerTool(
      'get_activity_types',
      {
        description: 'Get all available activity types (running, cycling, swimming, etc.)',
      },
      async () => {
        const data = await client.getActivityTypes();
        return {
          content: [{ type: 'text' as const, text: JSON.stringify(data, null, 2) }],
        };
      },
    );
  • The 'registerActivityTools' function that registers tools on the MCP server. This is where 'get_activity_types' is registered via server.registerTool.
    export function registerActivityTools(server: McpServer, client: GarminClient): void {
  • Client method that fetches activity types by calling the Garmin API endpoint ACTIVITY_TYPES_ENDPOINT via this.request().
    async getActivityTypes(): Promise<unknown> {
      return this.request(ACTIVITY_TYPES_ENDPOINT);
    }
  • The API endpoint constant for fetching activity types from Garmin Connect.
    export const ACTIVITY_TYPES_ENDPOINT = '/activity-service/activity/activityTypes';
  • Reference to get_activity_types as a cross-reference in the createManualActivitySchema for valid activityTypeKey values.
    activityTypeKey: z.string().describe('Activity type key (e.g. running, cycling, swimming). Use get_activity_types to see all options'),
Behavior4/5

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

The description states it returns 'all available activity types', implying a safe read operation. No annotations exist, but the tool is parameterless and the description is sufficient for this low-complexity tool, though it doesn't detail return format or rate 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?

A single sentence that efficiently conveys the tool's purpose. No redundant information.

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

Completeness4/5

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

For a parameterless tool with no output schema, the description covers what the tool does. It could mention that it returns a list of strings, but the examples imply that. It is sufficiently complete for an agent to understand the tool.

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?

No parameters exist, and schema coverage is 100%. The description adds meaning by listing example types, which clarifies the expected output beyond the empty schema.

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 clearly identifies the tool's action ('Get all available activity types') and provides concrete examples (running, cycling, swimming). It is a specific verb-resource pair that distinguishes it from sibling tools like 'get_activities' which return actual activity records.

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

Usage Guidelines3/5

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

No explicit guidance on when to use this tool versus alternatives, but given it's a simple reference listing, the purpose is self-evident. It does not mention prerequisites or typical use cases, which could help an agent decide to call it before filtering activities.

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/Nicolasvegam/garmin-connect-mcp'

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