Mindket

Webhook requests sorted into four routes by Claude

Newversion 1 · updated

Overview

An n8n workflow with a webhook: post any request and Claude Haiku 4.5 labels it support, technical, sales or general, with a priority and a one-line summary. The caller gets that label back in the same call.

Webhook requests sorted into four routes by Claude is an n8n workflow in the Developer category, listed by Mindket. It is free. This is version 1, last updated on . Download it on this page or copy its JSON, then import it into an n8n canvas. Nothing runs until you activate it in n8n.

At a glance

Runs in
  • n8n Cloud: import the file into a new workflow there
  • Your own n8n server: the same file and steps
  • A form or an app: let it post its JSON to the webhook’s address
  • Slack, email or a help desk: attach a node to the output you want, one for each route

Platform

Connects 1 app

How it works

Trigger

Webhook request

It starts when something sends a POST request to the path ai-router with:

  • Any JSON body, such as a customer’s message and name

Actions

  1. The request’s body is sent to the Anthropic Messages API, with claude-haiku-4-5
  2. Claude answers with a route (support, technical, sales or general), a priority and a one-sentence summary
  3. A Code node reads that answer, and falls back to general when it cannot
  4. A Switch node sorts the request into the support, technical, sales or fallback output
  5. The caller gets the route, the priority and the summary back as JSON

Result

The caller gets the route, priority and summary at once, and the request waits at its Switch output for nodes of yours

Integrations

What you need before you start.

Anthropic

Language model

Runs claude-haiku-4-5 through the Messages API to label each request with a route, a priority and a one-line summary.

NeedsAnthropic API key, read from the ANTHROPIC_API_KEY server variable

Workflow check

Checked by Mindket on 13 Nov 2026

Steps
5 steps, starting when its webhook is called
AI
No step calls an AI model
Sign-ins
No sign-in
API keys
No API key is left in the file
Step types
Mindket’s checker reads all 5 of its step types

Read from the workflow’s file, not from a run.

About

What it is

This n8n workflow sorts incoming requests with Claude. It listens for a POST at the path ai-router and sends the request’s body to Anthropic’s Messages API. There claude-haiku-4-5 answers with a route (support, technical, sales or general), a priority and a one-sentence summary. A Code node reads that answer, and a Switch node splits the request across four outputs. The caller gets the same three fields back as JSON. Five nodes do the work, and no sticky notes explain them.

Who it suits

Developers and small teams who collect mixed requests through one form or endpoint and want a first label before a person reads each one. Skip it if the Switch’s outputs must do something out of the box. As imported, they are empty, and only the reply shows the route.

Who uses it, and how
IndustryWho uses itHow they use itExample
SoftwareSupport leadsPost each contact form entry and read the route in the replyA lead sees a bug report come back as technical with high priority.
AgenciesAccount managersSort enquiries from a site’s form before they reach the inboxAn agency sees a quote request labeled sales.
EcommerceShop ownersLabel messages from a store’s contact pageA shop sees a late-order question labeled support.
Internal toolsDevelopersPut the routing step behind a company’s own forms and appsAn intranet form gets a route and a summary for each ticket.

You need a little n8n: import a file, give it one Anthropic key and send a test request with curl or any tool that posts JSON.

Where to use it

Any n8n that can reach Anthropic’s API will run it. The Switch node is the place to add whatever should happen next.

  • n8n Cloud: import the file into a new workflow there
  • Your own n8n server: the same file and steps
  • A form or an app: let it post its JSON to the webhook’s address
  • Slack, email or a help desk: attach a node to the output you want, one for each route

Setup

Download saves a zip with workflow.json and Mindket’s setup notes in your downloads folder. One Anthropic key is all it needs.

What you need first
NeedDetail
n8nOn n8n Cloud or on a server of your own
AnthropicAn API key for the Messages API. The call uses claude-haiku-4-5
A sendercurl, a form or any app that can post JSON to a web address
  1. In n8n, create a workflow, open its menu, choose Import from File and pick workflow.json.
  2. Give your n8n server a variable named ANTHROPIC_API_KEY with your key. The x-api-key header in Claude Classifier reads it. Where you cannot set server variables, type your key over that header’s expression.
  3. Open Incoming Webhook and copy its test address. Its path is ai-router.
  4. Save, press Execute workflow and post a JSON body to the test address.
  5. Check the reply, then attach your own nodes to the outputs of Route Switch.
  6. Press Publish and post to the production address.

How to use it

Post any JSON, such as a message and a name, to the webhook’s address. The reply comes back in the same call with route, priority and summary. Inside the run, Route Switch sends the request down the output named after the route, and general or anything unmatched goes to the fourth.

What to change for a different result
To changeWhere
The route namesThe system message in Claude Classifier and the three rules in Route Switch, which must match
The modelmodel in Claude Classifier, claude-haiku-4-5 in the file
The length of the answermax_tokens in Claude Classifier, 100 in the file
The replyThe JSON in Return Route Result
The leftoversThe fourth output of Route Switch, which takes general and anything unmatched

Example

A site’s contact form posts a message saying the export button shows an error since yesterday’s update, with the sender’s name.

Claude answers with a small JSON object: a route such as technical, a priority such as high and one sentence about the failing export. The caller gets received: true with those three fields. The request waits at the technical output of Route Switch with its original payload, ready for a node of yours.

For newcomers and experts

If you are new. n8n draws a workflow as boxes joined by lines, and each box, a node, does one job. This one runs from the webhook to Claude, then reads the answer and sorts it. The reply node hangs on a second line from the webhook, below the first. Send three different messages, then open Parse Classification to see what Claude returned for each.

For experts. The Claude call is a plain HTTP request with the key in a header and the body written as JSON text.

Where to look closer
NodeWhat it doesWhat to know
Claude ClassifierPosts to https://api.anthropic.com/v1/messages with anthropic-version 2023-06-01The request’s text goes in through JSON.stringify, twice
Parse ClassificationTakes the first {...} from Claude’s text and parses itA failed parse becomes route general, priority medium, summary Unable to classify
Route SwitchThree rules on route, ignoring caseThe fourth output takes everything else
Return Route ResultAnswers the webhook with JSONIt reads Parse Classification by name, so it needs to run after that branch

Good to know

The router labels and answers, but nobody receives the request yet. Two expressions also needed repair.

  • Nothing happens next: the four outputs of Route Switch have no node attached, so a request stops there until you add yours
  • Repairs: in the original copy the fallback sat outside options, where n8n ignores it, so a general request had no output. The Claude request pasted the payload’s JSON between quote marks, which breaks the body, and the reply’s summary could break the same way. Mindket’s copy moves the fallback and wraps both in JSON.stringify
  • Order: the reply reads Claude’s answer, so keep Return Route Result below Claude Classifier. n8n’s current execution order runs branches from the top of the canvas down
  • Model: Anthropic’s deprecations page, read on 12 November 2026, lists claude-haiku-4-5-20251001 as active, with no shutdown date announced
  • Billing: Anthropic bills one Messages call a request, with at most 100 tokens in the answer
  • Open webhook: once published, anyone who knows the address can post to it and spend your key. Add authentication in Incoming Webhook before you share it
  • Your data: the whole request body goes to Anthropic
  • Credentials: the JSON holds none and reads your key from a server variable

README and files

README

Webhook requests sorted into four routes by Claude

An n8n workflow with a webhook. You post any request to it, and Claude Haiku 4.5 labels the request support, technical,
sales or general, with a priority and a one-sentence summary. The caller gets that label back in the same call, and a
Switch node splits the request across four outputs for nodes of your own.

What is inside

  • workflow.json: the workflow as n8n exports it, five nodes and no sticky notes. It holds no credential.
  • README.md: these notes.

What we changed from the original copy

  • Route Switch had fallbackOutput set to extra outside its options, where n8n ignores it, so a request labeled
    general had no output. The setting now sits in options, and the node shows a fourth output.
  • Claude Classifier put JSON.stringify($json.body || $json) between quote marks inside its JSON body. The payload's
    own quote marks ended the string early, so any real request broke the body. The text now goes through a second
    JSON.stringify, which adds the outer quotes and escapes the inner ones.
  • Return Route Result put Claude's summary between quote marks the same way. It now uses JSON.stringify, so a
    quote mark in the summary no longer breaks the reply.
  • The webhook's webhookId and the file's template ids are gone. Nothing else changed: the model, the API version and
    the wiring are the file's own. We checked the two body repairs by filling the templates in a script, and have not run
    them in a live n8n.

Before you start

  • An n8n instance, on n8n Cloud or your own server.
  • An Anthropic API key for the Messages API, with access to claude-haiku-4-5.
  • A way to send a POST with a JSON body, such as curl or a form.

Set it up

  1. In n8n, create a workflow, open its menu and choose Import from File. Pick workflow.json.
  2. Give your n8n server an environment variable named ANTHROPIC_API_KEY with your key. The x-api-key header in
    Claude Classifier reads it as $env.ANTHROPIC_API_KEY. Where you cannot set server variables, type your key over
    that expression instead. n8n can also block variable access in expressions: its security settings page lists
    N8N_BLOCK_ENV_ACCESS_IN_NODE, which is false by default.
  3. Open Incoming Webhook and copy its test address. The path is ai-router.
  4. Save, press Execute workflow and post a JSON body to the test address, such as a message and a name.
  5. Read the reply, then attach your own nodes to the outputs of Route Switch.
  6. Press Publish and post to the production address.

How a run goes

  1. Incoming Webhook (Webhook 2) listens for a POST at ai-router and holds the answer until Return Route Result
    replies.
  2. Claude Classifier posts to https://api.anthropic.com/v1/messages with anthropic-version 2023-06-01,
    claude-haiku-4-5 and max_tokens 100. Its system message tells Claude to answer only with a JSON object that
    holds the route, the priority and a summary, and to pick the route from support, sales, technical and general.
  3. Parse Classification reads the first text block, takes the first {...} from it and parses it. When that fails it
    uses route general, priority medium and summary Unable to classify. It keeps the webhook's item as
    originalPayload.
  4. Route Switch (Switch 3) compares route with support, technical and sales, ignoring case. The fourth output
    takes everything else.
  5. Return Route Result (Respond to Webhook) answers with JSON: received, route, priority and summary.

The webhook feeds two lines: Claude Classifier above and Return Route Result below. The file's execution order is
v1, which runs the upper line to its end before the lower one, so the reply can read what Parse Classification
found. Keep the reply node below the classifier on the canvas.

Change the look

  • Routes: the list in the system message of Claude Classifier, and the three rules in Route Switch. Keep them in
    step. A new route needs a new rule and a new output.
  • Model: model in the JSON body of Claude Classifier.
  • Length: max_tokens there. 100 is enough for a route, a priority and one sentence.
  • Reply: the JSON in Return Route Result.
  • What happens next: attach nodes to the outputs of Route Switch, such as a Slack message for support or a CRM row for
    sales. Each one receives the route, the priority, the summary and originalPayload.

Good to know

  • The four outputs of Route Switch have nothing attached. The workflow labels and replies, and the request stops at
    the Switch until you add your own nodes.
  • Anthropic's deprecations page, read on 12 November 2026, lists claude-haiku-4-5-20251001 as active, with no
    shutdown date announced.
  • Each request is one Messages API call, with at most 100 tokens in the answer.
  • Once the workflow is published, anyone who knows the address can post to it and spend your key. Add authentication
    in Incoming Webhook before you share it.
  • The whole request body goes to Anthropic. Keep out anything you do not want a model to read.
  • The file holds no credential and no key. It reads yours from a server variable.
Files
NOTICE.md  594 B
README.md  5 KB
workflow.json  6 KB

3 files, 12 KB, downloaded as a zip.

What’s new

  • Version 1 · 2026-11-12

Reviews

No ratings yet

Write a review

No reviews yet.

More from Mindket

See all from Mindket

anaksor-ocr

Sokheng · Kit

Reads Khmer and English text from documents, receipts and photos of signs, using a detector for text lines and a recogniser for each line. Suits developers who…

New

Qwen2.5-7B-Instruct as GGUF files in eight quantization sizes, to chat with locally through llama.cpp. For people who want a capable 7.6B model on their own co…

New

ACE-Step 1.5 XL SFT

ACE-Step · Kit

Generates music from text with a 4B diffusion decoder, 50 steps and guidance control, aiming for higher audio quality than the base. For creators with a GPU of…

New

Similar in Developer

See all in Developer

Claude Code Skills & Plugins

alirezarezvani · Skill

Adds 411 ready-made skills for Claude Code and other coding agents, grouped by role from engineering and product to marketing, finance and compliance. Installs…

New29.8k

buzz

block · Kit

Self-hostable workspace where people and AI agents share the same rooms, built on a Nostr relay that logs every action as a signed event. For teams that want t…

New37.3k

plannotator

backnotprop · Kit

Opens your AI coding agent's plans, specs and code changes in a browser so you can annotate or comment on them and send the feedback straight back to the agent.

New10.5k