n8n/packages/@n8n/nodes-langchain/nodes/trigger/ChatTrigger
n8n-assistant[bot] 88264ed350
chore: Bundle 2026-W9 (backport to 1.x) (#27538)
Co-authored-by: n8n-assistant[bot] <100856346+n8n-assistant[bot]@users.noreply.github.com>
Co-authored-by: Matsu <matias.huhta@n8n.io>
Co-authored-by: Dimitri Lavrenük <20122620+dlavrenuek@users.noreply.github.com>
Co-authored-by: Charlie Kolb <charlie@n8n.io>
Co-authored-by: RomanDavydchuk <roman.davydchuk@n8n.io>
Co-authored-by: Jaakko Husso <jaakko@n8n.io>
Co-authored-by: Dawid Myslak <dawid.myslak@gmail.com>
Co-authored-by: Svetoslav Dekov <svetoslav.dekov@n8n.io>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Guillaume Jacquart <jacquart.guillaume@gmail.com>
Co-authored-by: Sandra Zollner <sandra.zollner@n8n.io>
Co-authored-by: Milorad FIlipović <milorad@n8n.io>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
Co-authored-by: Ricardo Espinoza <ricardo@n8n.io>
2026-03-25 14:27:48 +02:00
..
__test__ chore: Bundle 2026-W9 (backport to 1.x) (#27538) 2026-03-25 14:27:48 +02:00
Chat.node.ts chore: Update langchain (#22500) 2025-12-01 16:38:55 +01:00
ChatTrigger.node.ts fix: Enable streaming version of Respond To Webhook node (#22350) 2025-11-26 16:56:43 +01:00
constants.ts fix(ChatTrigger Node): Chat submit button, fix disabled state coloring (#20085) 2025-09-26 16:58:36 +01:00
error.ts refactor(core): Move ApplicationError to @n8n/errors (#17667) 2025-07-28 17:48:56 +02:00
GenericFunctions.ts chore: Backport Bundle (#26218) 2026-02-25 12:25:54 +02:00
README.md fix: Rename chat.css to style.css in chat package build (#16622) (no-changelog) 2025-06-23 12:20:04 +02:00
templates.ts chore: Bundle 2026-W9 (backport to 1.x) (#27538) 2026-03-25 14:27:48 +02:00
types.ts fix(Chat Trigger Node): Prevent XSS vulnerabilities and improve parameter validation (#18148) 2025-08-11 12:37:07 +02:00
util.ts feat: Respond to chat and wait for response (#12546) 2025-07-24 09:48:40 +01:00

ChatTrigger Local Development

This guide explains how to set up local development for the ChatTrigger node when working with the chat bundle.

Prerequisites

Since the chat bundle is loaded via <script type="module">, it needs to be served over HTTPS for local development.

Setup Instructions

1. Install HTTP Server

Install the http-server globally:

npm install -g http-server

2. Generate SSL Certificate

Generate a self-signed certificate for HTTPS:

openssl req -x509 -newkey rsa:4096 -keyout key.pem -out cert.pem -days 365 -nodes

3. Build the Chat Bundle

Navigate to the chat package and build it:

cd packages/frontend/@n8n/chat && pnpm run build 

4. Start HTTPS Server

Run the HTTPS server to serve the chat bundle:

http-server packages/frontend/@n8n/chat/dist -g -S -C cert.pem -K key.pem --port 8443 --cors

5. Update Import Paths

Modify the import paths in templates.ts to point to your local server:

<script type="module">
    import { createChat } from 'https://127.0.0.1:8443/chat.bundle.es.js';
<link href="https://127.0.0.1:8443/style.css" rel="stylesheet" />