Skip to main content
Glama
enoch-sit

gmail-mcp-server

by enoch-sit

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
PORTNoWeb UI setup server port (default: 3000)3000
GMAIL_CLIENT_IDYesGoogle OAuth2 Client ID
GMAIL_REDIRECT_URINoOverride redirect URI (default: http://localhost:3000/oauth/callback)http://localhost:3000/oauth/callback
GMAIL_CLIENT_SECRETYesGoogle OAuth2 Client Secret
GMAIL_REFRESH_TOKENYesLong-lived refresh token (from setup wizard)

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
list_emailsA

List emails from Gmail. Filter by labels and/or a search query. Returns sender, subject, date, and snippet for each message.

read_emailB

Read the full content of a specific email by its message ID, including headers and decoded body.

search_emailsA

Search Gmail using the standard Gmail search syntax. Returns matching emails with sender, subject, date, and snippet.

download_attachmentB

Download a specific attachment from a Gmail message. Returns the base64-encoded attachment data and its MIME type.

list_attachments_with_safetyA

List attachments for a message and provide policy-based safety assessment for each file.

validate_attachmentA

Validate one attachment against local safety policy (size, MIME type, extension, filename).

download_attachment_safeA

Safely download one validated attachment. Blocks risky files and enforces policy checks before returning data.

redact_text_localB

Redact sensitive content from provided text using local privacy pipeline (orchestrator with deterministic fallback).

read_email_with_privacyA

Read one email and return only privacy-redacted subject/snippet/body fields using the local privacy pipeline.

send_emailC

Send an email via the authenticated Gmail account.

create_draftA

Create a draft email in Gmail without sending it.

reply_to_emailA

Reply to an existing email thread. Automatically sets Reply-To headers and preserves the thread.

delete_emailA

Move an email to Trash. Pass permanent: true to permanently delete (irreversible).

mark_as_readA

Mark an email as read by removing the UNREAD label.

mark_as_unreadB

Mark an email as unread by adding the UNREAD label.

set_labelsA

Add and/or remove labels on an email. Use get_labels to obtain valid label IDs.

get_labelsA

List all Gmail labels (system labels like INBOX, SENT and user-created labels). Returns label IDs, names, and message counts.

get_profileA

Get the authenticated Gmail user profile: email address, total message count, and thread count. Useful to verify the connection.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/enoch-sit/gmail-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server