Templates / Run a RAG Messenger chatbot with Facebook, Google Drive, Supabase, OpenAI and OpenRouter

Run a RAG Messenger chatbot with Facebook, Google Drive, Supabase, OpenAI and OpenRouter

Ready for 3.0

by MADIAD ✓ · 7 views · created 2026-10-02 · 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 36 nodes and runs on Google Drive events (file created) (plus 3 other triggers). Along the way it connects Google Drive, Supabase Vector Store, Supabase and Embeddings OpenAI and 3 more.

How it runs

Trigger: On Google Drive events (file created) (plus 3 other triggers).

  1. Download the PDF (Google Drive): download
  2. Remove outdated vectors (Supabase): delete
  3. Remove vectors from database (Supabase): delete
  4. Prepare Webhook Verification (Edit Fields (Set)): sets 1 field: query.hub_challenge
  5. Filter Page Messages (If): checks a condition and branches into true / false
  6. Extract text from PDF (Extract from File): extracts data from a file (pdf)
  7. Download updated PDF (Google Drive): download
  8. Confirm file removed from Drive (Google Drive): delete file
  9. Respond to Webhook: sends the response back to the webhook caller
  10. Extract Messenger Data (Edit Fields (Set)): sets 3 fields: Id_Sender, Id_Page, User_Message

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

Services it uses

Google DriveSupabase Vector StoreSupabaseEmbeddings OpenAIFacebook Graph APIOpenRouter Chat ModelPostgres Chat Memory

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 (19)

From the author

Quick overview This workflow powers a Facebook Messenger chatbot that batches incoming user messages, answers with an OpenRouter chat model using RAG retrieval from a Supabase vector store, and keeps the knowledge base synced from PDFs in Google Drive (add,…

Excerpt from MADIAD'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.