get_available_badges
Retrieve a list of all badges you can earn through Garmin Connect activities and challenges.
Instructions
Get all available badges that can be earned
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "get_available_badges"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools/challenges.tools.ts:5-16 (registration)Tool 'get_available_badges' is registered with the MCP server via 'registerTool' with a description.
server.registerTool( 'get_available_badges', { description: 'Get all available badges that can be earned', }, async () => { const data = await client.getAvailableBadges(); return { content: [{ type: 'text' as const, text: JSON.stringify(data, null, 2) }], }; }, ); - src/client/garmin.client.ts:574-576 (handler)Handler method 'getAvailableBadges' on GarminClient makes the actual API request to the badges endpoint.
async getAvailableBadges(): Promise<unknown> { return this.request(AVAILABLE_BADGES_ENDPOINT); } - Endpoint constant pointing to '/badge-service/badge/available'.
export const AVAILABLE_BADGES_ENDPOINT = '/badge-service/badge/available';