⚡ Stacey – your Telegram AI assistant (powered by MCP, Gemini & Google tools)

1,204 views · ⚡ Personal Productivity

Description

> This n8n template builds Stacey, an AI assistant that runs inside Telegram. Stacey listens to your messages, understands what you want using AI, and intelligently routes commands to MCP-connected tools — like Gmail, Google Calendar, a blog writer, and more. > > For optimal performance, we recommend using OpenAI’s GPT-4o model. In this template, Google Gemini is used as a free alternative.


💡 Who is this for?

This workflow is designed for:


🧠 What this workflow does


⚙️ Prerequisites

Before using this workflow, make sure you have:


🚀 Step-by-Step Setup

✅ Step 1: Add Required Credentials in n8n

Go to Settings → Credentials and add:


✅ Step 2: Import the Workflow

  1. Go to n8n

  2. Click Workflows → Import from File

  3. Upload ai_assistant.json

  4. Connect your saved credentials to the correct nodes:

    • Telegram Trigger & Sender
    • Gmail, Calendar, Tavily, Gemini, Whisper

✅ Step 2.5: Import the Content Creator Sub-Workflow

The Content Creator is implemented as a modular sub-workflow and invoked through the Map Server as part of the MCP logic.

To set it up:

Go to Workflows → Import from File Upload content_creator_tool.json (provided in your files) Save it with a name like “Content Creator Tool” 🔗 Integration with MCP:

This tool is triggered via the MCP Map Server using an Execute Workflow node The AI agent chooses this tool when the user request involves writing blog posts, emails, product descriptions, etc. Make sure the tool ID or name in the Map Server matches what the AI agent uses in its logic You can customize this sub-workflow to:

Adjust writing prompts (e.g., tone, format, target audience) Add branching for different content types (e.g., blog vs. email) Send outputs directly to Gmail, Google Docs, or Sheets

✅ Step 3: Set Up Your Telegram Bot

  1. Talk to @BotFather

  2. Use /newbot to create a bot and get your token

  3. Paste this token into:

    • Telegram Trigger node (Telegram Trigger1)
    • Telegram Send Message node (Response1)
  4. Make sure your bot’s privacy is set correctly (use /setprivacy)


✅ Step 4: Customize Your Assistant’s Personality

  1. Open the “AI Agent” node

  2. In the systemMessage field, you’ll find a prompt that defines Stacey:

    • Her role is to delegate user requests to the right MCP tool
    • Includes examples, tone, rules, and logic
  3. You can customize Stacey’s:

    • Name
    • Behavior
    • Supported tools

✅ Step 5: Define Your MCP Tools (if extending)

This template includes:

To extend:


✅ Step 6: Test the Workflow

Open Telegram and message your bot:

The bot will:


✨ Customization Ideas

✏️ Add Voice Transcription

🧠 Upgrade to GPT-4o

🧩 Add More Tools


🧪 Troubleshooting

Telegram not responding?

Gmail actions not working?

AI not responding or behaving poorly?


🧾 Summary


🌟 Credits & License

Created by David Olusola Free to use, modify, and resell with attribution. If this helped you, please rate the template or follow me on the n8n Creator Page.


🔗 Nodes Used

Telegram, Telegram Trigger, AI Agent, Simple Memory, Calculator, Call n8n Workflow Tool

📥 Import

Download workflow.json and import into n8n: Workflow menu → Import from File

📖 Importing guide · 🔑 Credential setup