Run a human-approved shopping assistant with GPT-4.1-mini, product APIs and Slack
Needs changesNeeds changes. This template uses 1 thing(s) that n8n 3.0 removes: AI Agent v1 (old agent modes). 1 breaking item(s) found. Static check, last run 2026-10-19.
What to replace before upgrading
| Removed in 3.0 | Replace with |
|---|---|
| AI Agent v1 (old agent modes) AI Agent - Shopping Assistant (v1.6) | Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent. |
Nodes used (12)
- Chat Trigger
@n8n/n8n-nodes-langchain.chatTrigger - Manual Trigger
n8n-nodes-base.manualTrigger - Edit Fields (Set)
n8n-nodes-base.set - Http Request Tool
n8n-nodes-base.httpRequestTool - OpenAI Chat Model
@n8n/n8n-nodes-langchain.lmChatOpenAi - Simple Memory
@n8n/n8n-nodes-langchain.memoryBufferWindow - AI Agent
@n8n/n8n-nodes-langchain.agent - Code
n8n-nodes-base.code - If
n8n-nodes-base.if - Wait
n8n-nodes-base.wait - HTTP Request
n8n-nodes-base.httpRequest - Slack
n8n-nodes-base.slack
What it does
Quick overview This workflow powers a chat-based shopping assistant using OpenAI for conversation, an HTTP product-catalog search API for live item data, and a checkout/order API to place orders with explicit user approval, then posts the final order status to a Slack channel. How it works 1. Triggers from an n8n Chat Trigger (or a manual test run) when a user submits a shopping request. 2. Uses OpenAI (GPT-4.1-mini) with short-term memory and function calling to query a product-catalog search API for real-time price and availability before recommending up to three items. 3. Parses the agent’s structured JSON response into a reply, an optional product shortlist, and a purchase-intent signal with selected product and quantity. 4. If there is no purchase intent, returns the direct reply message; if there is purchase intent, pauses for the user to confirm the product selection via a resume webhook. 5. Pauses again for an explicit purchase approval via a second resume webhook, then submits the order to the store checkout API with the selected item, quantity, customer, payment method, and shipping details. 6. Waits for an asynchronous order-confirmation callback via a third resume webhook, then formats the order status and posts it to Slack. Setup 1. Add credentials for OpenAI, Slack, and HTTP Header Auth for both the product-catalog search API and the checkout/order API. 2. Update the configuration values for catalog and order base URLs, currency, customer ID, default shipping address, payment method ID, max budget, and the target Slack channel. 3. Copy the resume webhook URLs from the selection, approval, and order-confirmation wait steps and wire them into your chat UI buttons and your store/payment provider’s order-status callback.