Block 1 - Get many messages
- Type / Role
- n8n-nodes-base.gmail - gmail
- Config choices
- Version 2.1
This workflow is provided as-is. Please review and test before using in production.
Summary Send a number to your Telegram bot (e.g., 2) and get a neatly formatted digest of all Gmail newsletters received since that date. Each email is summarized by an LLM into concise topics, mer...
n8n-nodes-base.gmail, n8n-nodes-base.telegramtrigger, n8n-nodes-base.splitinbatches, n8n-nodes-base.code, n8n-nodes-base.telegram, @n8n/n8n-nodes-langchain.openai, n8n-nodes-base.stickynote
This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Vlad Arbatov.
Original n8n.io sourceSend a number to your Telegram bot (e.g., 2) and get a neatly formatted digest of all Gmail newsletters received since that date. Each email is summarized by an LLM into concise topics, merged into a single Telegram message, automatically split into chunks to fit Telegram limits, and safely formatted as HTML.
Node map
| Node | Type | Purpose |
|---|---|---|
| Telegram Trigger | Trigger | Receive daysAgo command from Telegram |
| Get days | Code | Compute Gmail after:YYYY/MM/DD from daysAgo |
| Get many messages | Gmail (getAll) | Search emails since date with custom from: filters |
| Loop Over Items | Split in Batches | Iterate messages one-by-one |
| Get a message | Gmail (get) | Fetch full message payload |
| Get message data | Code | Extract HTML/subject/from/date; normalize sender and date |
| Clean | Code | Reformat date and forward fields to LLM |
| Message a model | OpenAI | Summarize email into JSON topics |
| Merge | Code | Merge topics from all emails |
| Create TG message | Code | Build human-friendly digest text |
| Split | Code | Chunk into 3 500‑char parts |
| Sanitize | Code | Escape HTML and map Markdown to Telegram HTML |
| Send a message | Telegram | Deliver digest to Telegram chat |
<b> and <i> only; avoid other HTML tagsSample output format (Telegram)
One-sentence description
Original Subject Line → Sender Name — DD.MM.YYYY
...
<b>, <i>This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.
| Workflow | On-demand email newsletter summaries from Gmail to Telegram with GPT-4.1-mini |
|---|---|
| Complexity | advanced |
| Nodes | 16 |
| Categories | Personal Productivity, Multimodal AI |
| Author | Vlad Arbatov |
| Published | 11 Aug 2025 |
Use the JSON export at /data/workflows/7254/7254.json as the source template for this automation.
Open n8n, import the downloaded JSON, and review each node before activating the workflow.
Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.
Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.
Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.
Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.
Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.
Summary Send a number to your Telegram bot (e.g., 2) and get a neatly formatted digest of all Gmail newsletters received since that date. Each email is summarized by an LLM into concise topics, mer...
Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.
Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Personal Productivity, Multimodal AI use case.