/SKILL.md
# Gmail CLI Skill CLI for Gmail API with local sync. Supports multiple Google accounts. ## Running ```bash gmail <command> # Globally linked ``` ## Authentication Requires OAuth2 credentials from Google Cloud Console: ```bash gmail auth setup <client-id> <client-secret> # One-time setup gmail auth login # Opens browser gmail auth list # List accounts gmail auth default [email protected] # Set default ``` Switch ac
npx skillsauth add rusintez/gmail gmailInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
CLI for Gmail API with local sync. Supports multiple Google accounts.
gmail <command> # Globally linked
Requires OAuth2 credentials from Google Cloud Console:
gmail auth setup <client-id> <client-secret> # One-time setup
gmail auth login # Opens browser
gmail auth list # List accounts
gmail auth default [email protected] # Set default
Switch accounts with -a <email>:
gmail -a [email protected] inbox
gmail inbox # Recent inbox
gmail inbox -u # Unread only
gmail inbox -l STARRED # By label
gmail inbox -n 50 # Limit
gmail inbox -q "from:boss" # Gmail search
gmail message <id> # Full message
gmail thread <id> # Full conversation
gmail threads # List threads
gmail search "subject:urgent" # Search
gmail send --to [email protected] --subject "Hi" --body "Hello"
gmail send --to [email protected] --cc [email protected] --subject "FYI" --body "..."
All mutations sync to Gmail server immediately:
gmail archive <id> # Remove from inbox (keeps in All Mail)
gmail trash <id> # Move to trash
gmail mark-read <id> # Mark read (removes UNREAD label)
gmail mark-unread <id> # Mark unread (adds UNREAD label)
gmail label <id> STARRED # Add label
gmail unlabel <id> IMPORTANT # Remove label
Read/unread state: Stored in labelIds array - presence of UNREAD = unread.
Archive vs Trash: Archive removes from INBOX but message remains in All Mail. Trash moves to trash folder (auto-deleted after 30 days).
gmail labels # List all labels
gmail search "from:[email protected]"
gmail search "subject:invoice after:2024/01/01"
gmail search "has:attachment filename:pdf"
gmail search "is:unread in:inbox"
gmail search "category:primary newer_than:7d"
Sync Gmail data to local JSON files for offline access and searching.
Exclusions: Spam and Trash are automatically excluded from sync (never downloaded).
gmail sync # Incremental sync all accounts
gmail sync --full # Full sync
gmail sync --include-attachments # Include attachments
gmail sync -a [email protected] # Sync one account
gmail sync -c messages,labels # Sync specific collections
gmail sync-status # List synced accounts
gmail sync-status [email protected] # Status for account
gmail sync-reset [email protected] # Reset state
~/.local/share/gmail/{email}/
├── profile.json
├── labels/{id}.json
├── messages/{id}.json
├── threads/{id}.json
├── drafts/{id}.json
└── .sync-state.json
| Collection | Description |
|------------|-------------|
| labels | Gmail labels (INBOX, STARRED, custom) |
| messages | Individual emails with headers and body |
| threads | Conversation threads |
| drafts | Draft messages |
| attachments | Downloaded attachments (when --include-attachments) |
Note: Attachments from promotional emails (CATEGORY_PROMOTIONS) are skipped (security). Spam/trash are excluded entirely.
See schema.md for full field documentation.
| Flag | Format | Use Case |
|------|--------|----------|
| (default) | Markdown | Human readable |
| -f json | JSON | Parsing, scripting |
| -f minimal | Tab-separated | Simple processing |
~/.config/gmail-cli/config.json~/.local/share/gmail/tools
Use when work should span one or more detached tasks but still behave like one job with a single owner context. TaskFlow is the durable flow substrate under authoring layers like Lobster, ACPX, plugins, or plain code. Keep conditional logic in the caller; use TaskFlow for flow identity, child-task linkage, waiting state, revision-checked mutations, and user-facing emergence.
tools
# Lobster Lobster executes multi-step workflows with approval checkpoints. Use it when: - User wants a repeatable automation (triage, monitor, sync) - Actions need human approval before executing (send, post, delete) - Multiple tool calls should run as one deterministic operation ## When to use Lobster | User intent | Use Lobster? | | ------------------------------------------------------ | --------------------------
tools
# Lobster Lobster executes multi-step workflows with approval checkpoints. Use it when: - User wants a repeatable automation (triage, monitor, sync) - Actions need human approval before executing (send, post, delete) - Multiple tool calls should run as one deterministic operation ## When to use Lobster | User intent | Use Lobster? | | ------------------------------------------------------ | --------------------------
tools
A CLI tool for making authenticated requests to the X (Twitter) API. Use this skill when you need to post tweets, reply, quote, search, read posts, manage followers, send DMs, upload media, or interact with any X API v2 endpoint.