google-calendar-automation
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseGoogle Calendar Automation via Rube MCP
通过Rube MCP实现Google Calendar自动化
Automate Google Calendar workflows including event creation, scheduling, availability checks, attendee management, and calendar browsing through Composio's Google Calendar toolkit.
通过Composio的Google Calendar工具包自动化日历工作流,包括事件创建、日程安排、空闲时间查询、参会人管理以及日历浏览。
Prerequisites
前提条件
- Rube MCP must be connected (RUBE_SEARCH_TOOLS available)
- Active Google Calendar connection via with toolkit
RUBE_MANAGE_CONNECTIONSgooglecalendar - Always call first to get current tool schemas
RUBE_SEARCH_TOOLS
- 已连接Rube MCP(可使用RUBE_SEARCH_TOOLS)
- 通过建立了与
RUBE_MANAGE_CONNECTIONS工具包的有效Google Calendar连接googlecalendar - 请始终先调用以获取当前工具的模式
RUBE_SEARCH_TOOLS
Setup
设置步骤
Get Rube MCP: Add as an MCP server in your client configuration. No API keys needed — just add the endpoint and it works.
https://rube.app/mcp- Verify Rube MCP is available by confirming responds
RUBE_SEARCH_TOOLS - Call with toolkit
RUBE_MANAGE_CONNECTIONSgooglecalendar - If connection is not ACTIVE, follow the returned auth link to complete Google OAuth
- Confirm connection status shows ACTIVE before running any workflows
获取Rube MCP: 在客户端配置中添加作为MCP服务器。无需API密钥——只需添加该端点即可使用。
https://rube.app/mcp- 确认可正常响应,以此验证Rube MCP可用
RUBE_SEARCH_TOOLS - 调用并指定工具包为
RUBE_MANAGE_CONNECTIONSgooglecalendar - 如果连接未处于活跃状态,请按照返回的授权链接完成Google OAuth验证
- 在运行任何工作流之前,确认连接状态显示为活跃
Core Workflows
核心工作流
1. Create and Manage Events
1. 创建与管理事件
When to use: User wants to create, update, or delete calendar events
Tool sequence:
- - Identify target calendar ID [Prerequisite]
GOOGLECALENDAR_LIST_CALENDARS - - Get current time with proper timezone [Optional]
GOOGLECALENDAR_GET_CURRENT_DATE_TIME - - Check availability before booking [Optional]
GOOGLECALENDAR_FIND_FREE_SLOTS - - Create the event [Required]
GOOGLECALENDAR_CREATE_EVENT - - Update specific fields of an existing event [Alternative]
GOOGLECALENDAR_PATCH_EVENT - - Full replacement update of an event [Alternative]
GOOGLECALENDAR_UPDATE_EVENT - - Delete an event [Optional]
GOOGLECALENDAR_DELETE_EVENT
Key parameters:
- : Use 'primary' for main calendar, or specific calendar ID
calendar_id - : ISO 8601 format 'YYYY-MM-DDTHH:MM:SS' (NOT natural language)
start_datetime - : IANA timezone name (e.g., 'America/New_York', NOT 'EST' or 'PST')
timezone - : Hours (0+)
event_duration_hour - : Minutes (0-59 only; NEVER use 60+)
event_duration_minutes - : Event title
summary - : Array of email addresses (NOT names)
attendees - : Free-form text for event location
location
Pitfalls:
- must be ISO 8601; natural language like 'tomorrow' is rejected
start_datetime - max is 59; use
event_duration_minutesinstead ofevent_duration_hour=1event_duration_minutes=60 - must be IANA identifier; abbreviations like 'EST', 'PST' are NOT valid
timezone - only accepts email addresses, not names; resolve names first
attendees - Google Meet link creation defaults to true; may fail on personal Gmail accounts (graceful fallback)
- Organizer is auto-added as attendee unless
exclude_organizer=true
适用场景: 用户需要创建、更新或删除日历事件
工具序列:
- - 确定目标日历ID [前提步骤]
GOOGLECALENDAR_LIST_CALENDARS - - 获取带有时区的当前时间 [可选]
GOOGLECALENDAR_GET_CURRENT_DATE_TIME - - 预订前查询空闲时间 [可选]
GOOGLECALENDAR_FIND_FREE_SLOTS - - 创建事件 [必需]
GOOGLECALENDAR_CREATE_EVENT - - 更新现有事件的特定字段 [替代方案]
GOOGLECALENDAR_PATCH_EVENT - - 完全替换更新事件内容 [替代方案]
GOOGLECALENDAR_UPDATE_EVENT - - 删除事件 [可选]
GOOGLECALENDAR_DELETE_EVENT
关键参数:
- : 主日历使用'primary',或指定具体的日历ID
calendar_id - : ISO 8601格式(如'YYYY-MM-DDTHH:MM:SS'),不接受自然语言
start_datetime - : IANA时区名称(例如'America/New_York',不接受'EST'或'PST'这类缩写)
timezone - : 时长(小时,0及以上)
event_duration_hour - : 时长(分钟,仅0-59;请勿使用60及以上的值)
event_duration_minutes - : 事件标题
summary - : 邮箱地址数组(不接受姓名)
attendees - : 事件地点的自由文本描述
location
注意事项:
- 必须为ISO 8601格式;'明天'这类自然语言会被拒绝
start_datetime - 最大值为59;如需1小时,请使用
event_duration_minutes而非event_duration_hour=1event_duration_minutes=60 - 必须为IANA标识符;'EST'、'PST'这类缩写无效
timezone - 仅接受邮箱地址,不接受姓名;请先解析姓名对应的邮箱
attendees - Google Meet链接创建默认开启,在个人Gmail账户上可能失败(需优雅降级处理)
- 组织者会自动被添加为参会人,除非设置
exclude_organizer=true
2. List and Search Events
2. 列出与搜索事件
When to use: User wants to find or browse events on their calendar
Tool sequence:
- - Get available calendars [Prerequisite]
GOOGLECALENDAR_LIST_CALENDARS - - Search by title/keyword with time bounds [Required]
GOOGLECALENDAR_FIND_EVENT - - List events in a time range [Alternative]
GOOGLECALENDAR_EVENTS_LIST - - List instances of a recurring event [Optional]
GOOGLECALENDAR_EVENTS_INSTANCES
Key parameters:
- /
query: Free-text search (matches summary, description, location, attendees)q - : Lower bound (RFC3339 with timezone offset, e.g., '2024-01-01T00:00:00-08:00')
timeMin - : Upper bound (RFC3339 with timezone offset)
timeMax - : true to expand recurring events into instances
singleEvents - : 'startTime' (requires singleEvents=true) or 'updated'
orderBy - : Results per page (max 2500)
maxResults
Pitfalls:
- Timezone warning: UTC timestamps (ending in 'Z') don't align with local dates; use local timezone offsets instead
- Example: '2026-01-19T00:00:00Z' covers 2026-01-18 4pm to 2026-01-19 4pm in PST
- Omitting /
timeMinscans the full calendar and can be slowtimeMax - in response means more results; paginate until absent
pageToken - requires
orderBy='startTime'singleEvents=true
适用场景: 用户需要查找或浏览日历上的事件
工具序列:
- - 获取可用日历列表 [前提步骤]
GOOGLECALENDAR_LIST_CALENDARS - - 按标题/关键词结合时间范围搜索事件 [必需]
GOOGLECALENDAR_FIND_EVENT - - 列出指定时间范围内的事件 [替代方案]
GOOGLECALENDAR_EVENTS_LIST - - 列出重复事件的所有实例 [可选]
GOOGLECALENDAR_EVENTS_INSTANCES
关键参数:
- /
query: 自由文本搜索(匹配事件标题、描述、地点、参会人)q - : 时间范围下限(带时区偏移的RFC3339格式,例如'2024-01-01T00:00:00-08:00')
timeMin - : 时间范围上限(带时区偏移的RFC3339格式)
timeMax - : 设置为true可将重复事件展开为单独实例
singleEvents - : 排序方式,可选'startTime'(需设置singleEvents=true)或'updated'
orderBy - : 每页返回的结果数量(最大2500)
maxResults
注意事项:
- 时区警告: 以'Z'结尾的UTC时间戳与本地日期不匹配;请使用带本地时区偏移的时间戳
- 示例: '2026-01-19T00:00:00Z'对应PST时区的2026-01-18 16:00到2026-01-19 16:00
- 若省略/
timeMin,会扫描整个日历,可能导致响应缓慢timeMax - 响应中的表示还有更多结果;需循环调用直到该字段不存在
pageToken - 使用时必须设置
orderBy='startTime'singleEvents=true
3. Manage Attendees and Invitations
3. 管理参会人与邀请
When to use: User wants to add, remove, or update event attendees
Tool sequence:
- or
GOOGLECALENDAR_FIND_EVENT- Find the event [Prerequisite]GOOGLECALENDAR_EVENTS_LIST - - Add attendees (replaces entire attendees list) [Required]
GOOGLECALENDAR_PATCH_EVENT - - Remove a specific attendee by email [Required]
GOOGLECALENDAR_REMOVE_ATTENDEE
Key parameters:
- : Unique event identifier (opaque string, NOT the event title)
event_id - : Full list of attendee emails (PATCH replaces entire list)
attendees - : Email to remove
attendee_email - : 'all', 'externalOnly', or 'none'
send_updates
Pitfalls:
- is a technical identifier, NOT the event title; always search first to get the ID
event_id - attendees field replaces the entire list; include existing attendees to avoid removing them
PATCH_EVENT - Attendee names cannot be resolved; always use email addresses
- Use to resolve names to emails before managing attendees
GMAIL_SEARCH_PEOPLE
适用场景: 用户需要添加、移除或更新事件参会人
工具序列:
- 或
GOOGLECALENDAR_FIND_EVENT- 查找目标事件 [前提步骤]GOOGLECALENDAR_EVENTS_LIST - - 添加参会人(会替换整个参会人列表) [必需]
GOOGLECALENDAR_PATCH_EVENT - - 通过邮箱移除特定参会人 [必需]
GOOGLECALENDAR_REMOVE_ATTENDEE
关键参数:
- : 事件唯一标识符(随机字符串,并非事件标题)
event_id - : 完整的参会人邮箱列表(PATCH操作会替换整个列表)
attendees - : 要移除的参会人邮箱
attendee_email - : 发送更新的范围,可选'all'、'externalOnly'或'none'
send_updates
注意事项:
- 是技术标识符,并非事件标题;请务必先搜索获取该ID
event_id - 的参会人字段会替换整个列表;若要保留现有参会人,需将其包含在新列表中
PATCH_EVENT - 无法解析参会人姓名;请始终使用邮箱地址
- 可使用将姓名解析为邮箱后再管理参会人
GMAIL_SEARCH_PEOPLE
4. Check Availability and Free/Busy Status
4. 查询空闲/忙碌状态与可用时段
When to use: User wants to find available time slots or check busy periods
Tool sequence:
- - Identify calendars to check [Prerequisite]
GOOGLECALENDAR_LIST_CALENDARS - - Get current time with timezone [Optional]
GOOGLECALENDAR_GET_CURRENT_DATE_TIME - - Find free intervals across calendars [Required]
GOOGLECALENDAR_FIND_FREE_SLOTS - - Get raw busy periods for computing gaps [Fallback]
GOOGLECALENDAR_FREE_BUSY_QUERY - - Book a confirmed slot [Required]
GOOGLECALENDAR_CREATE_EVENT
Key parameters:
- : List of calendar IDs to check (e.g., ['primary'])
items - /
time_min: Query interval (defaults to current day if omitted)time_max - : IANA timezone for interpreting naive timestamps
timezone - : Max calendars (1-50)
calendarExpansionMax - : Max members per group (1-100)
groupExpansionMax
Pitfalls:
- Maximum span ~90 days per Google Calendar freeBusy API limit
- Very long ranges or inaccessible calendars yield empty/invalid results
- Only calendars with at least freeBusyReader access are visible
- Free slots responses may normalize to UTC ('Z'); check offsets
- requires RFC3339 timestamps with timezone
GOOGLECALENDAR_FREE_BUSY_QUERY
适用场景: 用户需要查找可用时段或查询忙碌时段
工具序列:
- - 确定要查询的日历 [前提步骤]
GOOGLECALENDAR_LIST_CALENDARS - - 获取带有时区的当前时间 [可选]
GOOGLECALENDAR_GET_CURRENT_DATE_TIME - - 跨日历查找空闲时段 [必需]
GOOGLECALENDAR_FIND_FREE_SLOTS - - 获取原始忙碌时段数据以计算空闲间隙 [备选方案]
GOOGLECALENDAR_FREE_BUSY_QUERY - - 预订确认后的空闲时段 [必需]
GOOGLECALENDAR_CREATE_EVENT
关键参数:
- : 要查询的日历ID列表(例如['primary'])
items - /
time_min: 查询时间范围(若省略则默认查询当天)time_max - : 用于解析无时区时间戳的IANA时区
timezone - : 最多查询的日历数量(1-50)
calendarExpansionMax - : 每个群组最多查询的成员数量(1-100)
groupExpansionMax
注意事项:
- Google Calendar freeBusy API的单次查询最大时间跨度约为90天
- 过长的时间范围或无法访问的日历会返回空或无效结果
- 仅能查询具有freeBusyReader权限的日历
- 空闲时段响应可能会被标准化为UTC时间(以'Z'结尾);请检查时区偏移
- 要求使用带时区的RFC3339时间戳
GOOGLECALENDAR_FREE_BUSY_QUERY
Common Patterns
常见模式
ID Resolution
ID解析
- Calendar name -> calendar_id: to enumerate all calendars
GOOGLECALENDAR_LIST_CALENDARS - Event title -> event_id: or
GOOGLECALENDAR_FIND_EVENTGOOGLECALENDAR_EVENTS_LIST - Attendee name -> email:
GMAIL_SEARCH_PEOPLE
- 日历名称 -> calendar_id: 使用枚举所有日历
GOOGLECALENDAR_LIST_CALENDARS - 事件标题 -> event_id: 使用或
GOOGLECALENDAR_FIND_EVENT查询GOOGLECALENDAR_EVENTS_LIST - 参会人姓名 -> 邮箱: 使用解析
GMAIL_SEARCH_PEOPLE
Timezone Handling
时区处理
- Always use IANA timezone identifiers (e.g., 'America/Los_Angeles')
- Use to get current time in user's timezone
GOOGLECALENDAR_GET_CURRENT_DATE_TIME - When querying events for a local date, use timestamps with local offset, NOT UTC
- Example: '2026-01-19T00:00:00-08:00' for PST, NOT '2026-01-19T00:00:00Z'
- 请始终使用IANA时区标识符(例如'America/Los_Angeles')
- 使用获取用户时区的当前时间
GOOGLECALENDAR_GET_CURRENT_DATE_TIME - 查询本地日期的事件时,请使用带本地时区偏移的时间戳,而非UTC时间戳
- 示例: 对于PST时区,使用'2026-01-19T00:00:00-08:00'而非'2026-01-19T00:00:00Z'
Pagination
分页处理
- returns
GOOGLECALENDAR_EVENTS_LIST; iterate until absentnextPageToken - also paginates; use
GOOGLECALENDAR_LIST_CALENDARSpage_token
- 会返回
GOOGLECALENDAR_EVENTS_LIST;需循环调用直到该字段不存在nextPageToken - 同样支持分页;请使用
GOOGLECALENDAR_LIST_CALENDARS参数page_token
Known Pitfalls
已知注意事项
- Natural language dates: NOT supported; all dates must be ISO 8601 or RFC3339
- Timezone mismatch: UTC timestamps don't align with local dates for filtering
- Duration limits: max 59; use hours for longer durations
event_duration_minutes - IANA timezones only: 'EST', 'PST', etc. are NOT valid; use 'America/New_York'
- Event IDs are opaque: Always search to get event_id; never guess or construct
- Attendees as emails: Names cannot be used; resolve with GMAIL_SEARCH_PEOPLE
- PATCH replaces attendees: Include all desired attendees in the array, not just new ones
- Conference limitations: Google Meet may fail on personal accounts (graceful fallback)
- Rate limits: High-volume searches can trigger 403/429; throttle between calls
- 自然语言日期: 不支持;所有日期必须为ISO 8601或RFC3339格式
- 时区不匹配: UTC时间戳与本地日期过滤不兼容
- 时长限制: 最大值为59;更长时长请使用小时参数
event_duration_minutes - 仅支持IANA时区: 'EST'、'PST'等缩写无效;请使用'America/New_York'这类标识符
- Event ID为随机字符串: 请务必通过查询获取event_id;切勿猜测或自行构造
- 参会人需用邮箱: 不支持姓名;请使用GMAIL_SEARCH_PEOPLE解析为邮箱
- PATCH操作会替换参会人列表: 请在数组中包含所有需要保留的参会人,而非仅新增的
- 会议链接限制: Google Meet在个人账户上可能无法创建(需优雅降级)
- 速率限制: 高频率搜索可能触发403/429错误;请在调用之间添加节流
Quick Reference
快速参考
| Task | Tool Slug | Key Params |
|---|---|---|
| List calendars | | |
| Create event | | |
| Update event | | |
| Delete event | | |
| Search events | | |
| List events | | |
| Recurring instances | | |
| Find free slots | | |
| Free/busy query | | |
| Remove attendee | | |
| Get current time | | |
| Get calendar | | |
| 任务 | 工具标识 | 关键参数 |
|---|---|---|
| 列出日历 | | |
| 创建事件 | | |
| 更新事件 | | |
| 删除事件 | | |
| 搜索事件 | | |
| 列出事件 | | |
| 重复事件实例 | | |
| 查找空闲时段 | | |
| 空闲/忙碌查询 | | |
| 移除参会人 | | |
| 获取当前时间 | | |
| 获取日历信息 | | |