google-task-mcp
Enables managing Google Tasks (list, create, update, complete, uncomplete, delete) via OAuth 2.0 authorization.
README
Google Tasks MCP
Use Google Tasks from Codex or any MCP client that can run a local STDIO server. The server can list task lists and tasks, create or edit tasks, mark tasks complete, and delete tasks after explicit confirmation.
Everything runs locally. The server talks directly to the Google Tasks API and stores the OAuth token on your computer.
What you need
- Node.js 20 or newer
- A Google account with Google Tasks enabled
- A Google Cloud project
- Codex, the ChatGPT desktop app, or another MCP client with local STDIO support
Set up the project
1. Download and install
git clone <repository-url>
cd google-task-mcp
npm install
Run the checks to confirm that your local copy is ready:
npm run verify
2. Create Google OAuth credentials
- Open the Google Cloud Console and create or select a project.
- Enable the Google Tasks API.
- Open Google Auth platform → Branding and configure the consent screen.
- Under Audience, use Internal for a Google Workspace organization or External for a personal Google account. If the app is in testing, add the Google account you will use as a test user.
- Open Google Auth platform → Clients, select Create client, and choose Desktop app.
- Copy the generated client ID and client secret.
Google supports loopback addresses for desktop OAuth clients, so the included local callback URL works without hosting a web server. See Google's Tasks API Node.js quickstart and desktop OAuth guidance for more detail.
3. Add your credentials
Create a local .env file from the example:
Copy-Item .env.example .env
On macOS or Linux, use cp .env.example .env instead. Then replace the placeholder values:
GOOGLE_TASKS_CLIENT_ID=your-client-id.apps.googleusercontent.com
GOOGLE_TASKS_CLIENT_SECRET=your-client-secret
GOOGLE_TASKS_REDIRECT_URI=http://127.0.0.1:53682/oauth2callback
The server loads this .env file from the repository directory even when it is launched from somewhere else. .env is ignored by Git.
4. Connect Codex
The simplest development setup is to add this repository as a local MCP server. Replace the example path with the absolute path to your clone:
codex mcp add google-task-mcp -- node C:\path\to\google-task-mcp\server\index.js
You can also add it in the ChatGPT desktop app under Settings → MCP servers → Add server:
- Name:
google-task-mcp - Type:
STDIO - Command:
node - Arguments: the absolute path to
server/index.js
Save the server and restart the app. Codex's MCP configuration is shared with the desktop app and IDE extension; the current options are documented in the official MCP setup guide.
This repository also contains .codex-plugin/plugin.json and .mcp.json for packaging it as a Codex plugin.
5. Authorize Google Tasks
Start a new chat and ask:
Connect my Google Tasks account.
The client should call google_tasks_get_authorization_url. Open the returned URL, approve access, return to the chat, and ask it to finish authorization. The authorization attempt expires after 10 minutes.
Try one of these prompts afterward:
- “Show my open Google Tasks.”
- “Create a task called Pay electricity bill due tomorrow.”
- “Mark my grocery task complete.”
Available tools
| Tool | Purpose |
|---|---|
google_tasks_get_authorization_url |
Start local Google OAuth authorization |
google_tasks_complete_authorization |
Finish authorization after browser consent |
google_tasks_list_tasklists |
List task lists |
google_tasks_list_tasks |
List tasks, optionally including completed or hidden tasks |
google_tasks_create_task |
Create a task or subtask |
google_tasks_update_task |
Change a task's title, notes, or due date |
google_tasks_set_task_completion |
Complete or reopen a task |
google_tasks_delete_task |
Permanently delete a task after explicit confirmation |
Task list IDs default to @default. Due dates use RFC 3339 timestamps, such as 2026-08-18T17:00:00Z; Google Tasks stores the date and may discard the time portion.
Local data and safety
- The OAuth token is stored at
%APPDATA%\google-task-mcp\token.jsonon Windows or~/.config/google-task-mcp/token.jsonon macOS and Linux. - Set
GOOGLE_TASKS_TOKEN_PATHin.envto use a different location. - Delete the token file to disconnect the Google account. You can also revoke access from your Google Account settings.
- The server requests only
https://www.googleapis.com/auth/tasks. - Task deletion requires
confirm: true; clients should show the exact task and ask before calling it. .env, token directories, logs, and dependencies are excluded from Git. Never commit credentials or tokens.
Troubleshooting
The MCP server exits immediately
Check that .env exists beside package.json and contains both GOOGLE_TASKS_CLIENT_ID and GOOGLE_TASKS_CLIENT_SECRET.
Google reports redirect_uri_mismatch
Confirm that you created a Desktop app OAuth client and kept GOOGLE_TASKS_REDIRECT_URI set to the included loopback URL.
The authorization URL expires
Run google_tasks_get_authorization_url again. Only one authorization attempt can be active at a time.
Port 53682 is already in use
Choose an unused local port in .env, restart the MCP server, and begin authorization again.
Development
The server is split by responsibility:
server/
config.js Environment and path configuration
google-auth.js OAuth callback and Google API client
index.js Server startup
mcp-result.js MCP text response formatting
tools.js Tool schemas and handlers
test/ Node.js unit tests
Useful commands:
npm run check # Syntax-check server files
npm test # Run unit tests
npm run verify # Run both checks
npm start # Start the STDIO server manually
OAuth and live Google API calls require real credentials and interactive browser consent. Unit tests do not contact Google.
License
Released under the MIT License.
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。