toggl_list_workspaces
Retrieve all available Toggl Track workspaces to organize time tracking data and manage projects across different teams or clients.
Instructions
List all available workspaces
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/index.ts:703-720 (handler)Handler for the toggl_list_workspaces tool. Fetches all workspaces using the TogglAPI and returns a formatted JSON response with workspace count and details (id, name, premium, default_currency).case 'toggl_list_workspaces': { const workspaces = await api.getWorkspaces(); return { content: [{ type: 'text', text: JSON.stringify({ count: workspaces.length, workspaces: workspaces.map(ws => ({ id: ws.id, name: ws.name, premium: ws.premium, default_currency: ws.default_currency })) }, null, 2) }] }; }
- src/index.ts:315-323 (schema)Tool schema definition including name, description, and empty input schema (no parameters required). This is part of the tools array registered with the MCP server.{ name: 'toggl_list_workspaces', description: 'List all available workspaces', inputSchema: { type: 'object', properties: {}, required: [] }, },