gws-groups
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.
Best use case
gws-groups is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
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.
Teams using gws-groups should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/groups/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How gws-groups Compares
| Feature / Agent | gws-groups | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
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.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# Google Groups (gws groups)
`gws groups` provides CLI access to Google Groups via the Admin Directory API with structured JSON output.
> **Disclaimer:** `gws` is not the official Google CLI. This is an independent, open-source project not endorsed by or affiliated with Google.
## Dependency Check
**Before executing any `gws` command**, verify the CLI is installed:
```bash
gws version
```
If not found, install: `go install github.com/omriariav/workspace-cli/cmd/gws@latest`
**Minimum version required:** v1.18.0 (Groups support added in this release)
## Prerequisites
- **Admin SDK API** must be enabled in the Google Cloud project
- **Google Workspace admin privileges** are required (not available for personal Gmail accounts)
## Authentication
Requires OAuth2 credentials. Run `gws auth status` to check.
If not authenticated: `gws auth login` (opens browser for OAuth consent).
For initial setup, see the `gws-auth` skill.
## Quick Command Reference
| Task | Command |
|------|---------|
| List groups | `gws groups list` |
| List groups in a domain | `gws groups list --domain example.com` |
| List groups for a user | `gws groups list --user-email user@example.com` |
| List more groups | `gws groups list --max 200` |
| List group members | `gws groups members group@example.com` |
| List group owners | `gws groups members group@example.com --role OWNER` |
## Detailed Usage
### list -- List groups
```bash
gws groups list [flags]
```
Lists Google Groups in your domain. By default, lists all groups for the customer account.
**Flags:**
- `--max int` -- Maximum number of groups to return (default 50)
- `--domain string` -- Filter by domain
- `--user-email string` -- Filter groups for a specific user
**Note:** `--domain` and `--user-email` are mutually exclusive. Providing both will return an error.
**Output includes:**
- `id` -- Group ID
- `email` -- Group email address
- `name` -- Group display name
- `description` -- Group description (if set)
- `member_count` -- Number of direct members (if available)
**Examples:**
```bash
gws groups list
gws groups list --max 200
gws groups list --domain example.com
gws groups list --user-email alice@example.com
gws groups list --format json | jq '.groups[] | {name, email}'
```
### members -- List group members
```bash
gws groups members <group-email> [flags]
```
Lists members of a Google Group by group email address.
**Arguments:**
- `group-email` -- Group email address (required)
**Flags:**
- `--max int` -- Maximum number of members to return (default 50)
- `--role string` -- Filter by role: `OWNER`, `MANAGER`, or `MEMBER`
**Output includes:**
- `id` -- Member ID
- `email` -- Member email address
- `role` -- Member role (OWNER, MANAGER, or MEMBER)
- `type` -- Member type (e.g., USER, GROUP)
- `status` -- Member status (if available)
**Examples:**
```bash
gws groups members engineering@example.com
gws groups members engineering@example.com --max 200
gws groups members engineering@example.com --role OWNER
gws groups members engineering@example.com --role MANAGER
gws groups members engineering@example.com --format json | jq '.members[] | select(.role == "OWNER")'
```
## Output Modes
```bash
gws groups list --format json # Structured JSON (default)
gws groups list --format yaml # YAML format
gws groups list --format text # Human-readable text
```
## Tips for AI Agents
- Always use `--format json` (the default) for programmatic parsing
- The `list` command returns groups for the entire customer account by default; use `--domain` or `--user-email` to narrow results
- `--domain` and `--user-email` cannot be used together -- pick one filter
- Use `--role` on the `members` command to quickly find group owners or managers
- The `members` command requires the exact group email address as a positional argument
- Use `--quiet` on any command to suppress JSON output (useful for scripted actions)
- This command requires Admin SDK API enabled and Workspace admin privileges -- it will not work with personal Gmail accounts
- For bulk membership analysis, pipe output through `jq` to filter and aggregate resultsRelated Skills
gws-tasks
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.
gws-slides
Google Slides CLI operations via gws. Use when users need to create, read, or edit Google Slides presentations. Triggers: slides, presentation, google slides, deck.
gws-sheets
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.
gws-search
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.
gws-keep
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.
gws-gmail
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.
gws-forms
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.
gws-drive
Google Drive CLI operations via gws. Use when users need to list, search, upload, download, manage files/folders, permissions, revisions, comments, shared drives, and more. Triggers: drive, files, upload, download, folders, google drive, file management, permissions, share, shared drives.
gws-docs
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.
gws-contacts
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.
gws-chat
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.
gws-calendar
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.