Skip to main content
Glama

google_tasks_create_tasklist

Create a new task list in Google Tasks by specifying a title. Ideal for organizing and managing tasks within Google MCP’s integrated workflow tools.

Instructions

Create a new task list

Input Schema

NameRequiredDescriptionDefault
titleYesTitle of the new task list

Input Schema (JSON Schema)

{ "properties": { "title": { "description": "Title of the new task list", "type": "string" } }, "required": [ "title" ], "type": "object" }

Implementation Reference

  • The main handler function that validates the input arguments using isCreateTaskListArgs and calls googleTasksInstance.createTaskList(title) to create the task list, then returns the result.
    export async function handleTasksCreateTasklist( args: any, googleTasksInstance: GoogleTasks ) { if (!isCreateTaskListArgs(args)) { throw new Error("Invalid arguments for google_tasks_create_tasklist"); } const { title } = args; const result = await googleTasksInstance.createTaskList(title); return { content: [{ type: "text", text: result }], isError: false, }; }
  • Defines the MCP tool schema including name, description, and input schema requiring a 'title' string.
    export const CREATE_TASKLIST_TOOL: Tool = { name: "google_tasks_create_tasklist", description: "Create a new task list", inputSchema: { type: "object", properties: { title: { type: "string", description: "Title of the new task list", }, }, required: ["title"], }, };
  • Registers the tool in the MCP server's CallToolRequestSchema handler by dispatching to the specific handler function.
    case "google_tasks_create_tasklist": return await tasksHandlers.handleTasksCreateTasklist( args, googleTasksInstance );
  • Runtime type guard function used by the handler to validate input arguments match the expected { title: string } shape.
    export function isCreateTaskListArgs(args: any): args is { title: string; } { return args && typeof args.title === "string"; }

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/vakharwalad23/google-mcp'

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