Skip to main content
Glama

check-strava-connection

Verify your Strava connection status to ensure data access for analyzing workouts, tracking fitness progress, and exploring routes through AI assistants.

Instructions

Check if Strava is connected and show the current connection status. Use this when the user asks about their connection status.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The implementation of the check-strava-connection tool, which verifies if a user is authenticated with Strava and returns their connection status.
    export const checkStravaConnectionTool = {
        name: 'check-strava-connection',
        description: 'Check if Strava is connected and show the current connection status. Use this when the user asks about their connection status.',
        inputSchema: z.object({}),
        execute: async (): Promise<{ content: Array<{ type: 'text'; text: string }> }> => {
            try {
                const config = await loadConfig();
                
                if (!hasClientCredentials(config) && !hasValidTokens(config)) {
                    return {
                        content: [{
                            type: 'text' as const,
                            text: 'āŒ Not connected to Strava.\n\nSay "Connect my Strava account" to get started!',
                        }],
                    };
                }
                
                if (!hasValidTokens(config)) {
                    return {
                        content: [{
                            type: 'text' as const,
                            text: 'āš ļø Strava credentials found but not fully authenticated.\n\nSay "Connect my Strava account" to complete the connection.',
                        }],
                    };
                }
                
                // Try to verify the connection
                try {
                    const token = config.accessToken!;
                    const athlete = await getAuthenticatedAthlete(token);
                    return {
                        content: [{
                            type: 'text' as const,
                            text: `āœ… Connected to Strava as ${athlete.firstname} ${athlete.lastname}\n\nšŸ“ ${athlete.city || 'Location not set'}, ${athlete.country || ''}\nšŸ… ${athlete.premium ? 'Premium' : 'Free'} account\n\nConfig stored at: ${getConfigPath()}`,
                        }],
                    };
                } catch {
                    return {
                        content: [{
                            type: 'text' as const,
                            text: 'āš ļø Connection may have expired.\n\nSay "Connect my Strava account" to refresh the connection.',
                        }],
                    };
                }
            } catch (error: any) {
                return {
                    content: [{
                        type: 'text' as const,
                        text: `āŒ Error checking connection: ${error.message}`,
                    }],
                };
            }
        },
    };
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions checking and showing status, which implies a read-only operation, but does not disclose any behavioral traits such as authentication requirements, rate limits, error conditions, or what the status output includes (e.g., connected/disconnected, last sync time). For a tool with zero annotation coverage, this is a significant gap.

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 concise sentences that are front-loaded with the tool's purpose followed by usage guidance. Every sentence earns its place by providing essential information without any waste or redundancy.

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

Completeness3/5

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

Given the tool's simplicity (0 parameters, no annotations, no output schema), the description is adequate but has clear gaps. It explains what the tool does and when to use it, but lacks details on behavioral aspects (e.g., what the status output looks like, any prerequisites). For a status-check tool, this is minimally viable but could be more complete.

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?

The tool has 0 parameters, and schema description coverage is 100%. With no parameters to document, the description does not need to add parameter semantics. The baseline for 0 parameters is 4, as there is nothing to compensate for, and the description appropriately focuses on the tool's purpose and usage.

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?

The description clearly states the tool's purpose: 'Check if Strava is connected and show the current connection status.' It specifies the verb ('check') and resource ('Strava connection'), but does not explicitly differentiate from its siblings (e.g., connect-strava, disconnect-strava) beyond implying it's a read-only status check.

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 clear context for when to use it: 'Use this when the user asks about their connection status.' This gives explicit guidance on the triggering condition. However, it does not mention when not to use it or name specific alternatives (e.g., connect-strava for establishing a connection).

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/LimeON-source/Strava-MCP'

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