Soporte al Cliente

Avanzado

Este es unSupport Chatbot, Multimodal AIflujo de automatización del dominio deautomatización que contiene 27 nodos.Utiliza principalmente nodos como Code, Switch, Webhook, GmailTool, SupabaseTool. Chatbot de soporte al cliente para comercio electrónico impulsado por IA, integrado con GPT-4 y Supabase

Requisitos previos
  • Punto final de HTTP Webhook (n8n generará automáticamente)
  • Cuenta de Google y credenciales de API de Gmail
  • URL y Clave de API de Supabase
  • Clave de API de OpenAI
Vista previa del flujo de trabajo
Visualización de las conexiones entre nodos, con soporte para zoom y panorámica
Exportar flujo de trabajo
Copie la siguiente configuración JSON en n8n para importar y usar este flujo de trabajo
{
  "id": "uuSl9lDT5Kvcmorr",
  "meta": {
    "instanceId": "6b109f8b50fc175f161ecf0ec15aeda399ad29579e94d7b8c80910ef688285d8",
    "templateCredsSetupCompleted": true
  },
  "name": "Customer Support",
  "tags": [],
  "nodes": [
    {
      "id": "dfd932f3-1fe2-49a4-b914-a6d9c69cdbf6",
      "name": "Agente de IA",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        -220,
        -20
      ],
      "parameters": {
        "text": "=Here is the query of user  {{ $json.body.message }}",
        "options": {
          "systemMessage": "=You are an AI assistant that classifies customer support queries.\n\nYour task is to:\n1. Understand the user's message.\n2. Identify the **intent** behind the query.\n3. Extract any **mentioned product** or item.\n4. Respond in **strict JSON format**.\n5. If user did not asking about these things then reply with the assitant tone . don't forecfully try to classify everything to certain category.\n\nPossible intents:\n- \"order_status\" → Asking about delivery, shipping, or order update.\n- \"support_ticket\" → Complaints, issues, or help requests.\n- \"product_recommendation\" → Asking for product suggestions or alternatives.\n\nHere are some examples:\n\n---\nUser: \"Where is my headset?\"\nOutput:\n{ \"intent\": \"order_status\", \"product\": \"headset\" }\n\n---\nUser: \"My keyboard hasn’t arrived yet.\"\nOutput:\n{ \"intent\": \"order_status\", \"product\": \"keyboard\" }\n\n---\nUser: \"I need help with a broken mouse.\"\nOutput:\n{ \"intent\": \"support_ticket\", \"product\": \"mouse\" }\n\n---\nUser: \"Can you suggest something similar to a gaming chair?\"\nOutput:\n{ \"intent\": \"product_recommendation\", \"product\": \"gaming chair\" }\n\n---\nUser: \"Thanks for your help\"\nOutput:\n{ \"intent\":\"general\", \"product\":\"Happy to assists you . What else you need . Aske me i can help.\"}\n\n\n"
        },
        "promptType": "define"
      },
      "typeVersion": 2
    },
    {
      "id": "dd1aa1e5-eaa2-4617-85e5-71f93a4327bd",
      "name": "OpenAI Chat Model",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        -220,
        160
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4o-mini"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "Q7EegaddHu6FMk4i",
          "name": "OpenAi account"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "37a5d705-e4a3-43c5-9405-077f0bc2827c",
      "name": "Código",
      "type": "n8n-nodes-base.code",
      "position": [
        80,
        -20
      ],
      "parameters": {
        "jsCode": "// Loop over input items and add a new field called 'myNewField' to the JSON of each one\nresponse= JSON.parse($input.first().json.output)\nreturn {\"category\":response}"
      },
      "typeVersion": 2
    },
    {
      "id": "865fc0d3-679a-4368-8605-75a94bb00f59",
      "name": "Switch",
      "type": "n8n-nodes-base.switch",
      "position": [
        280,
        0
      ],
      "parameters": {
        "rules": {
          "values": [
            {
              "conditions": {
                "options": {
                  "version": 2,
                  "leftValue": "",
                  "caseSensitive": true,
                  "typeValidation": "strict"
                },
                "combinator": "and",
                "conditions": [
                  {
                    "id": "52528583-0e80-4335-aa15-660d2d500108",
                    "operator": {
                      "type": "string",
                      "operation": "equals"
                    },
                    "leftValue": "={{ $json.category.intent }}",
                    "rightValue": "order_status"
                  }
                ]
              }
            },
            {
              "conditions": {
                "options": {
                  "version": 2,
                  "leftValue": "",
                  "caseSensitive": true,
                  "typeValidation": "strict"
                },
                "combinator": "and",
                "conditions": [
                  {
                    "id": "fb71b829-1006-4f9f-80ed-3458d5ce4b63",
                    "operator": {
                      "name": "filter.operator.equals",
                      "type": "string",
                      "operation": "equals"
                    },
                    "leftValue": "={{ $json.category.intent }}",
                    "rightValue": "product_recommendation"
                  }
                ]
              }
            },
            {
              "conditions": {
                "options": {
                  "version": 2,
                  "leftValue": "",
                  "caseSensitive": true,
                  "typeValidation": "strict"
                },
                "combinator": "and",
                "conditions": [
                  {
                    "id": "ec099566-32cf-408b-a502-7d0f6ca742f4",
                    "operator": {
                      "name": "filter.operator.equals",
                      "type": "string",
                      "operation": "equals"
                    },
                    "leftValue": "={{ $json.category.intent }}",
                    "rightValue": "support_ticket"
                  }
                ]
              }
            },
            {
              "conditions": {
                "options": {
                  "version": 2,
                  "leftValue": "",
                  "caseSensitive": true,
                  "typeValidation": "strict"
                },
                "combinator": "and",
                "conditions": [
                  {
                    "id": "d3ad5c59-2938-4fc6-ad0f-c9fec160c589",
                    "operator": {
                      "name": "filter.operator.equals",
                      "type": "string",
                      "operation": "equals"
                    },
                    "leftValue": "={{ $json.category.intent }}",
                    "rightValue": "general"
                  }
                ]
              }
            }
          ]
        },
        "options": {
          "allMatchingOutputs": true
        }
      },
      "typeVersion": 3.2
    },
    {
      "id": "83768852-add1-4a23-a407-9a193b821580",
      "name": "Nota Adhesiva",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        240,
        -120
      ],
      "parameters": {
        "height": 100,
        "content": "#### order_status\n#### product_recommendations\n#### support_ticket\n"
      },
      "typeVersion": 1
    },
    {
      "id": "95fbe02c-e9b1-4fc1-9444-2b98e76e3b99",
      "name": "Consultas de Pedidos",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        840,
        -500
      ],
      "parameters": {
        "text": "=The query of the user is this .{{ $('Webhook').item.json.body.message }}",
        "options": {
          "systemMessage": "=You are a helpful AI assistant that handles customer support queries related to order tracking.\n\nYour job is to:\n1. Understand the customer's query.\n2. Extract any useful details like:\n   - `order_id` (e.g., ORD001)\n   - `product` name (e.g., keyboard)\n   - `customer_name` (optional, fallback if no order_id is given)\n3. If the intent is to check order status, you MUST call the `getOrderStatus` tool with the extracted order_id or product.\n4. Wait for the result from the tool and then respond clearly with the order status and ETA.\n\n---\n\nExamples:\n\nUser: \"Where is my keyboard? I think it was order ORD001\"\n→ Extract:\n{\n  \"intent\": \"order_status\",\n  \"order_id\": \"ORD001\",\n  \"product\": \"keyboard\"\n}\n→ Then call: getOrderStatus(order_id = \"ORD001\")\n\n---\n\nUser: \"I ordered a mouse last week. When will it arrive?\"\n→ Extract:\n{\n  \"intent\": \"order_status\",\n  \"product\": \"mouse\"\n}\n→ Then ask about the order_id first then move further\n\n---\n\nUser: \"I haven’t received my microphone yet\"\n→ Extract:\n{\n  \"intent\": \"order_status\",\n  \"product\": \"microphone\"\n}\n→ Then call: getOrderStatus(product = \"microphone\")\n\n---\n\nIf you do not have enough information to look up the order, ask for the `order ID` or product name politely.\n\nALWAYS return your final answer to the user in natural, friendly language, after getting the result from `getOrderStatus`.\n\nThe result value should be of string .\n"
        },
        "promptType": "define"
      },
      "typeVersion": 2
    },
    {
      "id": "9fe7972e-c225-4918-b8ad-5b30e35c6535",
      "name": "getOrderStatus",
      "type": "n8n-nodes-base.supabaseTool",
      "position": [
        1240,
        -320
      ],
      "parameters": {
        "filters": {
          "conditions": [
            {
              "keyName": "order_id",
              "keyValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('conditions0_Value', ``, 'string') }}"
            }
          ]
        },
        "tableId": "orders",
        "operation": "get"
      },
      "credentials": {
        "supabaseApi": {
          "id": "Wwp5fmAE6zpCGAJI",
          "name": "Supabase account"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "37d2380c-1f86-4d33-a8a1-096df1aa8741",
      "name": "OpenAI Chat Model1",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        860,
        -300
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4o-mini"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "Q7EegaddHu6FMk4i",
          "name": "OpenAi account"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "2075ef0b-9415-4267-9d79-f9b5cd752fcb",
      "name": "Memoria Simple",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        1080,
        -280
      ],
      "parameters": {
        "sessionKey": "={{ $('Webhook').item.json.body.session_id }}",
        "sessionIdType": "customKey",
        "contextWindowLength": 7
      },
      "typeVersion": 1.3
    },
    {
      "id": "5a1f1e85-580a-489a-8e89-0d0065f5bfe8",
      "name": "Memoria Simple1",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        -40,
        180
      ],
      "parameters": {
        "sessionKey": "={{ $json.body.session_id }}",
        "sessionIdType": "customKey",
        "contextWindowLength": 7
      },
      "typeVersion": 1.3
    },
    {
      "id": "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548",
      "name": "Agente de IA1",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        760,
        340
      ],
      "parameters": {
        "text": "=The message/qiery of the user {{ $('Webhook').item.json.body.message }}",
        "options": {
          "systemMessage": "=You are a smart and polite AI assistant that helps users manage customer support tickets.\n\nYou have **two main responsibilities**:\n1. 📝 Help users **create a new support ticket** when they report an issue.\n2. 📊 Help users **check the status** of an existing support ticket using their ticket ID.\n\n---\n\n### 1. SUPPORT TICKET CREATION\n\nIf the user reports an issue with a product (e.g., “my keyboard is not working”), your task is to:\n\n✅ Collect the following required information:\n\n- `user_email` → The customer's email address  \n   - If the email is not provided, ask the user to share it.\n   - Warn them that this email will be used by the company to contact them, so it must be correct.\n\n- `product` → The name of the product involved in the issue.\n\n- `issue` → A clear description of the problem.\n\n- `ticket_id` → Call the **Code tool** to generate a unique ticket ID.  \n   **Do NOT generate the ticket ID yourself.**\n\n---\n\n✅ Once all required fields are collected:\n\n- Call the **`createSupportTicket`** tool using:\n  - `ticket_id` (from the Code tool)\n  - `user_email`\n  - `product`\n  - `issue`\n  - `status = open`\n\n- Then, politely respond to the user like this:\n\n> “Thanks! Your support ticket has been created with Ticket ID **TKT-20250711-8471**. Our team will contact you at **ali@example.com**. You can use this ID anytime to check the ticket's progress.”\n\n---\n\n✅ Also, **send an email** to the company or support team with the ticket info using a connected email tool (e.g., SendGrid or SMTP):\n- Subject: `New Support Ticket Created - TKT-20250711-8471`\n- Include: `user_email`, `product`, `issue`\n\n---\n\n### 2. CHECK TICKET STATUS\n\nIf the user asks about an existing ticket's progress (e.g., “What's the update on TKT-20250711-8471?”):\n\n✅ Steps:\n- Extract the `ticket_id` from the message.\n- If not provided, ask the user to share their ticket ID.\n- Once available, call the **`getTicketStatus`** tool using the `ticket_id`.\n\n✅ Respond back to the user with:\n\n> “Your ticket **TKT-20250711-8471** is currently marked as **in progress**.  \n> Update: Our technician is working on your issue and will follow up soon.”\n\n---\n\n### BEHAVIOR RULES:\n\n- Always use a helpful, natural, and polite tone.\n- Don’t make up any values — especially ticket IDs.\n- Don’t submit the ticket until all required fields are collected.\n- If any field is missing, gently ask for it.\n\n---\n\n### EXAMPLE DIALOGUE:\n\n**User**: “My monitor keeps flickering.”\n→ Ask: “I’m sorry to hear that! Can you please share your email address? We’ll use it to contact you with updates.”\n\n**User**: “My headset is broken. Email: sara@example.com”\n→ Extract all info → Call Code tool for `ticket_id` → Call `createSupportTicket` → Respond with confirmation + ID\n\n**User**: “What’s going on with ticket TKT-20250711-8471?”\n→ Extract ID → Call `getTicketStatus` → Respond with current status and update notes\n\n---\n\nFollow these steps carefully to manage all support ticket interactions.\n\n\n## Important\n- don't the output with ** , / or any element which cause the invalid json while parsing. "
        },
        "promptType": "define"
      },
      "typeVersion": 2
    },
    {
      "id": "40fe3c62-7dd5-4db7-9179-e773cc151a0f",
      "name": "handle support tickets",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        500,
        600
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4o-mini"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "Q7EegaddHu6FMk4i",
          "name": "OpenAi account"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "2760705d-0971-46c8-bf42-a16e08341ca0",
      "name": "Memoria Simple2",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        640,
        620
      ],
      "parameters": {
        "sessionKey": "={{ $('Webhook').item.json.body.session_id }}",
        "sessionIdType": "customKey",
        "contextWindowLength": 7
      },
      "typeVersion": 1.3
    },
    {
      "id": "55cbecd5-9e0c-482c-89ff-413b8fb4b35b",
      "name": "Code Tool",
      "type": "@n8n/n8n-nodes-langchain.toolCode",
      "position": [
        860,
        640
      ],
      "parameters": {
        "jsCode": "const now = new Date();\nconst dateStr = now.toISOString().slice(0,10).replace(/-/g, '');\nconst random = Math.floor(1000 + Math.random() * 9000); // 4-digit code\nconst ticket_id = `TKT-${dateStr}-${random}`;\nreturn ticket_id",
        "description": "Call this tool to create the unique Ticket Id"
      },
      "typeVersion": 1.2
    },
    {
      "id": "eb443fb8-fd18-4983-b1c3-91f1c92d7563",
      "name": "Enviar",
      "type": "n8n-nodes-base.gmailTool",
      "position": [
        1140,
        620
      ],
      "webhookId": "e234df90-5074-4e47-8982-f228df61d50c",
      "parameters": {
        "sendTo": "seharn314@gmail.com",
        "message": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
        "options": {},
        "subject": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Subject', ``, 'string') }}"
      },
      "credentials": {
        "gmailOAuth2": {
          "id": "XPVAzucp2RRhHu9P",
          "name": "Gmail account"
        }
      },
      "typeVersion": 2.1
    },
    {
      "id": "35975b58-ce77-4837-b098-a5673ce5dc6f",
      "name": "createSupportTicket",
      "type": "n8n-nodes-base.supabaseTool",
      "position": [
        1000,
        640
      ],
      "parameters": {
        "tableId": "support_tickets",
        "fieldsUi": {
          "fieldValues": [
            {
              "fieldId": "ticket_id",
              "fieldValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('fieldValues0_Field_Value', ``, 'string') }}"
            },
            {
              "fieldId": "user_email",
              "fieldValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('fieldValues1_Field_Value', ``, 'string') }}"
            },
            {
              "fieldId": "product",
              "fieldValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('fieldValues2_Field_Value', ``, 'string') }}"
            },
            {
              "fieldId": "issue",
              "fieldValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('fieldValues3_Field_Value', ``, 'string') }}"
            },
            {
              "fieldId": "status",
              "fieldValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('fieldValues4_Field_Value', ``, 'string') }}"
            }
          ]
        }
      },
      "credentials": {
        "supabaseApi": {
          "id": "Wwp5fmAE6zpCGAJI",
          "name": "Supabase account"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "dcd292e1-bb3b-441e-a4bf-8b730bbc353f",
      "name": "getTicketStatus",
      "type": "n8n-nodes-base.supabaseTool",
      "position": [
        1260,
        600
      ],
      "parameters": {
        "filters": {
          "conditions": [
            {
              "keyName": "ticket_id",
              "keyValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('conditions0_Value', ``, 'string') }}"
            }
          ]
        },
        "tableId": "support_tickets",
        "operation": "get",
        "descriptionType": "manual",
        "toolDescription": "Tool can retrieve the information about any support ticket by its Ticket ID"
      },
      "credentials": {
        "supabaseApi": {
          "id": "Wwp5fmAE6zpCGAJI",
          "name": "Supabase account"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "a7b25883-96b5-4d98-9c9b-37fcd23d5315",
      "name": "Recomendaciones",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        1160,
        -40
      ],
      "parameters": {
        "text": "=The query of the user is this . {{ $('Webhook').item.json.body.message }}",
        "options": {
          "systemMessage": "=You are a helpful and polite AI assistant that suggests similar or related products based on what the user is looking for.\n\nYour job is to:\n1. Understand whether the user is asking for **product recommendations**, **similar items**, **suggestions**, or **alternatives**.\n2. Determine whether the user is referring to a **specific product** or a **product category**.\n3. Based on that:\n   - If the user refers to a **product name**, call the tool `getProductRecommendations` with the key `\"product\"`.\n   - If the user refers to a **product category**, call the tool `getCategoryRecommendations` with the key `\"category\"`.\n4. Wait for the tool response before replying.\n5. After receiving the tool result, present the recommended products in a helpful, friendly tone.\n\n---\n\n### 🔍 Input Understanding Rules\n\n- If the user says something like “Can you suggest something like a wireless mouse?”, interpret this as a **product-based recommendation**.\n  - Extract: `\"product\": \"wireless mouse\"`\n  - Call: `getProductRecommendations`\n\n- If the user says something like “What are some good accessories for laptops?” or “Suggest something in audio equipment,” interpret this as a **category-based recommendation**.\n  - Extract: `\"category\": \"laptop accessories\"` or `\"audio equipment\"` or `\"display\"` , `\"audio\"`\n  - Call: `getCategoryRecommendations`\n\n---\n\n### ⚠️ Missing Info Handling\n\nIf the user does not clearly mention a product or category, politely ask:\n> “Could you please tell me the product or category you’re interested in so I can recommend something useful?”\n\n---\n\n"
        },
        "promptType": "define"
      },
      "typeVersion": 2
    },
    {
      "id": "5ac4c297-01f9-4f30-8e8a-55479a73dfe0",
      "name": "OpenAI Chat Model2",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        1140,
        160
      ],
      "parameters": {
        "model": {
          "__rl": true,
          "mode": "list",
          "value": "gpt-4o-mini"
        },
        "options": {}
      },
      "credentials": {
        "openAiApi": {
          "id": "Q7EegaddHu6FMk4i",
          "name": "OpenAi account"
        }
      },
      "typeVersion": 1.2
    },
    {
      "id": "cda9abdf-cabe-4127-9507-66392d712769",
      "name": "Memoria Simple3",
      "type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
      "position": [
        1280,
        180
      ],
      "parameters": {
        "sessionKey": "={{ $('Webhook').item.json.body.session_id }}",
        "sessionIdType": "customKey",
        "contextWindowLength": 7
      },
      "typeVersion": 1.3
    },
    {
      "id": "11aa9f9e-1acb-45ee-986c-4298b228dc5d",
      "name": "getCategoryRecommendations",
      "type": "n8n-nodes-base.supabaseTool",
      "position": [
        1400,
        200
      ],
      "parameters": {
        "filters": {
          "conditions": [
            {
              "keyName": "category",
              "keyValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('conditions1_Value', ``, 'string') }}"
            }
          ]
        },
        "tableId": "products",
        "operation": "get",
        "descriptionType": "manual",
        "toolDescription": "Call this tool when you want recommendation based on the category."
      },
      "credentials": {
        "supabaseApi": {
          "id": "Wwp5fmAE6zpCGAJI",
          "name": "Supabase account"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "130277bc-6cbf-48e2-9b16-a94bc1088d31",
      "name": "getProductRecommendations",
      "type": "n8n-nodes-base.supabaseTool",
      "position": [
        1540,
        140
      ],
      "parameters": {
        "filters": {
          "conditions": [
            {
              "keyName": "name",
              "keyValue": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('conditions0_Value', ``, 'string') }}"
            }
          ]
        },
        "tableId": "products",
        "operation": "get",
        "descriptionType": "manual",
        "toolDescription": "Call this tool if you want recommendation based on the product name."
      },
      "credentials": {
        "supabaseApi": {
          "id": "Wwp5fmAE6zpCGAJI",
          "name": "Supabase account"
        }
      },
      "typeVersion": 1
    },
    {
      "id": "3ca4c1cb-6a0d-49c5-ad2d-94ab800a3437",
      "name": "Webhook",
      "type": "n8n-nodes-base.webhook",
      "position": [
        -440,
        -20
      ],
      "webhookId": "4cdaa2e9-be46-4f60-83f6-8d7bd4a6ad5d",
      "parameters": {
        "path": "4cdaa2e9-be46-4f60-83f6-8d7bd4a6ad5d",
        "options": {},
        "httpMethod": "POST",
        "responseMode": "responseNode"
      },
      "typeVersion": 2
    },
    {
      "id": "015084ec-64f3-4bae-8aee-3f826c383c71",
      "name": "Respond to Webhook",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1200,
        -500
      ],
      "parameters": {
        "options": {},
        "respondWith": "json",
        "responseBody": "={\n  \"response\": \"{{ $json.output.replace(/[\\n\\r\\t]+/g, ' ').replace(/\\s{2,}/g, ' ').trim() }}\"\n}\n"
      },
      "typeVersion": 1.4
    },
    {
      "id": "cfe0f477-ae44-45cc-b3c1-33575934607b",
      "name": "Respond to Webhook1",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1560,
        -40
      ],
      "parameters": {
        "options": {},
        "respondWith": "json",
        "responseBody": "={\n\"response\":\"{{ JSON.stringify($json.output) }}\"\n}"
      },
      "typeVersion": 1.4
    },
    {
      "id": "8251dd9d-41b8-413b-a97e-aa086b6f66c6",
      "name": "Respond to Webhook2",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        1120,
        340
      ],
      "parameters": {
        "options": {},
        "respondWith": "json",
        "responseBody": "={\n  \"response\": \"{{ $json.output.replace(/[\\n\\r\\t]+/g, ' ').replace(/\\s{2,}/g, ' ').trim() }}\"\n}\n"
      },
      "typeVersion": 1.4
    },
    {
      "id": "0d6e5c87-9824-493f-a492-dead40212114",
      "name": "Respond to Webhook3",
      "type": "n8n-nodes-base.respondToWebhook",
      "position": [
        280,
        440
      ],
      "parameters": {
        "options": {},
        "respondWith": "json",
        "responseBody": "={\n  \"response\": \"{{ $json.category.product }}\"\n}"
      },
      "typeVersion": 1.4
    }
  ],
  "active": true,
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "0c596213-59ce-4080-b740-b2b6c6e3981d",
  "connections": {
    "37a5d705-e4a3-43c5-9405-077f0bc2827c": {
      "main": [
        [
          {
            "node": "865fc0d3-679a-4368-8605-75a94bb00f59",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "eb443fb8-fd18-4983-b1c3-91f1c92d7563": {
      "ai_tool": [
        [
          {
            "node": "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "865fc0d3-679a-4368-8605-75a94bb00f59": {
      "main": [
        [
          {
            "node": "95fbe02c-e9b1-4fc1-9444-2b98e76e3b99",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "a7b25883-96b5-4d98-9c9b-37fcd23d5315",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "0d6e5c87-9824-493f-a492-dead40212114",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "3ca4c1cb-6a0d-49c5-ad2d-94ab800a3437": {
      "main": [
        [
          {
            "node": "dfd932f3-1fe2-49a4-b914-a6d9c69cdbf6",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "dfd932f3-1fe2-49a4-b914-a6d9c69cdbf6": {
      "main": [
        [
          {
            "node": "37a5d705-e4a3-43c5-9405-077f0bc2827c",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548": {
      "main": [
        [
          {
            "node": "8251dd9d-41b8-413b-a97e-aa086b6f66c6",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "55cbecd5-9e0c-482c-89ff-413b8fb4b35b": {
      "ai_tool": [
        [
          {
            "node": "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "95fbe02c-e9b1-4fc1-9444-2b98e76e3b99": {
      "main": [
        [
          {
            "node": "015084ec-64f3-4bae-8aee-3f826c383c71",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "2075ef0b-9415-4267-9d79-f9b5cd752fcb": {
      "ai_memory": [
        [
          {
            "node": "95fbe02c-e9b1-4fc1-9444-2b98e76e3b99",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "5a1f1e85-580a-489a-8e89-0d0065f5bfe8": {
      "ai_memory": [
        [
          {
            "node": "dfd932f3-1fe2-49a4-b914-a6d9c69cdbf6",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "2760705d-0971-46c8-bf42-a16e08341ca0": {
      "ai_memory": [
        [
          {
            "node": "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "cda9abdf-cabe-4127-9507-66392d712769": {
      "ai_memory": [
        [
          {
            "node": "a7b25883-96b5-4d98-9c9b-37fcd23d5315",
            "type": "ai_memory",
            "index": 0
          }
        ]
      ]
    },
    "9fe7972e-c225-4918-b8ad-5b30e35c6535": {
      "ai_tool": [
        [
          {
            "node": "95fbe02c-e9b1-4fc1-9444-2b98e76e3b99",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "a7b25883-96b5-4d98-9c9b-37fcd23d5315": {
      "main": [
        [
          {
            "node": "cfe0f477-ae44-45cc-b3c1-33575934607b",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "dcd292e1-bb3b-441e-a4bf-8b730bbc353f": {
      "ai_tool": [
        [
          {
            "node": "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "dd1aa1e5-eaa2-4617-85e5-71f93a4327bd": {
      "ai_languageModel": [
        [
          {
            "node": "dfd932f3-1fe2-49a4-b914-a6d9c69cdbf6",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "37d2380c-1f86-4d33-a8a1-096df1aa8741": {
      "ai_languageModel": [
        [
          {
            "node": "95fbe02c-e9b1-4fc1-9444-2b98e76e3b99",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "5ac4c297-01f9-4f30-8e8a-55479a73dfe0": {
      "ai_languageModel": [
        [
          {
            "node": "a7b25883-96b5-4d98-9c9b-37fcd23d5315",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "015084ec-64f3-4bae-8aee-3f826c383c71": {
      "main": [
        []
      ]
    },
    "cfe0f477-ae44-45cc-b3c1-33575934607b": {
      "main": [
        []
      ]
    },
    "35975b58-ce77-4837-b098-a5673ce5dc6f": {
      "ai_tool": [
        [
          {
            "node": "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "40fe3c62-7dd5-4db7-9179-e773cc151a0f": {
      "ai_languageModel": [
        [
          {
            "node": "fe9f6c92-70d3-4ef9-90e3-f39f16d2a548",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "130277bc-6cbf-48e2-9b16-a94bc1088d31": {
      "ai_tool": [
        [
          {
            "node": "a7b25883-96b5-4d98-9c9b-37fcd23d5315",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    },
    "11aa9f9e-1acb-45ee-986c-4298b228dc5d": {
      "ai_tool": [
        [
          {
            "node": "a7b25883-96b5-4d98-9c9b-37fcd23d5315",
            "type": "ai_tool",
            "index": 0
          }
        ]
      ]
    }
  }
}
Preguntas frecuentes

¿Cómo usar este flujo de trabajo?

Copie el código de configuración JSON de arriba, cree un nuevo flujo de trabajo en su instancia de n8n y seleccione "Importar desde JSON", pegue la configuración y luego modifique la configuración de credenciales según sea necesario.

¿En qué escenarios es adecuado este flujo de trabajo?

Avanzado - Chatbot de soporte, IA Multimodal

¿Es de pago?

Este flujo de trabajo es completamente gratuito, puede importarlo y usarlo directamente. Sin embargo, tenga en cuenta que los servicios de terceros utilizados en el flujo de trabajo (como la API de OpenAI) pueden requerir un pago por su cuenta.

Información del flujo de trabajo
Nivel de dificultad
Avanzado
Número de nodos27
Categoría2
Tipos de nodos11
Descripción de la dificultad

Adecuado para usuarios avanzados, flujos de trabajo complejos con 16+ nodos

Autor

I design powerful n8n workflows that save businesses hours of work every week. From lead generation to AI-powered automation, I create plug-and-play solutions you can integrate in minutes. Let’s automate your success.

Enlaces externos
Ver en n8n.io

Compartir este flujo de trabajo

Categorías

Categorías: 34