Skip to content
Sponsor

Webhook to LLM

An endpoint on your machine: anything that can send an HTTP request (a script, a form, another service) posts a message, the model sums it up in three bullet points, and the summary is added to a file.

Download the graph and save it in user/graphs/, or build it below. The graph is MIT-0: copy it and license what you build from it however you like. It has no model picked: pick one on the LLM node, or the LLM writes a mock reply instead of a summary.

A webhook is reachable by anything that can reach the port, so give it a secret. In Settings › AI Providers, open Secrets and add HOOK_SECRET with a long random value. The graph uses it as {{secret.HOOK_SECRET}}, and it will not turn On until the secret exists.

Node Settings
Webhook, named Message path summarize, method POST, secret {{secret.HOOK_SECRET}}
Template, named Prompt Summarize this message in three short bullet points. then a blank line and {message}
LLM model: pick Gemma 4 e4b (Ollama), or the model you pulled
Preview, named Summary none
Time, named Time format 2026-06-08 14:30
Template, named Entry the text below
Append File, named Save path summaries.md

The Entry text, with a blank line at the end so entries stay apart:

## {time}
{summary}
From To
Message trigger Prompt trigger
Message body Prompt message
Prompt trigger LLM trigger
Prompt out LLM prompt
LLM trigger Summary trigger
LLM response Summary in
Summary trigger Entry trigger
Summary out Entry summary
Time out Entry time
Entry trigger Save trigger
Entry out Save content

The trigger runs down the line: the call fires the Prompt, the Prompt fires the LLM, and the Summary shows the reply and passes it on with one trigger, which fires the Entry and then Save. One call runs the model once and adds one entry. Each tag is named after the node its wire comes from: Message body becomes {message}, Summary out becomes {summary}, Time out becomes {time}.

Save the graph as webhook-to-llm (the name is part of the URL), press On, and post a message:

Terminal window
curl -X POST http://127.0.0.1:8770/hook/webhook-to-llm/summarize \
-H "X-Webhook-Secret: <your HOOK_SECRET>" \
-H "Content-Type: text/plain" \
--data "The team meets Thursday at 10. Bring the Q3 numbers. The venue moved to room 4."

The call answers {"ok": true} right away; the webhook does not wait for the model. A moment later the summary shows in the Summary node, and user/data/files/summaries.md has a new entry with the time on top. A wrong or missing secret gets a 401, and a call while the graph is Off gets a 404.

  • JSON in. Send Content-Type: application/json and the parsed body arrives on the Message node’s json output; a Get node picks one field out of it.
  • Post the summary on. Swap the Append File for an HTTP Request to a chat service’s incoming webhook. To send JSON safely, build it with Build JSON, turn it into text with Stringify, and use that as the body, so quotes and new lines in the summary are escaped.
  • Reach it from outside. Only /hook/* should ever face the internet, behind a proxy with TLS. Security explains how.