Skip to main content
Glama
arpitbatra123

Google Tasks MCP Server

list-tasklists

Retrieve all task lists from Google Tasks to view, organize, or manage your tasks through Claude's interface.

Instructions

List all task lists

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • src/index.ts:188-242 (registration)
    Registration of the 'list-tasklists' tool with inline handler implementation that lists all task lists from Google Tasks API after checking authentication.
    server.tool("list-tasklists", "List all task lists", {}, async () => { if (!isAuthenticated()) { return { isError: true, content: [ { type: "text", text: "Not authenticated. Please use the 'authenticate' tool first.", }, ], }; } try { const response = await tasks.tasklists.list(); const taskLists = response.data.items || []; if (taskLists.length === 0) { return { content: [ { type: "text", text: "No task lists found.", }, ], }; } const formattedLists = taskLists.map((list) => ({ id: list.id, title: list.title, updated: list.updated, })); return { content: [ { type: "text", text: JSON.stringify(formattedLists, null, 2), }, ], }; } catch (error) { console.error("Error listing task lists:", error); return { isError: true, content: [ { type: "text", text: `Error listing task lists: ${error}`, }, ], }; } });
  • The handler function for 'list-tasklists' tool: authenticates, calls tasks.tasklists.list(), formats the response, and returns JSON or appropriate error messages.
    server.tool("list-tasklists", "List all task lists", {}, async () => { if (!isAuthenticated()) { return { isError: true, content: [ { type: "text", text: "Not authenticated. Please use the 'authenticate' tool first.", }, ], }; } try { const response = await tasks.tasklists.list(); const taskLists = response.data.items || []; if (taskLists.length === 0) { return { content: [ { type: "text", text: "No task lists found.", }, ], }; } const formattedLists = taskLists.map((list) => ({ id: list.id, title: list.title, updated: list.updated, })); return { content: [ { type: "text", text: JSON.stringify(formattedLists, null, 2), }, ], }; } catch (error) { console.error("Error listing task lists:", error); return { isError: true, content: [ { type: "text", text: `Error listing task lists: ${error}`, }, ], }; } });
  • Empty schema object indicating no input parameters required for the tool.
    server.tool("list-tasklists", "List all task lists", {}, async () => {

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/arpitbatra123/mcp-googletasks'

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