gt

gtasks-mcp

An MCP server to Manage Google Tasks

Publishergtasks-mcp
Submitted date4/13/2025

Seamless Task Management: Integrating Google Tasks with LLMs via the Model Context Protocol

This document details the Google Tasks MCP (Model Context Protocol) Server, a powerful tool that bridges the gap between Large Language Models (LLMs) and Google Tasks. By leveraging the MCP, this server enables LLM applications to seamlessly access, manipulate, and utilize task data directly from Google Tasks, opening up a world of possibilities for AI-powered task management, workflow automation, and intelligent assistance.

Core Components: Tools for Task Mastery

The Google Tasks MCP Server exposes a suite of meticulously crafted tools, each designed to empower LLMs with specific task-related capabilities:

  • search: Unleash the power of semantic search within your task lists. This tool accepts a query (string) and returns a curated list of tasks that match your search criteria, complete with detailed information.

  • list: Obtain a comprehensive overview of your tasks. This tool provides a paginated list of all tasks within Google Tasks, with an optional cursor (string) for efficient navigation through large task lists.

  • create: Breathe life into new tasks effortlessly. The create tool requires a title (string) and optionally accepts a taskListId (string), notes (string), and due (string) to define the task's attributes.

  • update: Fine-tune existing tasks with precision. This tool demands a taskListId (string), id (string), and uri (string) to identify the target task, and then allows modification of its title (string), notes (string), status (string - "needsAction" or "completed"), and due (string).

  • delete: Eliminate tasks with surgical accuracy. The delete tool requires a taskListId (string) and id (string) to pinpoint the task for removal.

  • clear: Declutter your task lists by archiving completed tasks. This tool simply requires a taskListId (string) to clear all completed tasks from the specified list.

Resource Representation: The Task Object

The server exposes Google Tasks resources as addressable entities:

  • Tasks (gtasks:///<task_id>): Each task is represented by a unique URI, allowing LLMs to directly reference and interact with individual tasks. The server supports reading task details, including title, status, due date, notes, and other relevant metadata. These tasks can be listed, read, created, updated, and deleted using the tools described above.

Embarking on Your Integration Journey

Follow these steps to set up and integrate the Google Tasks MCP Server into your LLM application:

  1. Google Cloud Project Setup:

    • Navigate to the Google Cloud Console and create a new project.
    • Enable the Google Tasks API for your project.
    • Configure an OAuth consent screen. For testing purposes, selecting "internal" is sufficient.
    • Add the necessary scope: https://www.googleapis.com/auth/tasks.
    • Create an OAuth Client ID with the application type set to "Desktop App".
    • Download the JSON file containing your client's OAuth keys.
    • Rename the downloaded file to gcp-oauth.keys.json and place it in the root directory of this repository.
  2. Build the Server: Ensure the server is built using either npm run build or npm run watch.

  3. Smithery Installation (Optional): For seamless installation via Smithery for Claude Desktop:

    npx -y @smithery/cli install @zcaceres/gtasks --client claude
  4. Authentication:

    • Run the server with the auth argument: npm run start auth.
    • This will initiate an authentication flow in your default web browser.
    • Complete the authentication process.
    • Upon successful authentication, your credentials will be securely stored in a file named .gdrive-server-credentials.json in the root directory of the repository.
  5. Desktop App Integration: To integrate this server with a desktop application, add the following configuration to your application's server settings:

    { "mcpServers": { "gtasks": { "command": "/opt/homebrew/bin/node", "args": [ "{ABSOLUTE PATH TO FILE HERE}/dist/index.js" ] } } }

    Note: Replace {ABSOLUTE PATH TO FILE HERE} with the actual absolute path to the dist/index.js file.

By following these steps, you can seamlessly integrate the Google Tasks MCP Server into your LLM applications, unlocking a new era of intelligent task management and workflow automation.

Visit More

View All