AutomationFlowsAI & RAG › AI Chat Agent with OpenAI

AI Chat Agent with OpenAI

Original n8n title: Chat (agent Node, No Tools)

04 - Chat (Agent Node, no tools). Uses agent, lmChatOpenAi. Webhook trigger; 4 nodes.

Webhook trigger★★☆☆☆ complexityAI-powered4 nodesAgentOpenAI Chat
AI & RAG Trigger: Webhook Nodes: 4 Complexity: ★★☆☆☆ AI nodes: yes Added:

This workflow corresponds to n8n.io template #1954 — we link there as the canonical source.

This workflow follows the Agent → OpenAI Chat recipe pattern — see all workflows that pair these two integrations.

The workflow JSON

Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →

Download .json
{
  "name": "04 - Chat (Agent Node, no tools)",
  "nodes": [
    {
      "parameters": {
        "httpMethod": "POST",
        "path": "agent-chat",
        "responseMode": "lastNode",
        "options": {}
      },
      "id": "e3f4854f-2b7e-43bf-9603-98b1c0fd9057",
      "name": "Webhook",
      "type": "n8n-nodes-base.webhook",
      "typeVersion": 2.1,
      "position": [
        -16,
        128
      ]
    },
    {
      "parameters": {
        "promptType": "define",
        "text": "={{$json.body.input}}",
        "options": {}
      },
      "id": "c3a10029-838a-4836-bf3c-475cfd6ccb24",
      "name": "AI Agent1",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "typeVersion": 3,
      "position": [
        192,
        128
      ]
    },
    {
      "parameters": {
        "model": {
          "__rl": true,
          "value": "openai/gpt-oss-20b",
          "mode": "id"
        },
        "options": {}
      },
      "id": "24af2cc7-55e6-4dc5-9c52-441a461f63ff",
      "name": "OpenAI Chat Model1",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "typeVersion": 1.2,
      "position": [
        64,
        336
      ],
      "credentials": {
        "openAiApi": {
          "name": "<your credential>"
        }
      }
    },
    {
      "parameters": {
        "keepOnlySet": true,
        "values": {
          "string": [
            {
              "name": "answer",
              "value": "={{$json.output || $json.response || $json.text || ''}}"
            }
          ]
        },
        "options": {}
      },
      "id": "Set-Agent-Response",
      "name": "Format Agent Response",
      "type": "n8n-nodes-base.set",
      "typeVersion": 2,
      "position": [
        432,
        128
      ]
    }
  ],
  "connections": {
    "Webhook": {
      "main": [
        [
          {
            "node": "AI Agent1",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "AI Agent1": {
      "main": [
        [
          {
            "node": "Format Agent Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model1": {
      "ai_languageModel": [
        [
          {
            "node": "AI Agent1",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    }
  },
  "active": false,
  "settings": {
    "executionOrder": "v1"
  },
  "versionId": "",
  "meta": {
    "templateId": "1954"
  },
  "tags": []
}

Credentials you'll need

Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.

Pro

For the full experience including quality scoring and batch install features for each workflow upgrade to Pro

About this workflow

04 - Chat (Agent Node, no tools). Uses agent, lmChatOpenAi. Webhook trigger; 4 nodes.

Source: https://github.com/slayerlux/n8n-llm-workflows/blob/main/workflows/04-agentic-chat.json — original creator credit. Request a take-down →

More AI & RAG workflows → · Browse all categories →

Related workflows

Workflows that share integrations, category, or trigger type with this one. All free to copy and import.

AI & RAG

This template is ideal for: Businesses that want to provide 24/7 automated voice-based customer support Service providers needing to schedule appointments via voice interaction Teams looking to handle

Agent, Tool Think, OpenAI Chat +3
AI & RAG

Description: This n8n workflow automates a Discord bot to fetch messages from a specified channel and send AI-generated responses in threads. It ensures smooth message processing and interaction, maki

Tool Calculator, Discord, OpenAI Chat +2
AI & RAG

AI chatbot for appointment scheduling. Uses memoryBufferWindow, lmChatOpenAi, toolWorkflow, chatTrigger. Webhook trigger; 12 nodes.

Memory Buffer Window, OpenAI Chat, Tool Workflow +4
AI & RAG

InstaTest. Uses memoryBufferWindow, lmChatOpenAi, respondToWebhook, stickyNote. Webhook trigger; 11 nodes.

Memory Buffer Window, OpenAI Chat, Agent
AI & RAG

Vapi Calendar. Uses agent, googleCalendarTool, toolCalculator, respondToWebhook. Webhook trigger; 11 nodes.

Agent, Google Calendar Tool, Tool Calculator +1