谷歌日历MCP
A. 模型完成提示(MCP) 用于与谷歌日历交互的插件。
特性
- 在Google日历中创建可自定义的事件:
- 开始和结束时间 - 描述 - 位置 - 与会者 - 时区
安装
- 克隆此存储库:
git clone https://github.com/ITworkonline/GoogleCalendarMCP.git
cd GoogleCalendarMCP- 创建虚拟环境并安装依赖项:
python -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
pip install -e .- 设置Google日历API:
- 转到 谷歌云控制台 - 创建新项目 - 启用Google日历API - 创建OAuth 2.0凭据(桌面应用程序) - 下载凭据JSON文件并将其另存为 credentials.json 在项目根中
用法
from GoogleCalendarMCP.main import create_event
# Create a calendar event
result = await create_event(
summary="Meeting with Team",
start_time="2025-04-01T10:00:00",
end_time="2025-04-01T11:00:00",
description="Discuss project progress",
location="Conference Room 3",
attendees=["colleague@example.com"],
timezone="America/New_York"
)认证
您第一次运行该程序时,它将打开一个浏览器窗口,让您使用您的谷歌帐户进行身份验证。认证后,a token.json 将创建一个文件来存储您的凭据,以便后续运行。
许可证
麻省理工学院
