简介
Google Workspace
原始描述
Manage Google Calendar, Google Drive, and Google Sheets through MyBrandMetrics-connected Google data sources and the local Google Workspace CLI. Use it to li...
通过你的 Agent 添加
安装目录:google-workspace/(目录名取自 SKILL.md 的 frontmatter name,不是 URL 里的 slug)。
点「快速安装」复制一段指令贴给你的 Agent:它会先下载到 /tmp、把文件清单和校验值给你看,你确认之后才解压安装。不会一步装完、也不改系统其它位置。
或者手动安装
包是「根级 SKILL.md + 作者附带的文件」,解压到上面的 <slug>/ 目录即可;
目录名不用换,也不要把包直接解压到 skills 根目录。
技能申请的权限由作者决定:装之前先看清单里有没有脚本、它会读写什么。
技能正文
name: google-workspace
description: Use Google Workspace CLI (gws) for Drive, Docs, Sheets, Gmail, Calendar, Chat, and related Workspace API tasks.
homepage: https://github.com/googleworkspace/cli
metadata:
openclaw:
toolNames: [google_workspace, gws]
capabilities: [google-workspace, google-docs, google-drive, google-sheets, gmail, google-calendar, google-chat]
requires:
bins: [gws]
Google Workspace CLI
Use gws when the task is about Google Workspace resources or Google Workspace API automation.
Prefer gws over generic HTTP calls when possible because it already knows the Workspace API surface and returns structured JSON by default.
Rules
- Start with read/list/get commands before mutating Workspace state.
- Confirm IDs first: document IDs, spreadsheet IDs, file IDs, message IDs, calendar IDs, space IDs.
- Do not run interactive auth flows from an agent tool call. If auth is missing, report that
gws needs to be configured in plugin settings or via a manual terminal login.
- Keep commands machine-readable. Prefer JSON output and parse it instead of scraping human text.
- For large list operations, limit the scope first, then page or filter.
Common Commands
gws needs to be configured in plugin settings or via a manual terminal login.Check installation and health:
gws doctor
Inspect help for a resource or method:
gws help
gws drive help
gws drive files help
Google Docs:
gws docs get --document-id <DOC_ID>
Google Drive:
gws drive files list --params '{"pageSize":10}'
gws drive files get --file-id <FILE_ID>
Google Sheets:
gws sheets spreadsheets get --spreadsheet-id <SPREADSHEET_ID>
Gmail:
gws gmail users messages list --user-id me --params '{"maxResults":10}'
gws gmail users messages get --user-id me --message-id <MESSAGE_ID>
Google Calendar:
gws calendar events list --calendar-id primary --params '{"maxResults":10,"singleEvents":true}'
Google Chat:
gws chat spaces messages list --parent spaces/<SPACE_ID>
Tool Usage In SwarmClaw
When using the google_workspace tool:
- Put the
gwscommand after the binary intoargs, for example:{"args":["drive","files","list"],"params":{"pageSize":5}} - Use
paramsfor--params - Use
jsonInputfor--json - Use
pageAll: truewhen you intentionally want all pages - Use
dryRun: truebefore risky mutations if you are unsure
Error Handling
- If
gws is missing: tell the user to install Google Workspace CLI.
- If auth is missing or expired: tell the user to configure the plugin settings or authenticate
gws manually.
- If a command fails because an ID is missing: switch to a list/search command first and find the right ID.
gws is missing: tell the user to install Google Workspace CLI.gws manually.