π¬ Create personalized email outreach with AI, Telegram bot & website scraping
β‘ 709 views Β· π¬ Lead Nurturing & AI Sales Agents
π‘ Pro Tip β HTTP Request scraping tends to break when sites update their markup. If youβre scraping a major platform, check if ScraperNode covers it β it has maintained scrapers for LinkedIn, Instagram, TikTok, YouTube, and 20+ other platforms that return structured data.
Description
Demo Personalized Email
This n8n workflow is built for AI and automation agencies to promote their workflows through an interactive demo that prospects can try themselves.
The featured system is a deep personalized email demo.
π How It Works
-
Prospect Interaction
- A prospect starts the demo via Telegram.
- The Telegram bot (created with BotFather) connects directly to your n8n instance.
-
Demo Guidance
- The RAG agent and instructor guide the user step-by-step through the demo.
- Instructions and responses are dynamically generated based on user input.
-
Workflow Execution
- When the user triggers an action (e.g., testing the email demo), n8n runs the workflow.
- The workflow collects website data using Crawl4AI or standard HTTP requests.
-
Email Demo
- The system personalizes and sends a demo email through SparkPost, showing the automationβs capability.
-
Logging and Control
- Each user interaction is logged in your database using their
nameandid. - The workflow checks limits to prevent misuse or spam.
- Each user interaction is logged in your database using their
-
Error Handling
- If a low-CPU scraping method fails, the workflow automatically escalates to a higher-CPU method.
βοΈ Requirements
Before setting up, make sure you have the following:
- n8n β Automation platform to run the workflow
- Docker β Required to run Crawl4AI
- Crawl4AI β For intelligent website crawling
- Telegram Account β To create your Telegram bot via BotFather
- SparkPost Account β To send personalized demo emails
- A database (e.g., PostgreSQL, MySQL, or SQLite) β To store log data such as user name and ID
π Features
- Telegram interface using the BotFather API
- Instructor and RAG agent to guide prospects through the demo
- Flow generation limits per user ID to prevent abuse
- Low-cost yet powerful web scraping, escalating from low- to high-CPU flows if earlier ones fail
π‘ Development Ideas
- Replace the RAG logic with your own query-answering and guidance method
- Remove the flow limit if youβre confident the demo canβt be misused
- Swap the personalized email demo with any other workflow you want to showcase
π§ Technical Notes
- Telegram bot created with BotFather
- Website crawl process:
- Extract sub-links via
/sitemap.xml,sitemap_index.xml, or standard HTTP requests - Fall back to Crawl4AI if normal requests fail
- Fetch sub-link content via HTTPS or Crawl4AI as backup
- Extract sub-links via
- SparkPost used for sending demo emails
βοΈ Setup Instructions
1. Create a Telegram Bot
- Use BotFather on Telegram to create your bot and get the API token.
- This token will be used to connect your n8n workflow to Telegram.
2. Create a Log Data Table
- In your database, create a table to store user logs.
- The table must include at least the following columns:
nameβ to store the userβs name or Telegram username.idβ to store the userβs unique identifier.
3. Install Crawl4AI with Docker
- Follow the installation guide from the official repository:
π https://github.com/unclecode/crawl4ai - Crawl4AI will handle website crawling and content extraction in your workflow.
π¦ Notes
This setup is optimized for low cost, easy scalability, and real-time interaction with prospects.
You can customize each component β Telegram bot behavior, RAG logic, scraping strategy, and email workflow β to fit your agencyβs demo needs.
π You can try the live demo here: @email_demo_bot
π Nodes Used
Send Email, HTTP Request, Telegram, Telegram Trigger, Markdown, Schedule Trigger
π₯ Import
Download workflow.json and import into n8n:
Workflow menu β Import from File