Recipe Label And Archive Emails
Google WorkspaceOfficialPublished by Google Workspace
- Skill
- Workflow
- Automation and integrations
- Apache-2.0
- No issues found
AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
This workflow provides a structured approach to managing Gmail clutter by programmatically identifying specific emails, applying organizational labels, and archiving them to remove them from the primary inbox. It relies on the gws-gmail skill to interface with the Gmail API, allowing users to define search queries to filter incoming or existing messages for automated processing.
What it does
- Searches for specific email threads using Gmail query syntax.
- Applies custom labels to identified messages for better categorization.
- Archives messages by removing the INBOX label to maintain a clean workspace.
When to use it
- When you need to process large volumes of automated notifications.
- When you want to enforce a zero-inbox policy for specific senders.
- When you need to categorize incoming emails automatically without manual intervention.
Advantages
- Reduces manual email management time.
- Ensures consistent organization across your inbox.
- Keeps the primary inbox focused on essential communications.
Usage examples
- “Archive all emails from [email removed] and label them as 'Service'.”
- The agent searches for messages from the specified sender, applies the 'Service' label, and removes them from the inbox.
Install
Download the skill as a ZIP:
https://autogineer.com/agent-skills/googleworkspace/recipe-label-and-archive-emails/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip recipe-label-and-archive-emails.zip -d .agents/skills
Documentation by Google Workspace
Label and Archive Gmail Threads
PREREQUISITE: Load the following skills to execute this recipe:
gws-gmail
Apply Gmail labels to matching messages and archive them to keep your inbox clean.
Steps
Search for matching emails:
gws gmail users messages list --params '{"userId": "me", "q": "from:[email protected]"}' --format tableApply a label:
gws gmail users messages modify --params '{"userId": "me", "id": "MESSAGE_ID"}' --json '{"addLabelIds": ["LABEL_ID"]}'Archive (remove from inbox):
gws gmail users messages modify --params '{"userId": "me", "id": "MESSAGE_ID"}' --json '{"removeLabelIds": ["INBOX"]}'
Files
- ATTRIBUTION.mdAdded by AutoGineer924 B
- LICENSELicence file added by AutoGineer11.1 KiB
- SKILL.md959 B
Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Security
No issues found by our static scan· No issues found
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Published by
- Google Workspace
- Publisher
- Google Workspace (Official)
- Source
- googleworkspace/cli · skills/recipe-label-and-archive-emails · commit cd3697e
- Licence
- Apache License 2.0 (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
AutoGineer is not affiliated with or endorsed by Google Workspace or Google Workspace.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download recipe-label-and-archive-emails.zip