Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "gws",
"version": "1.43.1",
"version": "1.44.0",
"description": "Unofficial Google Workspace CLI skills (Gmail, Calendar, Drive, Docs, Sheets, Slides, Tasks, Chat, Forms, Contacts, Groups, Keep, Workspace Events, Search) and optional read-only session context hooks.",
"author": {
"name": "Omri Ariav",
Expand Down
6 changes: 3 additions & 3 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@

| Service | Commands |
|---------|----------|
| `auth` | login, logout, status (OAuth default; `auth_mode` supports service-account-dwd and service-account-app) |
| `auth` | login (`--readonly`, `--add`), logout, status (OAuth default; `auth_mode` supports service-account-dwd and service-account-app; `GWS_ACCESS_TOKEN` supplies an external token) |
| `gmail` | list, read, links, thread, send, reply, forward, labels, label, archive, trash, event-id, untrash, delete, batch-modify, batch-delete, trash-thread, untrash-thread, delete-thread, label-info, create-label, update-label, delete-label, drafts, draft, create-draft, update-draft, send-draft, delete-draft, attachment |
| `calendar` | list, events, create, update, delete, rsvp, get, quick-add, instances, move, get-calendar, create-calendar, update-calendar, delete-calendar, clear, subscribe, unsubscribe, calendar-info, update-subscription, acl, share, unshare, update-acl, freebusy, colors, settings |
| `calendar` | list, events, create, update, delete, rsvp, get, quick-add, instances, move, get-calendar, create-calendar, update-calendar, delete-calendar, clear, subscribe, unsubscribe, calendar-info, update-subscription, acl, share, unshare, update-acl, freebusy, suggest-time, colors, settings |
| `tasks` | lists, list, list-info, create, create-list, update, update-list, delete-list, get, delete, complete, reopen, move, clear |
| `drive` | list, search, info, download, upload, create-folder, move, delete, copy, convert, comments, approvals, approval, start-approval, approve, decline, reassign-approval, cancel-approval, comment-approval, permissions, share, unshare, permission, update-permission, revisions, revision, delete-revision, replies, reply, get-reply, delete-reply, comment, add-comment, delete-comment, resolve-comment, unresolve-comment, export, empty-trash, update, shared-drives, shared-drive, create-drive, delete-drive, update-drive, about, changes, activity |
| `docs` | read, info, create, append, insert, replace, replace-content, delete, add-table, format, set-paragraph-style, add-list, remove-list, trash, add-tab, delete-tab, rename-tab, add-image, insert-table-row, delete-table-row, insert-table-col, delete-table-col, merge-cells, unmerge-cells, pin-rows, page-break, section-break, add-header, delete-header, add-footer, delete-footer, add-named-range, delete-named-range, add-footnote, delete-object, replace-image, replace-named-range, update-style, update-section-style, update-table-cell-style, update-table-col-properties, update-table-row-style |
Expand Down Expand Up @@ -52,7 +52,7 @@ go run ./cmd/gws # or go run .

## Current Version

**v1.43.1** - Skill audit and version consistency: every source skill version now tracks the release version (enforced by test), with gws-events cross-references and service-account-app boundary clarifications in the chat and drive skills.
**v1.44.0** - Agent-safety release: least-privilege login (`auth login --readonly` / `--add`), external access tokens (`GWS_ACCESS_TOKEN`), `--schema` / `--show-scopes` introspection, an opt-in confirmation gate for sensitive commands (`GWS_CONFIRM_SENSITIVE`, `--yes`), `calendar suggest-time`, and OS-held locking for login state and token refresh.

## Roadmap

Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ PKG := ./cmd/gws
BUILD_DIR := ./bin

# Version info
VERSION ?= 1.43.1
VERSION ?= 1.44.0
COMMIT := $(shell git rev-parse --short HEAD 2>/dev/null || echo "unknown")
BUILD_DATE := $(shell date -u +"%Y-%m-%dT%H:%M:%SZ")
LDFLAGS := -ldflags "-X github.com/omriariav/workspace-cli/cmd.Version=$(VERSION) \
Expand Down
21 changes: 21 additions & 0 deletions RELEASES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,26 @@
# Releases

## v1.44.0

**Agent Safety: Least-Privilege Login, External Tokens, Introspection, Confirmation Gate, Suggest-Time**

- **Least-privilege login** ([#225](https://github.com/omriariav/workspace-cli/issues/225)): `gws auth login --readonly` requests only read-only scopes, and `--add --services X` extends the stored authorization instead of replacing it (same account required; previously granted scopes are re-requested and verified). `gws auth status` reports per-service access (`full`, `readonly`, `partial`, `partial-readonly`). Insufficient-scope errors carry a hint naming the login that grants the missing access.
- **Introspection** ([#226](https://github.com/omriariav/workspace-cli/issues/226)): global `--schema` and `--show-scopes` print JSON describing a command (flags, subcommands, whether the confirmation gate covers it, the scopes `gws auth login` requests for its service) and exit without calling any API or needing credentials.
- **External access token** ([#227](https://github.com/omriariav/workspace-cli/issues/227)): `GWS_ACCESS_TOKEN` / `--access-token` supply an externally managed OAuth token, used as-is (no refresh, nothing stored). A supplied-but-empty token is an error, never a fallback to the stored login. While one is set, the Chat space-cache commands and `auth logout` refuse to run, `chat members` skips its name cache, and session hooks add no Workspace context.
- **Confirmation gate** ([#228](https://github.com/omriariav/workspace-cli/issues/228)): opt-in via `GWS_CONFIRM_SENSITIVE` / `confirm_sensitive`. Commands that send, share, delete or destroy data show the invocation and ask before running; `--yes` skips the prompt; without a terminal they fail with `confirmation required`. A setting that cannot be understood, or a config file that cannot be loaded, stops sensitive commands rather than switching the gate off. Off by default.
- **`gws calendar suggest-time`** ([#229](https://github.com/omriariav/workspace-cli/issues/229)): finds free meeting slots across calendars and attendees inside working hours. Unreadable calendars fail the command unless `--allow-partial` is given.
- **Token refresh and locking**: refreshes of the stored login are serialized across processes with an OS-held lock (`flock` / `LockFileEx`), including refresh-token rotation; older gws versions sharing the config directory are still excluded through the existing `.lock` file. An expired token is no longer refreshed when the lock cannot be taken (for example a read-only config directory): the command fails with a message saying so.
- **`gws auth logout`** returns `"revoked": true` only when Google confirmed the revocation, and `"revoked": false` with instructions otherwise. `gws auth status` reports a token Google rejects as not authenticated.
- **README**: retitled as the unofficial Go CLI for Google Workspace, with a comparison against Google's `gwscli` and `googleworkspace/cli` and a Disclaimer section.
- New direct dependencies `golang.org/x/term` and `golang.org/x/sys` (both already in the module graph).
- All of the above shipped in [#230](https://github.com/omriariav/workspace-cli/pull/230).

**Upgrade notes**

- A blank `GWS_ACCESS_TOKEN=` in a shell profile now makes commands fail with a "set but empty" error until it is unset. Not affected: `gws version`, shell completion, `--help`, and the `--schema` / `--show-scopes` introspection flags, which are answered before the check.
- With a malformed `config.yaml`, sensitive commands are refused until the file is fixed, `GWS_CONFIRM_SENSITIVE` is set, or `--yes` is given.
- Upgrade every gws binary that shares a config directory: the refresh guarantee holds only between copies of this version or later.

## v1.43.1

**Skill Audit, Uniform Skill Versions, Canonical Release Procedure**
Expand Down
8 changes: 4 additions & 4 deletions cmd/skills_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -215,8 +215,8 @@ func TestCodexPluginJSON_Valid(t *testing.T) {
if name, ok := manifest["name"].(string); !ok || name != "gws" {
t.Errorf("expected Codex plugin name 'gws', got '%v'", manifest["name"])
}
if version, ok := manifest["version"].(string); !ok || version != "1.43.1" {
t.Errorf("expected Codex plugin version '1.43.1', got '%v'", manifest["version"])
if version, ok := manifest["version"].(string); !ok || version != "1.44.0" {
t.Errorf("expected Codex plugin version '1.44.0', got '%v'", manifest["version"])
}
if skills, ok := manifest["skills"].(string); !ok || skills != "./skills/" {
t.Errorf("expected Codex plugin skills path './skills/', got '%v'", manifest["skills"])
Expand Down Expand Up @@ -244,8 +244,8 @@ func TestPluginHookManifestsUseOneEntrypointPerEvent(t *testing.T) {
if hooks, ok := claudePlugin["hooks"].(string); !ok || hooks != "./hooks/hooks.json" {
t.Fatalf("Claude plugin hooks must reference ./hooks/hooks.json, got %v", claudePlugin["hooks"])
}
if version, ok := claudePlugin["version"].(string); !ok || version != "1.43.1" {
t.Fatalf("Claude plugin version must match the released 1.43.1 baseline, got %v", claudePlugin["version"])
if version, ok := claudePlugin["version"].(string); !ok || version != "1.44.0" {
t.Fatalf("Claude plugin version must match the released 1.44.0 baseline, got %v", claudePlugin["version"])
}
claudeHooksPath := filepath.Join("..", "hooks", "hooks.json")
claudeData, err := os.ReadFile(claudeHooksPath)
Expand Down
2 changes: 1 addition & 1 deletion plugins/gws/.codex-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "gws",
"version": "1.43.1",
"version": "1.44.0",
"description": "Unofficial Google Workspace CLI skills for Codex. Teaches Codex how to use gws for Gmail, Calendar, Drive, Docs, Sheets, Slides, Tasks, Chat, Forms, Contacts, Groups, Keep, Workspace Events, and Search.",
"author": {
"name": "Omri Ariav",
Expand Down
2 changes: 1 addition & 1 deletion skills/auth/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-auth
version: 1.43.1
version: 1.44.0
description: "Google Workspace CLI authentication setup and management. Use when users need to set up OAuth credentials, authenticate with Google APIs, or troubleshoot authentication issues. Triggers: gws auth, google workspace setup, oauth, credentials, client id, api setup."
metadata:
short-description: Google Workspace CLI authentication
Expand Down
2 changes: 1 addition & 1 deletion skills/calendar/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-calendar
version: 1.43.1
version: 1.44.0
description: "Google Calendar CLI operations via gws. Use when users need to list calendars, view events, create/update/delete events, RSVP to invitations, manage calendar CRUD, subscriptions, ACL, free/busy queries, colors, and settings. Triggers: calendar, events, meetings, schedule, rsvp, invite, share, freebusy."
metadata:
short-description: Google Calendar CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/chat/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-chat
version: 1.43.1
version: 1.44.0
description: "Google Chat CLI operations via gws. Use when users need to list/create/manage chat spaces, read/send messages, manage members, track read state, handle attachments, or monitor space events. Triggers: google chat, gchat, chat spaces, chat messages."
metadata:
short-description: Google Chat CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/contacts/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-contacts
version: 1.43.1
version: 1.44.0
description: "Google Contacts CLI operations via gws. Use when users need to list, search, view, create, or delete contacts. Triggers: contacts, google contacts, people api, contact management."
metadata:
short-description: Google Contacts CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/docs/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-docs
version: 1.43.1
version: 1.44.0
description: "Google Docs CLI operations via gws. Use when users need to read, create, or edit Google Docs documents. Triggers: google docs, document, gdoc, word processing."
metadata:
short-description: Google Docs CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/drive/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-drive
version: 1.43.1
version: 1.44.0
description: "Google Drive CLI operations via gws. Use when users need to list, search, upload, download, manage files/folders, permissions, approvals, revisions, comments, shared drives, and more. Triggers: drive, files, upload, download, folders, google drive, file management, permissions, approvals, share, shared drives."
metadata:
short-description: Google Drive CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/events/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-events
version: 1.43.1
version: 1.44.0
description: "Google Workspace Events API operations via gws. Use when users need to create or manage event subscriptions for Chat, Drive, or Meet resources (Pub/Sub delivery), renew or reactivate subscriptions, or decode Pub/Sub CloudEvent notifications. Triggers: workspace events, event subscription, subscribe to chat events, drive events, meet events, pubsub notifications, cloudevent."
metadata:
short-description: Google Workspace Events subscriptions
Expand Down
2 changes: 1 addition & 1 deletion skills/forms/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-forms
version: 1.43.1
version: 1.44.0
description: "Google Forms CLI operations via gws. Use when users need to get form metadata, retrieve form responses, create forms, or update forms. Triggers: google forms, form responses, survey, form data, create form, update form."
metadata:
short-description: Google Forms CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/gmail/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-gmail
version: 1.43.1
version: 1.44.0
description: "Google Gmail CLI operations via gws. Use when users need to list emails, read messages, send email, manage labels, drafts, attachments, batch operations, or trash messages. Triggers: gmail, email, inbox, send email, mail, labels, archive, trash, drafts, attachments."
metadata:
short-description: Google Gmail CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/groups/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-groups
version: 1.43.1
version: 1.44.0
description: "Google Groups CLI operations via gws. Use when users need to list groups or view group members. Triggers: groups, google groups, admin directory, group members."
metadata:
short-description: Google Groups CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/gws-setup/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-setup
version: 1.43.1
version: 1.44.0
description: "Safely inspect, preview, and explicitly configure optional GWS authentication and session-context hooks. Use for gws setup, gws hooks, time context, Workspace context, or hook configuration."
metadata:
short-description: Safe GWS hook setup
Expand Down
2 changes: 1 addition & 1 deletion skills/keep/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-keep
version: 1.43.1
version: 1.44.0
description: "Google Keep CLI operations via gws. Use when users need to list, view, or create Google Keep notes. Triggers: keep, google keep, notes, sticky notes."
metadata:
short-description: Google Keep CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/search/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-search
version: 1.43.1
version: 1.44.0
description: "Google Custom Search CLI operations via gws. Use when users need to perform web searches using Google Programmable Search Engine. Triggers: google search, custom search, web search."
metadata:
short-description: Google Custom Search CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/sheets/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-sheets
version: 1.43.1
version: 1.44.0
description: "Google Sheets CLI operations via gws. Use when users need to read, write, or manage Google Sheets spreadsheets including cell values, rows, columns, sheets, sorting, merging, formatting, and find-replace. Triggers: sheets, spreadsheet, google sheets, cells, rows, columns, formulas, formatting."
metadata:
short-description: Google Sheets CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/slides/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-slides
version: 1.43.1
version: 1.44.0
description: "Google Slides CLI operations via gws. Use when users need to create, read, or edit Google Slides presentations. Triggers: slides, presentation, google slides, deck."
metadata:
short-description: Google Slides CLI operations
Expand Down
2 changes: 1 addition & 1 deletion skills/tasks/SKILL.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: gws-tasks
version: 1.43.1
version: 1.44.0
description: "Google Tasks CLI operations via gws. Use when users need to manage task lists, view/create/update/delete tasks, move tasks, or clear completed. Triggers: google tasks, task list, todo, task management."
metadata:
short-description: Google Tasks CLI operations
Expand Down
Loading