AutomationFlowsAI & RAG › Route and Log Incoming Emails with Gpt-4, Excel 365 and Telegram

Route and Log Incoming Emails with Gpt-4, Excel 365 and Telegram

ByRamdoni @ramdoni on n8n.io

This workflow automatically analyzes incoming emails using AI, categorizes them, routes them to the appropriate department, logs the results in Excel 365, and sends notifications to the responsible team member via Telegram.

Manual trigger★★★★☆ complexityAI-powered15 nodesEmail Read ImapMicrosoft ExcelEmail SendTelegramOpenAI
AI & RAG Trigger: Manual Nodes: 15 Complexity: ★★★★☆ AI nodes: yes Added:

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

This workflow follows the Emailreadimap → Emailsend recipe pattern — see all workflows that pair these two integrations.

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": "yYi7kOLtNyyMtm7z",
  "meta": {
    "templateCredsSetupCompleted": true
  },
  "name": "AI Email Inbox \u2192 Excel 365 Smart Logger",
  "tags": [],
  "nodes": [
    {
      "id": "09a48a06-4a41-4086-8d6b-ecbcf09c8b66",
      "name": "Email Trigger (IMAP)",
      "type": "n8n-nodes-base.emailReadImap",
      "position": [
        176,
        32
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "583def6c-0cdc-4f9d-8188-ac49a281bec4",
      "name": "Extract Email Fields",
      "type": "n8n-nodes-base.set",
      "position": [
        384,
        32
      ],
      "parameters": {},
      "typeVersion": 3.4
    },
    {
      "id": "5f46ca75-d4e7-4a8e-aab8-6cbf85cb3113",
      "name": "Parse Summary",
      "type": "n8n-nodes-base.code",
      "position": [
        960,
        32
      ],
      "parameters": {},
      "typeVersion": 2
    },
    {
      "id": "85a35a38-0cd1-4287-9d34-05dde5937854",
      "name": "Append rows to table",
      "type": "n8n-nodes-base.microsoftExcel",
      "position": [
        176,
        768
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "27b697bf-1096-4dfc-9762-f84140653469",
      "name": "Prepare Excel Row",
      "type": "n8n-nodes-base.set",
      "position": [
        160,
        320
      ],
      "parameters": {},
      "typeVersion": 3.4
    },
    {
      "id": "850eb357-0f9c-4b6a-941e-564501f713b3",
      "name": "Sticky Note",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        -784,
        -144
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "0de7e2cd-2487-4c66-a61c-36b120e111df",
      "name": "Send email",
      "type": "n8n-nodes-base.emailSend",
      "position": [
        960,
        416
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "c9a09d61-2d5b-4f74-bb39-785824831794",
      "name": "Send Notification",
      "type": "n8n-nodes-base.telegram",
      "position": [
        960,
        240
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "7e546db4-8aba-448e-b786-3872a6ecfdc4",
      "name": "Validate Department",
      "type": "n8n-nodes-base.if",
      "position": [
        720,
        320
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "65e651d6-2a33-4b48-96e8-92b633359816",
      "name": "Lookup Department",
      "type": "n8n-nodes-base.microsoftExcel",
      "position": [
        512,
        320
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "4701869e-3809-473f-950a-d73a47c56005",
      "name": "Sticky Note1",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        128,
        -80
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "c46bea03-bb15-419c-a268-e75bfa479cd5",
      "name": "Sticky Note2",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        560,
        -80
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "eea548db-c384-49a0-98e3-291193c0d6a0",
      "name": "Sticky Note4",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        128,
        224
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    },
    {
      "id": "81c635c0-5a9f-4b35-8048-561171cc9dad",
      "name": "Message a model",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        624,
        32
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "34323f82-f685-44e9-bcdd-4d8d09e16de8",
      "name": "Sticky Note5",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        128,
        624
      ],
      "parameters": {
        "content": ""
      },
      "typeVersion": 1
    }
  ],
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "a7720c3c-5e9e-4d77-b8af-b79ec98ac21e",
  "connections": {
    "Parse Summary": {
      "main": [
        [
          {
            "node": "Prepare Excel Row",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Message a model": {
      "main": [
        [
          {
            "node": "Parse Summary",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Lookup Department": {
      "main": [
        [
          {
            "node": "Validate Department",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Prepare Excel Row": {
      "main": [
        [
          {
            "node": "Append rows to table",
            "type": "main",
            "index": 0
          },
          {
            "node": "Lookup Department",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Validate Department": {
      "main": [
        [
          {
            "node": "Send Notification",
            "type": "main",
            "index": 0
          },
          {
            "node": "Send email",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Email Trigger (IMAP)": {
      "main": [
        [
          {
            "node": "Extract Email Fields",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Extract Email Fields": {
      "main": [
        [
          {
            "node": "Message a model",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
Pro

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

About this workflow

This workflow automatically analyzes incoming emails using AI, categorizes them, routes them to the appropriate department, logs the results in Excel 365, and sends notifications to the responsible team member via Telegram.

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

More AI & RAG workflows → · Browse all categories →

Related workflows

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

AI & RAG

Use cases are many: Perfect for freelancers managing client invoices, small businesses handling supplier bills, accounting departments processing high invoice volumes, or anyone who wants to eliminate

OpenAI, Google Drive, Google Sheets +3
AI & RAG

This automated n8n workflow provides an AI-powered email classifier for support emails, automatically categorizing incoming emails and routing them to the appropriate inbox, creating a Jira task, and

Email Read Imap, OpenAI, Email Send +1
AI & RAG

🌸 The Quiet Evening Ritual — Wind-Down Automation (Telegram + Notion + Email)

Telegram, Telegram Trigger, OpenAI +2
AI & RAG

Stop manually reading every CV. This workflow watches your inbox, extracts CV text using Mistral OCR, scores every candidate against your job description using Google Gemini AI, and automatically rout

Email Read Imap, Mistral Ai, Google Gemini +1
AI & RAG

🌸 Overview

HTTP Request, Google Calendar, OpenAI +2