mc

mcp-googletasks

An MCP server to interface with the Google Tasks API

Publishermcp-googletasks
Submitted date4/13/2025

Bridging the Gap: Integrating Google Tasks with LLMs via the Model Context Protocol

The Model Context Protocol (MCP) is revolutionizing how Large Language Models (LLMs) interact with external data and tools. This document details a practical implementation: a Google Tasks MCP server, enabling seamless task management directly within LLM applications like Claude.

Unlocking LLM Potential: Google Tasks Integration

This MCP server acts as a bridge, empowering Claude to interact with Google Tasks. Imagine managing your to-do lists, creating new tasks, and marking them as complete, all through natural language commands within your LLM interface.

Key Features:

This server provides a comprehensive suite of functionalities:

  • Task List Management:

    • list-tasklists: Retrieve a list of all your task lists.
    • get-tasklist: Obtain detailed information about a specific task list.
    • create-tasklist: Generate new task lists to organize your work.
    • update-tasklist: Modify existing task lists to reflect changes.
    • delete-tasklist: Remove task lists that are no longer needed.
  • Task Management:

    • list-tasks: View all tasks within a specific task list.
    • get-task: Access detailed information about a particular task.
    • create-task: Add new tasks to your lists with ease.
    • update-task: Modify task details, such as due dates or descriptions.
    • delete-task: Remove tasks that are no longer relevant.
    • complete-task: Mark tasks as completed, tracking your progress.
    • move-task: Reorder tasks within a list or move them between lists.
    • clear-completed-tasks: Remove all completed tasks from a list, keeping it clean and focused.

Setting Up Your Google Tasks MCP Server: A Step-by-Step Guide

Follow these instructions to configure your environment and connect Claude to your Google Tasks:

1. Google Cloud Project Configuration

  1. Access the Google Cloud Console: Navigate to the Google Cloud Console.
  2. Create a New Project: Initiate a new project to house your Google Tasks API integration.
  3. Enable the Google Tasks API:
    • Go to "APIs & Services" > "Library."
    • Search for "Google Tasks API" and enable it for your project.
  4. Configure OAuth 2.0 Credentials:
    • Go to "APIs & Services" > "Credentials."
    • Click "Create Credentials" > "OAuth Client ID."
    • Configure the OAuth consent screen (selecting "External" is sufficient for personal use).
    • Choose "Web application" as the Application Type.
    • Add http://localhost:3000 as an authorized redirect URI.
    • Create the client ID and client secret. Important: Store these securely.

2. Integrating with Claude for Desktop

  1. Install Claude for Desktop: Download and install the latest version of Claude for Desktop.
  2. Locate the Configuration File:
    • MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json
    • Windows: %APPDATA%\Claude\claude_desktop_config.json
  3. Add the MCP Server Configuration: Modify the claude_desktop_config.json file to include the following configuration, replacing placeholders with your actual values:
{ "mcpServers": { "google-tasks": { "command": "node", "args": ["/path/to/google-tasks-mcp/build/index.js"], "env": { "GOOGLE_CLIENT_ID": "your_client_id_here", "GOOGLE_CLIENT_SECRET": "your_client_secret_here", "GOOGLE_REDIRECT_URI": "http://localhost:3000/oauth2callback" } } } }
  • command: Specifies the command to execute the server.
  • args: An array of arguments passed to the command. Ensure the path points to the compiled JavaScript file.
  • env: An object containing environment variables required by the server, including your Google Cloud credentials.

3. Building and Running the MCP Server

  1. Install Dependencies: Open your terminal, navigate to the project directory, and run:
npm install
  1. Build the Server: Compile the TypeScript code into JavaScript:
npm run build
  1. Restart Claude for Desktop: Ensure Claude recognizes the new configuration by restarting the application.

Authentication Process

The initial authentication process is crucial for granting the MCP server access to your Google Tasks:

  1. Initiate Authentication: Use the authenticate tool within Claude to generate an authorization URL.
  2. Authorize Access: Open the generated URL in your web browser and sign in with your Google account. Grant the necessary permissions to allow the MCP server to access your Google Tasks.
  3. Retrieve the Authorization Code: After successful authorization, you will be redirected to a page displaying an authorization code.
  4. Complete Authentication: Use the set-auth-code tool within Claude, providing the authorization code obtained in the previous step. This completes the authentication process.

Important Note: Authentication is session-based. You will need to re-authenticate each time you restart the server.

Prerequisites

  • Node.js: Version 14 or higher is required.
  • Claude for Desktop: Ensure you have the latest version installed.
  • Google Cloud Project: A Google Cloud Project with the Tasks API enabled and OAuth 2.0 credentials configured.

Visual Confirmation

The following screenshot provides a visual representation of the server in action:

Screenshot of the Google Tasks MCP Server

Visit More

View All