Skip to product information

Sync Supabase Storage to Vector Store with OpenAI | n8n

Sync Supabase Storage to Vector Store with OpenAI | n8n

 (200+Reviews)
Regular price £73.99
Regular price £73.99 Sale price
SAVE Sold out
Instant Digital Download
Unlimited Downloads
Lifetime Access in Your Account
🔥
128+ Sold
Popular with n8n builders
23 people viewing
High interest right now
9 added today
Fast-moving digital product
Sync Supabase Storage to Vector Store with OpenAI | n8n

Sync Supabase Storage to Vector Store with OpenAI | n8n

Regular price £73.99
Regular price £73.99 Sale price
SAVE Sold out

Sync your Supabase Storage files into a vector store—and answer questions with an OpenAI-powered agent in n8n

This n8n workflow automatically syncs documents from Supabase Storage into a Supabase vector store using OpenAI embeddings, then provides a chat trigger where an AI agent retrieves relevant chunks and responds grounded in your indexed files.

What this workflow does

  • Runs a manual sync when you click “Test workflow”.
  • Reads what’s already indexed by fetching existing records from the Supabase files table.
  • Lists objects in Supabase Storage (from the private bucket), then compares storage objects to the files table.
  • Skips duplicates—it avoids files already indexed and ignores objects matching the .emptyFolderPlaceholder marker.
  • Downloads new files and extracts text (PDFs are parsed; files without an extension are treated as plain text).
  • Creates/updates indexing records by inserting a new row into the Supabase files table with fields like name and storage_id.
  • Chunks text and generates embeddings with OpenAI.
  • Inserts chunks into the Supabase vector table (documents) so they can be retrieved later.
  • Responds to chat: when a chat message is received, an AI agent uses OpenAI plus a Supabase vector search tool (via the required match_documents function) to retrieve top matches and answer based on the indexed content.

Use cases

  • Build a knowledge base from PDFs and text files stored in Supabase Storage.
  • Enable retrieval-augmented Q&A for internal docs, product materials, or support assets.
  • Keep a vector index up to date by running sync whenever new documents are uploaded.

Technical details

  • Integrations: Supabase Storage, Supabase (tables + vector store), OpenAI.
  • Workflow nodes / logic: if, merge, switch, supabase, aggregate, plus Sticky Notes.
  • Required database objects: files table (at least name, storage_id), documents vector table, and match_documents function.
View full details