Skip to main content
Glama

whoop-set-access-token

Configure API authentication by setting the access token required to retrieve WHOOP fitness and health data through the MCP server.

Instructions

Set the access token for API calls

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
accessTokenYesAccess token to use for API calls

Implementation Reference

  • Handler for the 'whoop-set-access-token' tool: validates the accessToken input and delegates to WhoopApiClient.setAccessToken, returning success message.
    case 'whoop-set-access-token': { if (!args || typeof args.accessToken !== 'string') { throw new Error('accessToken is required and must be a string'); } this.whoopClient.setAccessToken(args.accessToken); return { content: [ { type: 'text', text: 'Access token set successfully', }, ], }; }
  • Registration of the 'whoop-set-access-token' tool in the listTools handler, including name, description, and input schema.
    { name: 'whoop-set-access-token', description: 'Set the access token for API calls', inputSchema: { type: 'object', properties: { accessToken: { type: 'string', description: 'Access token to use for API calls', }, }, required: ['accessToken'], }, },
  • Input schema definition for the 'whoop-set-access-token' tool.
    inputSchema: { type: 'object', properties: { accessToken: { type: 'string', description: 'Access token to use for API calls', }, }, required: ['accessToken'], },
  • Core helper method in WhoopApiClient that sets the access token in the config, which is used by the axios interceptor for Authorization headers in subsequent API calls.
    setAccessToken(accessToken: string) { this.config.accessToken = accessToken; }

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/nissand/whoop-mcp-server-claude'

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