Directory Compare FCRS-1.0 /llms.txt
← Back to Directory

gogcli

$ gog Community High Risk
OpenClaw · Workspace & SaaS · MIT · macos / linux / windows

gogcli (gog) is an open-source Go CLI by OpenClaw providing fast terminal and agent access to Gmail, Google Calendar, Drive, Docs, Sheets, and Workspace Admin. Built specifically for scripts and AI agents with --json, --plain TSV output, --dry-run, gog schema --json, -a/--account switching, and encrypted file keyring support for headless servers.

FCRS-1.0 Score
86 /100
Good
Medium Confidence
Zero-Friction Install
brew install gogcli
CLI vs MCP Decision CLI Preferred vs MCP

gog packs Gmail, Calendar, Drive, Docs, Sheets, and Admin into one local binary with --json, --dry-run, and --plain TSV output at zero MCP context-bloat cost.

Agent-Readiness Checklist

✓ JSON Output
— Field Filtering
✓ Non-Interactive
✓ Dry-Run
— Read-Only Mode
✓ NO_COLOR Clean
✓ Self-Describing
— Official SKILL.md

Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.

FCRS-1.0 6-Dimension Breakdown

Agent-Readiness 23 / 25

Offers --json, --plain TSV, --color=never, --dry-run, -a/--account, and gog schema --json built for agent workflows.

  • --json, --plain, and gog schema --json expose clean machine contracts
  • GOG_KEYRING_BACKEND=file supports headless server automation
Trust & Safety 20 / 25

Supports --dry-run on mutations and encrypted keyring storage, though OAuth scopes span sensitive Workspace data (email, Drive, Admin).

  • --dry-run prevents unintended email sends or Drive mutations
  • Tokens encrypted in OS keychain or GOG_KEYRING_BACKEND=file
Setup & Portability 13 / 15

Single Go binary via Homebrew (brew install gogcli), go install, and GitHub releases across macOS, Linux, and Windows.

  • Available via brew install gogcli and release binaries
Utility & Efficiency 13 / 15

Consolidates six Google Workspace services into one fast, consistent CLI.

  • Covers Gmail, Calendar, Drive, Docs, Sheets, and Admin
Maintenance & Lineage 8 / 10

Active community project (openclaw/gogcli) under MIT license, though not an official Google binary.

  • MIT open-source CLI maintained by OpenClaw
Docs & Verifiability 9 / 10

Clear documentation at gogcli.sh, detailed README, and machine-readable gog schema --json.

  • Official site gogcli.sh plus built-in gog schema --json

Security, Auth & Guardrails

Auth Modes
OAuth Browser OS Keychain Service Account Config File
Credential Storage

Stores OAuth client credentials and refresh tokens in the OS keychain by default, or in an encrypted file backend via GOG_KEYRING_BACKEND=file and GOG_KEYRING_PASSWORD for headless Linux/containers.

Side Effects
Read-Only Local Write Remote Write Destructive
Cost & Quotas

MIT open-source CLI; uses your Google account or paid Google Workspace OAuth credentials.

Copyable Guardrail for CLAUDE.md / AGENTS.md
# gogcli (gog) Agent Rules
- Always pass `--json` (or `--plain`) and explicit `-a <account>` on multi-account setups.
- Pass `--dry-run` before sending Gmail messages, modifying Calendar events, or deleting Drive files.
- On headless Linux hosts, configure `GOG_KEYRING_BACKEND=file` and `GOG_KEYRING_PASSWORD` instead of interactive GUI keyrings.

Agent-Ready Command Recipes

Safe Read-Only Queries

Search Gmail messages as JSON
gog gmail search 'is:unread' --json -a [email protected]

Queries unread Gmail threads for a specific account and returns structured JSON.

Inspect CLI command schema as JSON
gog schema --json

Outputs the full command tree, parameters, and exit codes for programmatic agent discovery.

Controlled Writes & Previews

Preview sending an email with --dry-run
gog gmail send --to [email protected] --subject "Status" --body "Ready" --dry-run --json -a [email protected]

Validates and prints the intended Gmail send payload without dispatching an actual email.

Strengths for Agents

  • + Consistent --json, --plain, --dry-run, and gog schema --json across Google Workspace services.
  • + Encrypted file keyring backend (GOG_KEYRING_BACKEND=file) avoids GUI keyring hangs on servers.

Caveats & Pitfalls

  • ! Initial setup requires registering your own Google Cloud OAuth client JSON and completing a browser consent flow.
  • ! Third-party community CLI (openclaw/gogcli), not first-party Google software.

Tested Agent Hosts

Claude Code Codex CLI Gemini CLI