Templates / Run a Telegram RAG support chatbot with OpenAI, Pinecone, and Google Sheets

Run a Telegram RAG support chatbot with OpenAI, Pinecone, and Google Sheets

Ready for 3.0

by isaWOW ✓ · 74 views · created 2026-07-09 · Support Chatbot, AI RAG

Ready for 3.0. This template uses no nodes that n8n 3.0 removes. No removed nodes, versions or helpers found. Static check, last run 2026-10-19.

What this workflow does

This AI workflow has 20 nodes and runs on Telegram events (message). Along the way it connects Telegram, OpenAI and Google Sheets. It also calls api.openai.com over HTTP.

How it runs

Trigger: On Telegram events (message).

  1. 2. Code - Detect Message Type (Code): runs custom JavaScript code
  2. 3. Switch - Route by Message Type (Switch): routes items into 5 branches
  3. 13. Code - Build Query Text from Any Input (Code): runs custom JavaScript code
  4. 4. Telegram - Get Voice File URL (Telegram): work with file
  5. 7. Telegram - Get Photo File URL (Telegram): work with file
  6. 10. Telegram - Get Document File URL (Telegram): work with file
  7. 14. HTTP - OpenAI Embed Query (HTTP Request): calls api.openai.com (POST)
  8. 5. HTTP - Download Voice File (HTTP Request): calls an HTTP API
  9. 8. HTTP - Download Photo File (HTTP Request): calls an HTTP API
  10. 11. HTTP - Download Document File (HTTP Request): calls an HTTP API

…plus 9 more steps. See the full node list below.

Services it uses

TelegramOpenAIGoogle Sheets

HTTP calls to: api.openai.com

Before you upgrade to n8n 3.0

Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.

Nodes used (8)

From the author

Quick overview This workflow turns a Telegram bot into a multi-modal support chatbot that accepts text, voice, images, and PDFs, converts them to text, retrieves relevant knowledge from Pinecone using OpenAI embeddings, generates a grounded answer with OpenAI…

Excerpt from isaWOW's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.