此仓库提供了一个与Google日历API集成的模型上下文协议(MCP)服务器。它允许用户列出、创建、删除和更新日历事件。该服务器设计用于与Anthropic的Claude桌面作为MCP客户端一起工作。
安装UV包管理器: 按照官方UV安装指南中的说明进行操作。
克隆仓库并设置环境:
git clone https://github.com/rsc1102/Google_Calendar_MCP.git
cd Google_Calendar_MCP
uv sync
创建Google云凭证:
credentials.json文件。credentials.json放置在Google_Calendar_MCP目录中。定位配置文件:
在系统上打开claude_desktop_config.json文件:
Linux/macOS:
code ~/Library/Application\ Support/Claude/claude_desktop_config.json
Windows (PowerShell):
code $env:AppData\Claude\claude_desktop_config.json
添加MCP服务器配置:
在mcpServers部分添加以下内容:
{
"mcpServers": {
"calendar": {
"command": "uv",
"args": [
"--directory",
"/ABSOLUTE/PATH/TO/PARENT/FOLDER/Google_Calendar_MCP",
"run",
"calendar_mcp.py"
]
}
}
}
重启Claude桌面。
在Claude桌面中创建新项目。
设置时区:
在项目的知识部分,使用IANA时区格式定义本地时区(例如,timeZone="America/New_York")。
开始聊天: 开始与Claude互动以管理您的Google日历事件。 注意: 首次使用服务器时,Google会提示您进行身份验证并授予访问日历的权限。
https://github.com/user-attachments/assets/75da4943-15c4-4ec2-bc5d-af4af3509031
对于问题或疑问,请在此仓库中提交问题。