ต้นแบบ · รุ่นทดลอง: มีทุก server ในทะเบียนทางการ อัปเดตทุก 30 นาที รีวิวและบัญชีผู้ใช้จะมาในขั้นถัดไป
PopNx MCPที่รวม MCP สำหรับคนใช้ AI · อธิบายเป็นภาษาคน

Gmail

โดย pulsemcpรุ่น 0.4.12i★ –iรันบนเครื่อง
ชื่อใน registrycom.pulsemcp/gmail

ติดตั้ง

ภาพรวม

คำอธิบายจากผู้ทำ (ภาษาอังกฤษตามต้นฉบับ)

MCP server for Gmail with OAuth2 (personal) and service account (Workspace) support.

สามเสาของ PopNx MCP

สามเรื่องนี้ไม่รวมเป็นคะแนนเดียว เพราะความเห็น การวัด และความนิยม เป็นคนละเรื่องกัน

ใช้ทำอะไรได้

ตัวนี้ยังไม่ได้เรียบเรียงเป็นภาษาไทย ด้านล่างคือข้อเท็จจริงที่เราอ่านจาก registry

  • การเชื่อมต่อ: รันบนเครื่อง
  • ช่องทาง (transport): stdio
  • หมวด: แชตและอีเมล
  • ต้องใส่ค่าเหล่านี้: GMAIL_OAUTH_CLIENT_ID, GMAIL_OAUTH_CLIENT_SECRET, GMAIL_OAUTH_REFRESH_TOKEN, GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY

ติดตั้ง

เลือกโปรแกรม AI ที่คุณใช้ แล้วคัดลอกค่าตั้งไปวาง

ก่อนติดตั้ง

  • ผลตรวจเบื้องต้น: ผ่าน 1 จาก 1 ข้อ
  • รันในเครื่องคุณด้วยสิทธิ์ของผู้ใช้คุณ (ไฟล์ อินเทอร์เน็ต แอปต่าง ๆ)
  • ค่าที่คุณต้องใส่เอง: GMAIL_OAUTH_CLIENT_ID, GMAIL_OAUTH_CLIENT_SECRET, GMAIL_OAUTH_REFRESH_TOKEN, GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL, GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY, GMAIL_IMPERSONATE_EMAIL, GMAIL_ENABLED_TOOLGROUPS

ค่าที่ติดป้ายความลับคือกุญแจของบัญชีคุณ อย่าส่งให้ใคร และอย่าวางในแชต

ต้องเตรียมก่อน

  • npmติดตั้ง Node.js (มีคำสั่ง npx) ในเครื่อง

คุณใช้แอปไหน

เลือกแอปด้านบน เราจำไว้ให้ ครั้งหน้าปุ่มจะขึ้นว่า “ติดตั้งลง …”

เปิด Claude Desktop → Settings → Developer → Edit Config แล้ววางค่านี้ในไฟล์ claude_desktop_config.json

{
  "mcpServers": {
    "gmail": {
      "command": "npx",
      "args": [
        "-y",
        "gmail-workspace-mcp-server"
      ],
      "env": {
        "GMAIL_OAUTH_CLIENT_ID": "ใส่ค่าของคุณ",
        "GMAIL_OAUTH_CLIENT_SECRET": "ใส่ค่าของคุณ",
        "GMAIL_OAUTH_REFRESH_TOKEN": "ใส่ค่าของคุณ",
        "GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL": "ใส่ค่าของคุณ",
        "GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY": "ใส่ค่าของคุณ",
        "GMAIL_IMPERSONATE_EMAIL": "ใส่ค่าของคุณ",
        "GMAIL_ENABLED_TOOLGROUPS": "ใส่ค่าของคุณ"
      }
    }
  }
}

พิมพ์คำสั่งนี้ใน Terminal

claude mcp add gmail --env GMAIL_OAUTH_CLIENT_ID='ใส่ค่าของคุณ' --env GMAIL_OAUTH_CLIENT_SECRET='ใส่ค่าของคุณ' --env GMAIL_OAUTH_REFRESH_TOKEN='ใส่ค่าของคุณ' --env GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL='ใส่ค่าของคุณ' --env GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY='ใส่ค่าของคุณ' --env GMAIL_IMPERSONATE_EMAIL='ใส่ค่าของคุณ' --env GMAIL_ENABLED_TOOLGROUPS='ใส่ค่าของคุณ' -- npx -y gmail-workspace-mcp-server

เติมค่าที่เว้นว่างไว้ก่อนรัน

เปิดใน Cursor

หรือคัดลอกค่าตั้งเอง

วางในไฟล์ .cursor/mcp.json ของโปรเจกต์ หรือ ~/.cursor/mcp.json

{
  "mcpServers": {
    "gmail": {
      "command": "npx",
      "args": [
        "-y",
        "gmail-workspace-mcp-server"
      ],
      "env": {
        "GMAIL_OAUTH_CLIENT_ID": "ใส่ค่าของคุณ",
        "GMAIL_OAUTH_CLIENT_SECRET": "ใส่ค่าของคุณ",
        "GMAIL_OAUTH_REFRESH_TOKEN": "ใส่ค่าของคุณ",
        "GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL": "ใส่ค่าของคุณ",
        "GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY": "ใส่ค่าของคุณ",
        "GMAIL_IMPERSONATE_EMAIL": "ใส่ค่าของคุณ",
        "GMAIL_ENABLED_TOOLGROUPS": "ใส่ค่าของคุณ"
      }
    }
  }
}

เบราว์เซอร์จะถามก่อนเปิดแอป จากนั้นแอปแสดงค่าตั้งให้ตรวจแล้วกดยืนยัน ช่อง key เว้นว่างไว้ให้คุณใส่เอง

เปิดใน VS Code

หรือคัดลอกค่าตั้งเอง

วางในไฟล์ .vscode/mcp.json ของโปรเจกต์

{
  "servers": {
    "gmail": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "gmail-workspace-mcp-server"
      ],
      "env": {
        "GMAIL_OAUTH_CLIENT_ID": "ใส่ค่าของคุณ",
        "GMAIL_OAUTH_CLIENT_SECRET": "ใส่ค่าของคุณ",
        "GMAIL_OAUTH_REFRESH_TOKEN": "ใส่ค่าของคุณ",
        "GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL": "ใส่ค่าของคุณ",
        "GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY": "ใส่ค่าของคุณ",
        "GMAIL_IMPERSONATE_EMAIL": "ใส่ค่าของคุณ",
        "GMAIL_ENABLED_TOOLGROUPS": "ใส่ค่าของคุณ"
      }
    }
  }
}

เบราว์เซอร์จะถามก่อนเปิดแอป จากนั้นแอปแสดงค่าตั้งให้ตรวจแล้วกดยืนยัน ช่อง key เว้นว่างไว้ให้คุณใส่เอง

ตัวนี้รันในเครื่องคุณ แต่ ChatGPT ต่อได้เฉพาะ server บนอินเทอร์เน็ต ลองเลือกแอปอื่น

ตัวเลือกเก็บในคุกกี้บนเครื่องนี้ ไม่ต้องมีบัญชี

ค่าที่ต้องใส่เอง

  • GMAIL_OAUTH_CLIENT_ID ความลับ env
    OAuth2 client ID from Google Cloud Console (for personal Gmail accounts).
  • GMAIL_OAUTH_CLIENT_SECRET ความลับ env
    OAuth2 client secret from Google Cloud Console.
  • GMAIL_OAUTH_REFRESH_TOKEN ความลับ env
    Refresh token from the OAuth2 setup script.
  • GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL env
    Service account email address (for Google Workspace).
  • GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY ความลับ env
    Service account private key in PEM format (for Google Workspace).
  • GMAIL_IMPERSONATE_EMAIL env
    Email address to impersonate (required for service account mode).
  • GMAIL_ENABLED_TOOLGROUPS env
    Comma-separated list of tool groups to enable (readonly, readwrite, readwrite_external).

ค่าตั้งนี้สร้างจากข้อมูลใน registry ของผู้ทำ ถ้าไม่ตรงกับ README ให้เชื่อ README

ทำอะไรได้บ้าง

รันในเครื่องคุณ รายการเครื่องมือจะขึ้นในแอป AI หลังติดตั้ง

ผลตรวจเบื้องต้นi

เราตรวจจากข้อมูลที่ใครก็เปิดดูได้ ยังไม่ได้อ่านโค้ด ข้อที่ไม่เกี่ยวกับตัวนี้ไม่นับในตัวหาร · ตรวจเมื่อ 6 พ.ย. 2569

  • ✓ ผ่าน

    ตัวตนผู้ทำตรงกับ repo

    ชื่อใน registry ยืนยันโดเมน pulsemcp.com แล้ว (registry ตรวจความเป็นเจ้าของโดเมน)

  • … ยังไม่ตรวจ

    ยังมีคนดูแล

    ยังไม่ได้อ่านข้อมูล repo จาก GitHub

  • … ยังไม่ตรวจ

    มีสัญญาอนุญาต (license)

    ยังไม่ได้อ่านข้อมูล repo จาก GitHub

  • – ไม่เกี่ยว

    endpoint ตอบ

    ตัวนี้รันบนเครื่องคุณ ไม่มี endpoint บนอินเทอร์เน็ต

  • – ไม่เกี่ยว

    ล็อกอินแบบ OAuth

    ตัวนี้รันบนเครื่อง ใช้ค่าที่ตั้งในเครื่องแทน

  • … ยังไม่ตรวจ

    คำอธิบายเครื่องมือไม่มีคำสั่งแอบแฝง

    รันในเครื่องคุณ เราอ่านรายการเครื่องมือได้เฉพาะตัวที่มี endpoint บนอินเทอร์เน็ต

เทียบกับตัวอื่นในหมวด แชตและอีเมลi

  • ดาวมากกว่า 0% ของอีก 1765 ตัวในหมวดนี้
  • ส่งรุ่นใหม่เข้า registry ล่าสุดกว่า 27% ของอีก 1765 ตัวในหมวดนี้
  • ผลตรวจเบื้องต้นดีกว่าหรือเท่ากับ 100% ของอีก 1765 ตัวในหมวดนี้

เทียบกับทุก server ที่ยังใช้งานในหมวดนี้ทั้งทะเบียน ดาวนับเฉพาะเมื่อผู้ลงทะเบียนเป็นเจ้าของ repo

คำถามที่พบบ่อย

Gmail ปลอดภัยไหม?

จากการตรวจเบื้องต้นของเรา ผ่าน 1 จาก 1 ข้อที่ตรวจได้ เรายังไม่ได้อ่านโค้ด ก่อนใส่กุญแจหรือ token ให้ดูว่า server ขอสิทธิ์อะไร และเลือกกุญแจที่ทำได้เท่าที่จำเป็น

ต้องใช้กุญแจหรือรหัสอะไรบ้าง?

ต้องใส่ค่าเหล่านี้: GMAIL_OAUTH_CLIENT_ID, GMAIL_OAUTH_CLIENT_SECRET, GMAIL_OAUTH_REFRESH_TOKEN, GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY

ตัวนี้รันบนเครื่องหรือบนคลาวด์?

รันบนเครื่องของคุณ โปรแกรม AI จะเปิด server ขึ้นมาเองเมื่อใช้ ข้อมูลไม่ต้องผ่านเซิร์ฟเวอร์ของผู้ทำ (ยกเว้นตัวที่ไปเรียกบริการออนไลน์ต่อ)

ยังมีคนดูแลอยู่ไหม?

repo บน GitHub มีการแก้โค้ดล่าสุด – และส่งรุ่นล่าสุด (0.4.12) เข้า registry 2 เดือนที่ผ่านมา

ใช้กับโปรแกรมไหนได้บ้าง?

โปรแกรมที่รองรับ MCP เช่น Claude Desktop, Claude Code, Cursor และ VS Code ตัวนี้ต้องมี Node.js ในเครื่องด้วย

มีตัวไหนใช้แทนได้บ้าง?

ในหมวดเดียวกันมี Vexa, emailmd, MCP WhatsApp Cloud

ตัวที่ใช้แทนได้

server หมวดเดียวกันจากผู้ทำคนอื่น เรียงตามดาว

อ่านการ์ด:★ ดาว GitHubiสามเสา: รีวิว · ผลตรวจ · การใช้งานiอัปเดต = วันที่ส่งรุ่นล่าสุดเข้า registryi

Vexa

โดย Vexa-ai

Meeting bot and transcripts for Google Meet, Teams and Zoom. Live or after, speakers labelled.

รันบนคลาวด์★ 2,949Apache-2.0อัปเดต 2 เดือนที่ผ่านมา
ติดตั้ง

emailmd

โดย anypost

Render markdown into email-safe HTML, lint drafts for deliverability problems, and preview emails.

บนเครื่องหรือคลาวด์★ 1,385MITอัปเดต 31 วันที่ผ่านมา
ติดตั้ง

MCP WhatsApp Cloud

โดย codespar

MCP server for WhatsApp Cloud API (Meta) — messages, media, and templates via Graph API

รันบนเครื่อง★ 277MITอัปเดต 5 เดือนที่ผ่านมา
ติดตั้ง

README จากผู้ทำ

เปิดอ่าน README

ส่วนนี้คัดจาก repo ของผู้ทำตามต้นฉบับ PopNx MCP ไม่ได้ตรวจหรือรับรองเนื้อหา ตัด HTML รูปภาพ และสคริปต์ออกแล้ว ลิงก์จะพาออกนอกเว็บ

Gmail Workspace MCP Server

An MCP (Model Context Protocol) server that provides Gmail integration for AI assistants. Supports both personal Gmail accounts (via OAuth2) and Google Workspace accounts (via service account with domain-wide delegation).

Features

  • List Email Conversations: Retrieve emails with label filtering
  • Get Email Details: Fetch full email content including body and attachments info
  • Search Emails: Search using Gmail's powerful query syntax
  • Manage Emails: Mark as read/unread, star/unstar, archive, apply labels
  • Create Drafts: Compose draft emails with reply support
  • Send Emails: Send new emails or replies, directly or from drafts
  • Two Auth Methods: OAuth2 for personal accounts, Service Account for Google Workspace

Installation

npm install gmail-workspace-mcp-server

Or run directly with npx:

npx gmail-workspace-mcp-server

Authentication

This server supports two authentication modes. Choose the one that matches your account type.

Option 1: OAuth2 (Personal Gmail Accounts)

Use this for personal @gmail.com accounts or any Google account without Workspace admin access.

Prerequisites
  1. Go to Google Cloud Console
  2. Create or select a project
  3. Enable the Gmail API
  4. Configure the OAuth consent screen:
  • Choose External user type
  • Add yourself as a test user
  • Publish the app (click "Publish" on the consent screen) to prevent refresh tokens from expiring every 7 days. No full Google verification is needed for personal use.
  1. Create OAuth 2.0 credentials:
  • Choose Desktop app as the application type
  • Important: Create new credentials _after_ publishing the app
  1. Copy the Client ID and Client Secret
Getting a Refresh Token

Run the built-in setup command:

npx gmail-workspace-mcp-server oauth-setup <client_id> <client_secret>

You can also pass credentials via environment variables:

GMAIL_OAUTH_CLIENT_ID=... GMAIL_OAUTH_CLIENT_SECRET=... npx gmail-workspace-mcp-server oauth-setup

Port conflict? If port 3000 is already in use, specify a different port:

PORT=3001 npx gmail-workspace-mcp-server oauth-setup <client_id> <client_secret>

Desktop app credentials automatically allow http://localhost redirects on any port, so no additional Google Cloud Console configuration is needed.

This will open your browser for Google sign-in and print the refresh token. You only need to do this once — the refresh token does not expire (as long as the OAuth consent screen is published).

Environment Variables (OAuth2)
VariableRequiredDescription
GMAIL_OAUTH_CLIENT_IDYesOAuth2 client ID from Google Cloud Console
GMAIL_OAUTH_CLIENT_SECRETYesOAuth2 client secret
GMAIL_OAUTH_REFRESH_TOKENYesRefresh token from the setup script
GMAIL_ENABLED_TOOLGROUPSNoComma-separated list of tool groups (default: all)
Claude Desktop Configuration (OAuth2)
{

"mcpServers": { "gmail": { "command": "npx", "args": ["gmail-workspace-mcp-server"], "env": { "GMAIL_OAUTH_CLIENT_ID": "your-client-id.apps.googleusercontent.com", "GMAIL_OAUTH_CLIENT_SECRET": "your-client-secret", "GMAIL_OAUTH_REFRESH_TOKEN": "your-refresh-token" } } } }

Option 2: Service Account (Google Workspace)

Use this for Google Workspace organizations where a domain admin can grant domain-wide delegation.

Prerequisites
  1. Go to Google Cloud Console
  2. Create or select a project
  3. Enable the Gmail API
  4. Create a service account with domain-wide delegation enabled
  5. In Google Workspace Admin Console, grant the service account access to the following scopes:
  • https://www.googleapis.com/auth/gmail.readonly (read emails)
  • https://www.googleapis.com/auth/gmail.modify (modify labels)
  • https://www.googleapis.com/auth/gmail.compose (create drafts)
  • https://www.googleapis.com/auth/gmail.send (send emails)
  1. Download the JSON key file
Environment Variables (Service Account)
VariableRequiredDescription
GMAIL_SERVICE_ACCOUNT_CLIENT_EMAILYesService account email address
GMAIL_SERVICE_ACCOUNT_PRIVATE_KEYYesService account private key (PEM format)
GMAIL_IMPERSONATE_EMAILYesEmail address to impersonate
GMAIL_ENABLED_TOOLGROUPSNoComma-separated list of tool groups to enable (default: all groups)

You can find the client_email and private_key values in your service account JSON key file.

Claude Desktop Configuration (Service Account)
{

"mcpServers": { "gmail": { "command": "npx", "args": ["gmail-workspace-mcp-server"], "env": { "GMAIL_SERVICE_ACCOUNT_CLIENT_EMAIL": "my-service-account@my-project.iam.gserviceaccount.com", "GMAIL_SERVICE_ACCOUNT_PRIVATE_KEY": "[PopNx MCP ตัดค่าที่หน้าตาเหมือนกุญแจออก]", "GMAIL_IMPERSONATE_EMAIL": "user@yourdomain.com" } } } }

Note: For the private key, you can either:

  1. Use the key directly with \n for newlines (as shown above)
  2. Set the environment variable from a shell that preserves newlines

Tool Groups

The server supports three tool groups for permission-based access control:

GroupTools IncludedRisk Level
readonlylist_email_conversations, get_email_conversation, search_email_conversations, list_draft_emailsLow
readwriteAll readonly tools + change_email_conversation, upsert_draft_emailMedium
readwrite_externalAll readwrite tools + send_emailHigh

By default, all tool groups are enabled. To restrict access, set the GMAIL_ENABLED_TOOLGROUPS environment variable:

# Read-only access (no write/send capabilities)

GMAIL_ENABLED_TOOLGROUPS=readonly

Read and write, but no external sending

GMAIL_ENABLED_TOOLGROUPS=readwrite

Full access including sending emails (default)

GMAIL_ENABLED_TOOLGROUPS=readwrite_external

Security Note: The send_email tool is in a separate readwrite_external group because it can send emails externally, which carries higher risk than internal operations like modifying labels or creating drafts.

Available Tools

list_email_conversations

List email conversations from Gmail with optional filtering.

Parameters:

  • count (number, optional): Number of emails to return (default: 10, max: 100)
  • labels (string, optional): Comma-separated label IDs to filter by (default: "INBOX")
  • sort_by (string, optional): Sort order - "recent" (newest first) or "oldest" (default: recent)
  • after (string, optional): Only return emails after this datetime, exclusive (ISO 8601 UTC, e.g., "2024-01-15T14:30:00Z")
  • before (string, optional): Only return emails before this datetime, exclusive (ISO 8601 UTC, e.g., "2024-01-15T14:30:00Z")

Example:

{

"count": 20, "labels": "INBOX,STARRED", "after": "2024-01-15T00:00:00Z", "before": "2024-01-20T23:59:59Z" }

get_email_conversation

Retrieve the full content of a specific email by its ID.

Parameters:

  • email_id (string, required): The unique identifier of the email

Example:

{

"email_id": "18abc123def456" }

search_email_conversations

Search emails using Gmail's powerful query syntax.

Parameters:

  • query (string, required): Gmail search query (e.g., "from:user@example.com", "is:unread", "subject:meeting")
  • count (number, optional): Maximum results to return (default: 10, max: 100)

Example:

{

"query": "from:alice@example.com is:unread", "count": 20 }

change_email_conversation

Modify email labels and status (read/unread, starred, archived).

Parameters:

  • email_id (string, required): The email ID to modify
  • status (string, optional): "read", "unread", or "archived"
  • is_starred (boolean, optional): Star or unstar the email
  • labels (string, optional): Comma-separated labels to add
  • remove_labels (string, optional): Comma-separated labels to remove

Example:

{

"email_id": "18abc123def456", "status": "read", "is_starred": true }

list_draft_emails

List draft emails from Gmail with optional thread filtering.

Parameters:

  • count (number, optional): Maximum number of drafts to return (default: 10, max: 100)
  • thread_id (string, optional): Filter drafts by conversation thread ID

Example:

{

"thread_id": "18abc123def456" }

upsert_draft_email

Create, update, or delete a draft email. Optionally as a reply to an existing conversation.

Parameters:

  • draft_id (string, optional): ID of an existing draft to update or delete (omit to create a new draft)
  • delete (boolean, optional): Set to true to delete the draft specified by draft_id. All other parameters are ignored when deleting
  • to (string, required for create/update): Recipient email address
  • subject (string, required for create/update): Email subject
  • plaintext_body (string): Plain text body content (at least one of plaintext_body or html_body required for create/update)
  • html_body (string): HTML body content for rich text formatting (at least one of plaintext_body or html_body required for create/update)
  • cc (string, optional): CC recipients
  • bcc (string, optional): BCC recipients
  • thread_id (string, optional): Thread ID for replies
  • reply_to_email_id (string, optional): Email ID to reply to (sets References/In-Reply-To headers)

For create/update: at least one of plaintext_body or html_body must be provided. If both are provided, a multipart email is sent with both versions.

Example (create new draft):

{

"to": "recipient@example.com", "subject": "Meeting Follow-up", "plaintext_body": "Thanks for the meeting today!" }

Example (update existing draft):

{

"draft_id": "r123456789", "to": "recipient@example.com", "subject": "Meeting Follow-up (revised)", "html_body": " Thanks for the meeting today! Check out the notes . " }

Example (delete a draft):

{

"draft_id": "r123456789", "delete": true }

send_email

Send an email directly or from an existing draft.

Parameters:

  • to (string, conditional): Recipient email (required unless sending from draft)
  • subject (string, conditional): Email subject (required unless sending from draft)
  • plaintext_body (string): Plain text body content (at least one of plaintext_body or html_body required, unless sending a draft)
  • html_body (string): HTML body content for rich text formatting (at least one of plaintext_body or html_body required, unless sending a draft)
  • cc (string, optional): CC recipients
  • bcc (string, optional): BCC recipients
  • `from_d

ตัดมาแค่ช่วงต้น อ่านต่อใน repo

ถาม PopNx