Read, send, and search Gmail messages — manage labels, drafts, and attachments with full inbox control.
Use with AI AssistantsMCP
Connect Claude, Cursor, or any MCP-compatible client — then call tools directly
① Add This MCP Server
Paste into your AI client config — then all its tools are available instantly.
{
"mcpServers": {
"gmail": {
"url": "https://mcp.aerostack.dev/s/aerostack/mcp-gmail",
"headers": {
"Authorization": "Bearer YOUR_AEROSTACK_TOKEN"
}
}
}
}Replace YOUR_AEROSTACK_TOKEN with your API token from the dashboard.
② Call a Tool
Ask your AI assistant to call a specific tool, or send raw JSON-RPC:
Natural Language Prompt
“Use the _ping tool to verify gmail credentials by calling a lightweight read endpoint. used internally by aerostack to validate credentials”
Using a Workspace?
Add this MCP to your Workspace — your team shares one token, secrets are stored securely, and every AI agent in the workspace can call it without per-user setup.
Give AI agents full access to Gmail — read, search, send, reply, organize, and manage email conversations programmatically.
Gmail is the world's most widely used email platform. This MCP server gives your agents complete access to the Gmail API: searching and reading messages, sending emails and replies, managing labels and folders, forwarding threads, drafting emails, and downloading attachments — enabling fully automated email workflows without human intervention.
Live endpoint: https://mcp.aerostack.dev/s/aerostack/mcp-gmail
| Tool | Description |
|---|---|
| list_messages | List Gmail messages matching an optional query with pagination |
| get_message | Get a specific message by ID with headers, body, and labels |
| search_messages | Search messages using Gmail query syntax (from:, subject:, has:attachment, etc.) |
| list_threads | List conversation threads matching an optional query |
| get_thread | Get a full conversation thread including all messages |
| send_email | Send an email with plain text or HTML body, CC, and BCC |
| reply_to_message | Reply to a message in the same thread with correct email headers |
| forward_message | Forward a message to one or more recipients with an optional note |
| create_draft | Create a draft email without sending it |
| list_labels | List all Gmail labels including system and user-created labels |
| get_label | Get details of a specific label with message counts |
| create_label | Create a new label for organizing messages |
| modify_message_labels | Add or remove labels on a message (use to mark read, move to folder, etc.) |
| trash_message | Move a message to trash (recoverable for 30 days) |
| delete_message | Permanently delete a message — cannot be undone |
| mark_as_read | Mark a message as read |
| mark_as_unread | Mark a message as unread |
| get_profile | Get the authenticated Gmail user's profile and message counts |
| list_drafts | List draft emails in the drafts folder |
| get_attachment | Download a message attachment by attachment ID |
| Variable | Required | Description | How to Get |
|---|---|---|---|
| GMAIL_ACCESS_TOKEN | Yes | OAuth 2.0 access token with gmail.send and gmail.readonly scopes | Google Cloud Console → APIs → Gmail API → OAuth 2.0 credentials |
GMAIL_ACCESS_TOKEN under Project → SecretsOnce added, every AI agent in your workspace can read and send Gmail automatically — no per-user setup needed.
"Search my inbox for unread emails from customers asking about pricing and summarize them"
"Reply to the email from alice@acme.com saying I'll send the proposal by Friday"
"Label all emails from support@stripe.com as 'Billing' and mark them as read"
curl -X POST https://mcp.aerostack.dev/s/aerostack/mcp-gmail \
-H 'Content-Type: application/json' \
-H 'X-Mcp-Secret-GMAIL-ACCESS-TOKEN: your-token' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"search_messages","arguments":{"query":"is:unread from:boss@example.com"}}}'
MIT
Live Endpoint
https://mcp.aerostack.dev/s/aerostack/mcp-gmail
Sub-50ms globally · Zero cold start
@aerostack
Pre-built functions for the most common MCP tool patterns. Clone, extend, and deploy.
by @aerostack
Design creation, AI generation, editing, export, assets, brand kits, folders via Canva's official MCP
by @aerostack
Conversations, contacts, tickets, articles via Intercom's official MCP
by @aerostack
Call Claude models directly — run AI conversations, tool-use chains, batch jobs, and model comparisons from any agent.
by @aerostack
Deployments, projects, domains, env vars, logs via Vercel's official MCP
by @aerostack
Manage audiences, campaigns, and subscriber tags in Mailchimp — automate your email marketing with AI.
by @aerostack
Run chat completions, generate embeddings, create images, and moderate content via the OpenAI API.
Yes. search_messages accepts a Gmail query string supporting all standard operators: from:, subject:, after:, before:, has:attachment. Claude constructs the query from natural language and returns matching message IDs and snippets.
Yes. reply_to_message takes a message ID and automatically sets the correct In-Reply-To and References headers so the reply threads correctly in Gmail. forward_message works the same way, preserving the original thread context.
Yes. create_label defines a new Gmail label with optional text and background colour. modify_message_labels then applies or removes any label by ID. Claude can triage an inbox by labelling messages by project, urgency, or sender domain in bulk.
Yes. get_attachment returns the attachment's base64-encoded data and MIME type given a message ID and attachment ID. Claude first calls get_message to locate attachment IDs, then fetches each one — the bytes can then be forwarded to a storage or analysis tool.