gccli

GitHub

Google Calendar CLI工具,用于列出日历、查看/创建/更新事件及检查可用性。支持OAuth配置与账户管理,提供命令行接口进行日程操作。

gccli/SKILL.md badlogic/pi-skills

触发场景

用户需要查询或管理Google日历事件 用户请求检查特定时间段的空闲状态

安装

npx skills add badlogic/pi-skills --skill gccli -g -y
更多选项

非标准路径

npx skills add https://github.com/badlogic/pi-skills/tree/main/gccli -g -y

不安装直接使用

npx skills use badlogic/pi-skills@gccli

指定 Agent (Claude Code)

npx skills add badlogic/pi-skills --skill gccli -a claude-code -g -y

安装 repo 全部 skill

npx skills add badlogic/pi-skills --all -g -y

预览 repo 内 skill

npx skills add badlogic/pi-skills --list

SKILL.md

Frontmatter
{
    "name": "gccli",
    "description": "Google Calendar CLI for listing calendars, viewing\/creating\/updating events, and checking availability."
}

Google Calendar CLI

Command-line interface for Google Calendar operations.

Installation

npm install -g @mariozechner/gccli

Setup

Google Cloud Console (one-time)

  1. Create a new project (or select existing)
  2. Enable the Google Calendar API
  3. Set app name in OAuth branding
  4. Add test users (all Gmail addresses you want to use)
  5. Create OAuth client:
    • Click "Create Client"
    • Application type: "Desktop app"
    • Download the JSON file

Configure gccli

First check if already configured:

gccli accounts list

If no accounts, guide the user through setup:

  1. Ask if they have a Google Cloud project with Calendar API enabled
  2. If not, walk them through the Google Cloud Console steps above
  3. Have them download the OAuth credentials JSON
  4. Run: gccli accounts credentials ~/path/to/credentials.json
  5. Run: gccli accounts add <email> (use --manual for browserless OAuth)

Usage

Run gccli --help for full command reference.

Common operations:

  • gccli <email> calendars - List all calendars
  • gccli <email> events <calendarId> [--from <dt>] [--to <dt>] - List events
  • gccli <email> event <calendarId> <eventId> - Get event details
  • gccli <email> create <calendarId> --summary <s> --start <dt> --end <dt> - Create event
  • gccli <email> freebusy <calendarIds> --from <dt> --to <dt> - Check availability

Use primary as calendarId for the main calendar.

Date/Time Format

  • Timed events: YYYY-MM-DDTHH:MM:SSZ (UTC) or YYYY-MM-DDTHH:MM:SS (local)
  • All-day events: YYYY-MM-DD with --all-day flag

Data Storage

  • ~/.gccli/credentials.json - OAuth client credentials
  • ~/.gccli/accounts.json - Account tokens

版本历史

  • 90bb51c 当前 2026-07-25 09:42

同 Skill 集合

browser-tools/SKILL.md
gdcli/SKILL.md
gmcli/SKILL.md
transcribe/SKILL.md
vscode/SKILL.md
youtube-transcript/SKILL.md

元信息

文件数
0
版本
90bb51c
Hash
3a687e1d
收录时间
2026-07-25 09:42

首页 - Wiki
Copyright © 2011-2026 iteam. Current version is 2.156.0. UTC+08:00, 2026-11-17 21:00
浙ICP备14020137号-1