Google Calendar MCP Server
Google 日历 MCP 服务器
使用模型上下文协议 (MCP) 通过 Claude Desktop 与您的 Google 日历进行交互。
这是一个基于 TypeScript 的 MCP 服务器,实现了 Google 日历集成。它演示了 MCP 的核心概念,同时提供:
通过 MCP URI 管理日历事件
用于创建和修改事件的工具
生成日历洞察的提示
特征
资源
通过 MCP URI 访问日历事件
每个活动都有标题、时间、描述和参加者
具有适当 MIME 类型的结构化事件数据
工具
create_event- 创建新的日历事件以标题、时间和其他事件详细信息作为参数
直接与 Google 日历 API 接口
list_events- 查看即将发生的日历事件[添加您已实现的其他工具]
提示
analyze_schedule- 生成有关日历的见解包括即将举行的活动作为嵌入式资源
返回 LLM 分析的结构化提示
[添加您已实施的其他提示]
Related MCP server: Google Calendar MCP Server
先决条件
Node.js(v14 或更高版本)
启用了日历 API 的 Google Cloud 项目
OAuth 2.0 客户端凭据
发展
按照devbox.sh上的说明安装 devbox
curl -fsSL https://get.jetpack.io/devbox | bash在项目目录中初始化devbox:
devbox init启动 devbox shell:
devbox shell安装依赖项:
npm install构建服务器:
npm run build对于使用自动重建的开发:
npm run watch安装
要与 Claude Desktop 一起使用,请添加服务器配置:
在 MacOS 上: ~/Library/Application Support/Claude/claude_desktop_config.json在 Windows 上: %APPDATA%/Claude/claude_desktop_config.json
{
"mcpServers": {
"Google Calendar": {
"command": "/path/to/Google Calendar/build/index.js"
}
}
}首次设置
设置 Google Cloud 凭据:
创建新项目或选择现有项目
启用 Google 日历 API
创建 OAuth 2.0 凭据(桌面应用程序类型)
下载客户端机密 JSON 文件
将其重命名为
.client_secret.json并将其放在项目根目录中
初始身份验证:
首次运行服务器时,它将提供一个身份验证 URL
在浏览器中访问 URL
授予请求的权限
复制提供的授权码
将代码粘贴回 CLI 提示符
调试
由于 MCP 服务器通过 stdio 进行通信,调试起来可能比较困难。我们推荐使用MCP Inspector ,它以包脚本的形式提供:
npm run inspector检查器将提供一个 URL 来访问浏览器中的调试工具。
This server cannot be deployed
Maintenance
Related MCP Connectors
Calendar API for AI agents: events, availability, Google/Microsoft setup, scheduling, and iCal.
Multiple Google accounts (Gmail, Calendar, Drive, Contacts, Tasks) in one Claude connector.
GDPR-compliant calendar access for AI assistants: read, create, edit, RSVP. Google, MS 365, Apple.
Schedule and manage Google Calendar events directly from your workspace. Check availability, view…
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceConnects Claude Desktop to Google Calendar for local calendar management including adding, updating, and deleting events, checking schedules, and calculating travel time between meetings.1-
- FlicenseNot gradedqualityDmaintenanceEnables natural language interaction with Google Calendar via the Model Context Protocol, allowing LLMs like Claude to read and manage calendar events through the Google Calendar v3 API.2-
- AlicenseAqualityDmaintenanceIntegrates Google Calendar with the Model Context Protocol to manage events, search agendas, and check availability. It features Home Assistant integration and SSE support for remote access through Claude Desktop.11MIT
- AlicenseBqualityCmaintenanceEnables creating, modifying, and checking Google Calendar events from Claude desktop app using MCP protocol with secure OAuth2 authentication.22MIT