Skip to main content

Company website chatbot agent (RAG, calendar integrations)

Workflow preview

Workflow preview
100%
Company website chatbot agent (RAG, calendar integrations) preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Company Website Chatbot Agent Overview This workflow implements a modular Website AI Chatbot Assistant capable of handling multiple types of customer interactions autonomously. Instead of relying o...

Best for

  • Support Chatbot automation workflows
  • AI Chatbot automation workflows
  • intermediate n8n builders looking for reusable templates

Tools used

@n8n/n8n-nodes-langchain.chattrigger, @n8n/n8n-nodes-langchain.lmchatopenai, @n8n/n8n-nodes-langchain.toolworkflow, @n8n/n8n-nodes-langchain.memorybufferwindow, n8n-nodes-base.stickynote, @n8n/n8n-nodes-langchain.agent

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by Abdul Mir.

Original n8n.io source

1.1 Workflow description

Title
Company website chatbot agent (RAG, calendar integrations)
Workflow name
Company website chatbot agent (RAG, calendar integrations)

Company Website Chatbot Agent

Overview

This workflow implements a modular Website AI Chatbot Assistant capable of handling multiple types of customer interactions autonomously. Instead of relying on a single large agent to handle all logic and tools, this system routes user queries to specialized sub-agents—each dedicated to a specific function.

By using a manager-style orchestration layer, this approach prevents overloading a single AI model with excessive context, leading to cleaner routing, faster execution, and easier scaling as your automation needs grow.


How It Works

1. Chat Trigger

  • The flow is initiated when a chat message is received via the website widget.

2. Manager Agent (Ultimate Website AI Assistant)

  • The central LLM-based agent is responsible for parsing the message and deciding which specialized sub-agent to route it to.
  • It uses an OpenAI GPT model for natural language understanding and a lightweight memory system to preserve recent context.

3. Sub-Agent Routing

  • calendarAgent: Handles availability checks and books meetings on connected calendars.
  • RAGAgent: Searches company documentation or FAQs to provide accurate responses from your internal knowledge base.
  • ticketAgent: Forwards requests to human support by generating and sending support tickets to a designated email.

Setup Instructions
  1. Embed the Chatbot

    • Use a custom HTML widget or script to embed the chatbot interface on your website.
    • Connect the frontend to the webhook that triggers the When chat message received node.
  2. Configure Your OpenAI Key

    • Insert your API key in the OpenAI Chat Model node.
    • Adjust the model parameters for temperature, max tokens, etc., based on how formal or creative you want the bot to be.
  3. Customize Sub-Agents

    • calendarAgent: Connect to your Google or Outlook calendar.
    • RAGAgent: Link to a vector store or document database via API or native integration.
    • ticketAgent: Set the destination email and format for ticket generation (e.g. via SendGrid or SMTP).
  4. Deploy in Production

    • Host on n8n Cloud or your self-hosted instance.
    • Monitor usage through the Executions tab and refine prompts based on user behavior.

Benefits
  • Modular system with dedicated logic per function
  • Reduces token bloat by offloading complexity to sub-agents
  • Easy to scale by adding more tools (e.g. CRM, analytics)
  • Fast and responsive user experience for customers on your site
  • Cleaner code structure and easier debugging

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - When chat message received

Type / Role
@n8n/n8n-nodes-langchain.chatTrigger - chatTrigger
Config choices
Version 1.1

Block 2 - OpenAI Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

Block 3 - calendarAgent

Type / Role
@n8n/n8n-nodes-langchain.toolWorkflow - toolWorkflow
Config choices
Version 2

Block 4 - RAGagent

Type / Role
@n8n/n8n-nodes-langchain.toolWorkflow - toolWorkflow
Config choices
Version 2

Block 5 - ticketAgent

Type / Role
@n8n/n8n-nodes-langchain.toolWorkflow - toolWorkflow
Config choices
Version 2

Block 6 - Simple Memory

Type / Role
@n8n/n8n-nodes-langchain.memoryBufferWindow - memoryBufferWindow
Config choices
Version 1.3

Block 7 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 8 - Ultimate Website Chatbot Agent

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 1.7

3. Summary Table

Workflow Company website chatbot agent (RAG, calendar integrations)
Complexity intermediate
Nodes 8
Categories Support Chatbot, AI Chatbot
Author Abdul Mir
Published 22 Jul 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/6290/6290.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Company website chatbot agent (RAG, calendar integrations) do?

Company Website Chatbot Agent Overview This workflow implements a modular Website AI Chatbot Assistant capable of handling multiple types of customer interactions autonomously. Instead of relying o...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Support Chatbot, AI Chatbot use case.