gmail-automation
Lets your agent interact with Gmail to automate tasks. It's useful for managing emails without needing a complex server.
What it does
This tool lets you interact with your Gmail account directly from your computer, without needing to open the website. You can search, read, and send emails, as well as organize your messages.
When to use it
- ✓When you want to find a specific email quickly.
- ✓To automate repetitive tasks in your work email.
- ✓If you prefer using computer commands instead of clicking on a website.
Example of what to ask your AI
“Search for unread emails from 'boss@company.com' sent in the last 3 days.”
Want more? Open the sections below.
How to use
The easiest way: copy the message below and paste it into Claude, ChatGPT, Cursor or any AI. It reads the skill and follows the instructions.
Skill link
Ready-to-paste message
How it works
It uses a separate program to connect to your Gmail account securely. First, you authorize the program once, and then it can run commands to manage your emails.
Installation
Easiest way: copy the skill link and paste it into Claude, ChatGPT or Cursor asking it to follow the instructions.
In the terminal (Claude Code, Codex, Cursor), in your project folder:
npx skills add sickn33/agentic-awesome-skills --skill gmail-automationOr download just the file:
curl -L https://raw.githubusercontent.com/sickn33/agentic-awesome-skills/main/plugins/agentic-awesome-skills-claude/skills/gmail-automation/SKILL.md -o SKILL.mdTechnical content (original SKILL.md)
Original text by the author, straight from GitHub.
Supporting material availability
This catalog copy contains the inline guidance below, but does not include the following supporting paths. They are external prerequisites, not bundled files:
<support-root>/scripts/auth.py<support-root>/scripts/gmail.py
Ask for the original supporting material or an existing installation before using a step that depends on these paths; this catalog does not identify a verified download source for them. Resolve each path relative to that installation, inspect its contents, and verify any applicable license and execution prerequisites. Do not run a command or claim a referenced procedure was followed until its required file exists. Do not fabricate the missing scripts or treat an unrelated file with the same name as equivalent. Independent steps fully documented here can proceed within the user’s authorized scope; report any dependent step as unavailable.
Gmail
Lightweight Gmail integration with standalone OAuth authentication. No MCP server required.
⚠️ Requires Google Workspace account. Personal Gmail accounts are not supported.
When to Use
- You need to search, read, or send Gmail messages from the command line without an MCP server.
- You are automating inbox workflows for a Google Workspace account.
- You want a lightweight Gmail integration backed by standalone OAuth scripts.
First-Time Setup
Authenticate with Google (opens browser):
python scripts/auth.py login
Check authentication status:
python scripts/auth.py status
Logout when needed:
python scripts/auth.py logout
Commands
All operations via scripts/gmail.py. Auto-authenticates on first use if not logged in.
Search Emails
# Search with Gmail query syntax
python scripts/gmail.py search "from:someone@example.com is:unread"
# Search recent emails (no query returns all)
python scripts/gmail.py search --limit 20
# Filter by label
python scripts/gmail.py search --label INBOX --limit 10
# Include spam and trash
python scripts/gmail.py search "subject:important" --include-spam-trash
Read Email Content
# Get full message content
python scripts/gmail.py get MESSAGE_ID
# Get just metadata (headers)
python scripts/gmail.py get MESSAGE_ID --format metadata
# Get minimal response (IDs only)
python scripts/gmail.py get MESSAGE_ID --format minimal
Send Emails
# Send a simple email
python scripts/gmail.py send --to "user@example.com" --subject "Hello" --body "Message body"
# Send with CC and BCC
python scripts/gmail.py send --to "user@example.com" --cc "cc@example.com" --bcc "bcc@example.com" \
--subject "Team Update" --body "Update message"
# Send from an alias (must be configured in Gmail settings)
python scripts/gmail.py send --to "user@example.com" --subject "Hello" --body "Message" \
--from "Mile9 Accounts <accounts@mile9.io>"
# Send HTML email
python scripts/gmail.py send --to "user@example.com" --subject "HTML Email" \
--body "<h1>Hello</h1><p>HTML content</p>" --html
Draft Management
# Create a draft
python scripts/gmail.py create-draft --to "user@example.com" --subject "Draft Subject" \
--body "Draft content"
# Send an existing draft
python scripts/gmail.py send-draft DRAFT_ID
Modify Messages (Labels)
# Mark as read (remove UNREAD label)
python scripts/gmail.py modify MESSAGE_ID --remove-label UNREAD
# Mark as unread
python scripts/gmail.py modify MESSAGE_ID --add-label UNREAD
# Archive (remove from INBOX)
python scripts/gmail.py modify MESSAGE_ID --remove-label INBOX
# Star a message
python scripts/gmail.py modify MESSAGE_ID --add-label STARRED
# Unstar a message
python scripts/gmail.py modify MESSAGE_ID --remove-label STARRED
# Mark as important
python scripts/gmail.py modify MESSAGE_ID --add-label IMPORTANT
# Multiple label changes at once
python scripts/gmail.py modify MESSAGE_ID --remove-label UNREAD --add-label STARRED
List Labels
# List all Gmail labels (system and user-created)
python scripts/gmail.py list-labels
Gmail Query Syntax
Gmail supports powerful search operators:
| Query | Description |
|---|---|
from:user@example.com |
Emails from a specific sender |
to:user@example.com |
Emails to a specific recipient |
subject:meeting |
Emails with "meeting" in subject |
is:unread |
Unread emails |
is:starred |
Starred emails |
is:important |
Important emails |
…
FAQ
Do I need a personal Gmail account?
No, this tool only works with Google Workspace accounts (email accounts for companies or institutions that use Gmail).
How does it connect to my account?
It uses a method called OAuth, which allows you to authorize access without sharing your password directly. The first time, a browser will open for you to log in and grant permission.
What are the mentioned 'scripts'?
These are small programs (code files) that perform the actions. You need to have these files for the tool to work, but they are not included with the tool's description.
Details
Original description by the author
Lightweight Gmail integration with standalone OAuth authentication. No MCP server required.
Popularity
- GitHub stars
- 48k
- Ranking position
- #3144
- License
- MIT
- Updated
- 10/15/2026
Comments
- …
More skills from this repository
00-andruia-consultant
Helps your agent start or improve AI projects. It analyzes code, suggests tools, and creates action plans in Spanish.
sickn33/agentic-awesome-skills
007
Lets your agent perform security audits and threat modeling. It's useful for protecting projects against attacks and vulnerabilities.
sickn33/agentic-awesome-skills
10-andruia-skill-smith
Helps your agent create or improve AI tools. It defines how tools work, writes documentation, and validates the structure.
sickn33/agentic-awesome-skills
20-andruia-niche-intelligence
Lets your agent create a summary about a specific industry. It's useful for understanding the context, rules, usage patterns, and risks of a project, using reliable sources.
sickn33/agentic-awesome-skills
Similar skills
benchmark
Helps your agent measure code speed and performance. It's useful for ensuring things are fast and finding slowness issues.
affaan-m/ECC
content-hash-cache-pattern
Lets your agent use content hashes to cache file processing results. This avoids repeated processing and auto-invalidates the cache when content changes. Useful for speeding up slow tasks.
affaan-m/ECC
parallel-execution-optimizer
Makes your agent speed up complex tasks by breaking them into smaller parts and running them in parallel. It ensures everything is verified at the end.
affaan-m/ECC