Forecast demand, optimize pricing, and engage customers with GPT‑4.1, Postgres, email, and Slack
Ready for 3.0What this workflow does
This AI workflow has 31 nodes and runs when an HTTP POST request hits its webhook URL. Along the way it connects OpenAI Chat Model, Postgres and Slack.
How it runs
Trigger: When an HTTP POST request hits its webhook URL.
- Workflow Configuration (Edit Fields (Set)): sets 7 fields: lowStockThreshold, negativeSentimentThreshold, highDemandThreshold…
- Route by Data Type (Switch): routes items into 4 branches
- Normalize Orders (Edit Fields (Set)): sets 7 fields: orderId, customerId, orderDate…
- Normalize Reviews (Edit Fields (Set)): sets 7 fields: reviewId, productId, customerId…
- Normalize Inventory (Edit Fields (Set)): sets 7 fields: productId, productName, currentStock…
- Normalize Social Media (Edit Fields (Set)): sets 7 fields: postId, platform, content…
- Validate Orders (Filter): keeps only the items that match a condition
- Validate Reviews (Filter): keeps only the items that match a condition
- Validate Inventory (Filter): keeps only the items that match a condition
- Validate Social Media (Filter): keeps only the items that match a condition
…plus 16 more steps. See the full node list below.
Services it uses
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 (15)
- Webhook
n8n-nodes-base.webhook - Edit Fields (Set)
n8n-nodes-base.set - Switch
n8n-nodes-base.switch - Filter
n8n-nodes-base.filter - AI Agent
@n8n/n8n-nodes-langchain.agent - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Structured Output Parser
@n8n/n8n-nodes-langchain.outputParserStructured - Code
n8n-nodes-base.code - If
n8n-nodes-base.if - Merge
n8n-nodes-base.merge - Wait
n8n-nodes-base.wait - Postgres
n8n-nodes-base.postgres - Slack
n8n-nodes-base.slack - Send Email
n8n-nodes-base.emailSend - Remove Duplicates
n8n-nodes-base.removeDuplicates
From the author
How It Works This workflow automates inventory management and customer engagement for e-commerce businesses and retail operations managing multiple product categories. It solves the critical challenge of maintaining optimal stock levels while personalizing…