AutomationFlowsEmail & Gmail › Ai-powered Gmail Mcp Server

Ai-powered Gmail Mcp Server

ByLuciano Gutierrez @koresoluciones on n8n.io

This n8n workflow template leverages an external AI Model Control Plane (MCP) Server to automate various Gmail tasks, such as composing emails, replying to threads, and handling follow-ups using dynamically generated content. It uses the native n8n Gmail nodes available from…

Event trigger★★☆☆☆ complexityAI-powered5 nodesGmail ToolMcp Trigger
Email & Gmail Trigger: Event Nodes: 5 Complexity: ★★☆☆☆ AI nodes: yes Added:

This workflow corresponds to n8n.io template #3623 — we link there as the canonical source.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "id": "lYOQGMEJDxugrfrT",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "MCP_GMAIL",
  "tags": [],
  "nodes": [
    {
      "id": "c13105ec-6ac3-4179-a331-da5214ced6e6",
      "name": "SEND_EMAIL",
      "type": "n8n-nodes-base.gmailTool",
      "position": [
        -260,
        540
      ],
      "parameters": {
        "sendTo": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('To', ``, 'string') }}",
        "message": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
        "options": {},
        "subject": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Subject', ``, 'string') }}",
        "descriptionType": "manual",
        "toolDescription": "envia menssagems via API google"
      },
      "credentials": {
        "gmailOAuth2": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "0836faf7-59fd-41f5-9a54-3f467ed87db1",
      "name": "REPLY_EMAIL",
      "type": "n8n-nodes-base.gmailTool",
      "position": [
        -120,
        540
      ],
      "parameters": {
        "message": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
        "options": {},
        "messageId": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message_ID', ``, 'string') }}",
        "operation": "reply",
        "descriptionType": "manual"
      },
      "credentials": {
        "gmailOAuth2": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "892e89a7-8751-4c9f-87f3-a663ec0ca042",
      "name": "GET_EMAIL",
      "type": "n8n-nodes-base.gmailTool",
      "position": [
        0,
        540
      ],
      "parameters": {
        "simple": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Simplify', ``, 'boolean') }}",
        "options": {},
        "messageId": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message_ID', ``, 'string') }}",
        "operation": "get"
      },
      "credentials": {
        "gmailOAuth2": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "c1c2d8cd-6117-4238-b696-22da8f217f59",
      "name": "SEND_AND_WAIT",
      "type": "n8n-nodes-base.gmailTool",
      "position": [
        140,
        540
      ],
      "parameters": {
        "sendTo": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('To', ``, 'string') }}",
        "message": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
        "options": {},
        "subject": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Subject', ``, 'string') }}",
        "operation": "sendAndWait",
        "responseType": "freeText"
      },
      "credentials": {
        "gmailOAuth2": {
          "name": "<your credential>"
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "89c8bc41-cbf9-4099-a3ac-6d5d7cd1a626",
      "name": "MCP_GMAIL",
      "type": "@n8n/n8n-nodes-langchain.mcpTrigger",
      "position": [
        0,
        0
      ],
      "parameters": {
        "path": "/mcp/:tool/gmail"
      },
      "typeVersion": 1
    }
  ],
  "active": true,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "2022464f-822f-4b3e-9425-4e938a95348c",
  "connections": {
    "GET_EMAIL": {
      "ai_tool": [
        [
          {
            "node": "MCP_GMAIL",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "SEND_EMAIL": {
      "ai_tool": [
        [
          {
            "node": "MCP_GMAIL",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "REPLY_EMAIL": {
      "ai_tool": [
        [
          {
            "node": "MCP_GMAIL",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "SEND_AND_WAIT": {
      "ai_tool": [
        [
          {
            "node": "MCP_GMAIL",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    }
  }
}

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

This n8n workflow template leverages an external AI Model Control Plane (MCP) Server to automate various Gmail tasks, such as composing emails, replying to threads, and handling follow-ups using dynamically generated content. It uses the native n8n Gmail nodes available from…

Source: https://n8n.io/workflows/3623/ — original creator credit. Request a take-down →

More Email & Gmail workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

Email & Gmail

Gmail MCP Server Expose Gmail’s full API as a single SSE “tool server” endpoint for your AI agents.

Gmail Tool, Mcp Trigger
Email & Gmail

This workflow contains community nodes that are only compatible with the self-hosted version of n8n.

Mcp Trigger, Gmail Tool
Email & Gmail

MCP_GMAIL. Uses gmailTool, mcpTrigger. Event-driven trigger; 5 nodes.

Gmail Tool, Mcp Trigger
Email & Gmail

This workflow is for contractors, freelancers, local service businesses, and small teams that receive leads and customer requests through Gmail but do not have a dedicated sales or admin team.

Redis Trigger, Postgres, HTTP Request +5
Email & Gmail

This workflow automatically classifies and routes incoming Outlook emails into smart categories using n8n + OpenAI GPT-4.1-mini. It helps professionals and teams stay organized by intelligently sortin

Google Sheets, Gmail, Microsoft Outlook Trigger +3