RAG & GenAI App With WordPress Content
Configured with Agent, Aggregate, Chat Trigger, Document Default Data Loader, and additional nodes. Review the connections and setup before adapting this template.
Node categories in this workflow
- Trigger
- AI & models
- Files / media
- Transform
- Data store
- Web / API
- Integration
- Routing
Icons describe general node roles, inferred from node types. Inspect the parameters for the configured action.
Drag to pan; use + and − to zoom. Reconstructed from the exported node positions; nothing runs here. Dashed lines represent non-main connections. Full node names and notes appear below.
How it works
The exported workflow contains the following configured nodes. Their connections are shown above; inspect the JSON for the complete logic, expressions, and external actions.
| Node | Category | Type | Operation |
|---|---|---|---|
| When clicking ‘Test workflow’ | Trigger | Manual Trigger | See node parameters |
| Embeddings OpenAI | AI & models | Embeddings Open Ai | See node parameters |
| Default Data Loader | Files / media | Document Default Data Loader | See node parameters |
| Token Splitter | Transform | Text Splitter Token Splitter | See node parameters |
| Embeddings OpenAI1 | AI & models | Embeddings Open Ai | See node parameters |
| OpenAI Chat Model | AI & models | OpenAI Chat Model | See node parameters |
| Postgres Chat Memory | Data store | Memory Postgres Chat | See node parameters |
| Respond to Webhook | Web / API | Respond To Webhook | See node parameters |
| Set fields | Transform | Edit Fields | See node parameters |
| Embeddings OpenAI2 | AI & models | Embeddings Open Ai | See node parameters |
| Default Data Loader1 | Files / media | Document Default Data Loader | See node parameters |
| Token Splitter1 | Transform | Text Splitter Token Splitter | See node parameters |
| Markdown1 | Transform | Markdown | See node parameters |
| Postgres | Data store | Postgres | executeQuery |
| Aggregate | Transform | Aggregate | See node parameters |
| Aggregate1 | Transform | Aggregate | See node parameters |
| Aggregate2 | Transform | Aggregate | See node parameters |
| Wordpress - Get all posts | Integration | Wordpress | getAll |
| Wordpress - Get all pages | Integration | Wordpress | page / getAll |
| Set fields1 | Transform | Edit Fields | See node parameters |
| Filter - Only published & unprotected content | Routing | Filter | See node parameters |
| HTML To Markdown | Transform | Markdown | See node parameters |
| Supabase - Store workflow execution | Data store | Supabase | See node parameters |
| Every 30 seconds | Trigger | Schedule Trigger | See node parameters |
| Wordpress - Get posts modified after last workflow execution | Web / API | HTTP Request | See node parameters |
| Wordpress - Get posts modified after last workflow execution1 | Web / API | HTTP Request | See node parameters |
| Set fields2 | Transform | Edit Fields | See node parameters |
| Filter - Only published and unprotected content | Routing | Filter | See node parameters |
| Loop Over Items | Routing | Loop Over Items | See node parameters |
| Set fields3 | Transform | Edit Fields | See node parameters |
| Set fields4 | Transform | Edit Fields | See node parameters |
| Store documents on Supabase | Data store | Vector Store Supabase | See node parameters |
| Store workflow execution id and timestamptz | Data store | Supabase | See node parameters |
| Aggregate documents | Transform | Aggregate | See node parameters |
| Postgres - Create documents table | Data store | Postgres | executeQuery |
| Postgres - Create workflow execution history table | Data store | Postgres | executeQuery |
| Merge Wordpress Posts and Pages | Transform | Merge | See node parameters |
| Merge retrieved WordPress posts and pages | Transform | Merge | See node parameters |
| Postgres - Filter on existing documents | Data store | Postgres | executeQuery |
| Supabase - Delete row if documents exists | Data store | Supabase | delete |
| Switch | Routing | Switch | See node parameters |
| When chat message received | Trigger | Chat Trigger | See node parameters |
| Supabase - Retrieve documents from chatinput | Data store | Vector Store Supabase | See node parameters |
| AI Agent | AI & models | Agent | See node parameters |
| Supabase Vector Store | Data store | Vector Store Supabase | See node parameters |
Setup
- Download the JSON and import it into an isolated n8n instance. Leave the workflow inactive.
- Connect your own credentials through n8n’s credential store. Replace
REPLACE_WITH_*values with your resource identifiers. - Inspect API destinations, Code nodes, database queries, file paths, and outbound actions.
- Run with synthetic data and harmless destinations. Enable triggers only after checking the actual outputs.
Requirements
An n8n instance with the listed node types and compatible versions. Service-connected workflows may require accounts, credentials, or paid APIs.
Credential types declared in the source
None declared. HTTP requests and Code nodes may still need configuration.
Workflow notes
Switch:
Switch:
- If the document exists and has been updated: delete rows and insert new embedding
- If it’s a new document: insert embedding
RAG & GenAI App With WordPress Content
RAG & GenAI App With WordPress Content
Purpose and structure
This folder contains the RAG & GenAI App With WordPress Content workflow. Its executable nodes use agent, aggregate, chatTrigger, documentDefaultDataLoader, embeddingsOpenAi, filter, httpRequest, lmChatOpenAi, manualTrigger, markdown, memoryPostgresChat, merge, postgres, respondToWebhook, scheduleTrigger, set, splitInBatches, supabase, switch, textSplitterTokenSplitter, vectorStoreSupabase, wordpress. The table and connection map below are derived from the JSON, not an inferred guarantee of behavior.
Setup
Import inactive. Configure your own credentials and replace REPLACE_WITH_* values. Review external destinations and Code nodes before running.
Entry points
When clicking ‘Test workflow’, Every 30 seconds, When chat message received
Verification
Sanitized source candidate; not runtime-tested. This overview is generated from node metadata. Read the folder README for the connection map, credential types, and license.
Attribution
https://github.com/Zie619/n8n-workflows/blob/94007c1445d9258a7da116646b79473e7c7c3282/workflows/Postgres/1942_Postgres_Wordpress_Automation_Webhook.json MIT; preserve source notices.
Canvas section labels
These name areas of the original canvas; they do not include explanatory instructions.
- Workflow 1 : Initial Embedding
- Workflow 2 : Upsert
- Workflow 3 : Use this workflow to enable chat functionality with your website content. The chat can be embedded into your website to enhance user experience
- Use filters to create embeddings only for content that you want to include in your GenAI application
- Run these two nodes if the "documents" table on Supabase and the "n8n_website_embedding_histories" table do not exist
- Set this node to match the frequency of publishing and updating on your website
- Retrieve documents from Supabase immediately after chat input to send metadata to OpenAI