Skip to main content

Create professional email drafts with GPT-4, Telegram & contact database

Workflow preview

Workflow preview
100%
Create professional email drafts with GPT-4, Telegram & contact database preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Transform your email workflow with this intelligent automation that drafts professional emails through Telegram commands using AI and contact retrieval. Key Features Telegram Integration: Send e...

Best for

  • AI Chatbot automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

n8n-nodes-base.manualtrigger, @n8n/n8n-nodes-langchain.vectorstorepinecone, @n8n/n8n-nodes-langchain.embeddingsopenai, @n8n/n8n-nodes-langchain.documentdefaultdataloader, n8n-nodes-base.stickynote, @n8n/n8n-nodes-langchain.agent, n8n-nodes-base.code, n8n-nodes-base.gmail

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Ninja - Abbas.

Original n8n.io source

1.1 Workflow description

Title
Create professional email drafts with GPT-4, Telegram & contact database
Workflow name
Create professional email drafts with GPT-4, Telegram & contact database

Transform your email workflow with this intelligent automation that drafts professional emails through Telegram commands using AI and contact retrieval. Key Features

📱 Telegram Integration: Send email requests directly from Telegram 🤖 AI-Powered Email Generation: Uses OpenAI GPT-4 to create formal, professional emails 📧 Smart Contact Retrieval: Leverages Pinecone vector database with RAG to automatically find recipient email addresses ✉️ Gmail Draft Creation: Automatically creates email drafts in your Gmail account 📋 Google Docs Integration: Sync contact data from Google Docs to vector database 🎯 Structured Email Formatting: Ensures consistent professional email format with proper recipients and formal tone

How It Works

Send Message: Send a message via Telegram with your email request AI Processing: AI agent processes your request and queries the contact database to find recipient emails Email Generation: OpenAI generates a professionally formatted email based on your input Draft Creation: Gmail draft is automatically created with the formatted content Confirmation: Receive confirmation via Telegram with a completion sticker

Perfect For

Business professionals managing multiple contacts Academic professionals (professors, researchers) who frequently send formal emails Anyone wanting to streamline their email creation process with AI assistance

Required Credentials

Telegram Bot API OpenAI API google OAuth2 for(gmail&docs) Pinecone Vector Database

Setup Instructions

Load Contact Data: Add your contact information to the Google Docs document Configure Pinecone: Set up your Pinecone index with namespace "contacts" Connect Services: Add all required API credentials to their respective nodes Customize AI: Modify the AI system message and sender name in the AI Agent node Test Workflow: Run the manual trigger to populate your vector database first **

Ex. of the google docs data

1.2 Logical Blocks

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.

2. Block-by-Block Analysis

Block 1 - When clicking ‘Execute workflow’

Type / Role
n8n-nodes-base.manualTrigger - manualTrigger
Config choices
Version 1

Block 2 - Pinecone Vector Store

Type / Role
@n8n/n8n-nodes-langchain.vectorStorePinecone - vectorStorePinecone
Config choices
Version 1.3

Block 3 - Embeddings OpenAI

Type / Role
@n8n/n8n-nodes-langchain.embeddingsOpenAi - embeddingsOpenAi
Config choices
Version 1.2

Block 4 - Default Data Loader

Type / Role
@n8n/n8n-nodes-langchain.documentDefaultDataLoader - documentDefaultDataLoader
Config choices
Version 1.1

Block 5 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 6 - AI Agent

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 2.2

Block 7 - Pinecone Vector Store1

Type / Role
@n8n/n8n-nodes-langchain.vectorStorePinecone - vectorStorePinecone
Config choices
Version 1.3

Block 8 - Embeddings OpenAI1

Type / Role
@n8n/n8n-nodes-langchain.embeddingsOpenAi - embeddingsOpenAi
Config choices
Version 1.2

Block 9 - Code

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 10 - Create a draft

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.1

Block 11 - Get a document

Type / Role
n8n-nodes-base.googleDocs - googleDocs
Config choices
Version 2

Block 12 - Send a sticker

Type / Role
n8n-nodes-base.telegram - telegram
Config choices
Version 1.2

Block 13 - Telegram Trigger

Type / Role
n8n-nodes-base.telegramTrigger - telegramTrigger
Config choices
Version 1.2

Block 14 - Send a text message

Type / Role
n8n-nodes-base.telegram - telegram
Config choices
Version 1.2

Block 15 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 16 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 17 - OpenAI Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

3. Summary Table

Workflow Create professional email drafts with GPT-4, Telegram & contact database
Complexity advanced
Nodes 17
Categories AI Chatbot
Author Ninja - Abbas
Published 08 Sept 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/8395/8395.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

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.

Frequently asked questions

What does Create professional email drafts with GPT-4, Telegram & contact database do?

Transform your email workflow with this intelligent automation that drafts professional emails through Telegram commands using AI and contact retrieval. Key Features Telegram Integration: Send e...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

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 AI Chatbot use case.