How to Connect Hermes Agent to n8n With Webhooks
n8n has 400+ integrations but every workflow follows a predetermined path. Hermes Agent adds reasoning to those workflows through its webhook adapter, which accepts POST requests from n8n, transforms payloads into agent prompts, and routes intelligent responses back. This guide covers the full setup from enabling the webhook adapter to building production n8n workflows that call Hermes for analysis, triage, and code review.
Why n8n Workflows Need a Reasoning Layer
n8n passed 230,000 active users in early 2026, backed by 400+ core integrations and a visual workflow editor that puts automation within reach of non-developers. The platform handles structured pipelines well: trigger on a Stripe payment, update a CRM record, send a Slack notification. Every path through an n8n workflow, though, is predetermined. When a support ticket needs triage based on context rather than keywords, or a pull request review requires understanding code intent, the if/else branching hits a wall.
Nous Research Hermes Agent fills that gap. It's an open-source, MIT-licensed AI agent framework with persistent memory across sessions, reusable skills that improve over time, and a webhook adapter that accepts HTTP POST requests from any external service. The adapter validates HMAC signatures, transforms incoming payloads into agent prompts using dot-notation templates, and routes Hermes's responses to configurable delivery targets including Slack, Telegram, Discord, and email.
The hermes agent n8n integration pattern is straightforward: n8n handles the plumbing (scheduling, data fetching, SaaS connectors), and Hermes handles the thinking (analysis, contextual judgment). They connect through webhooks, with n8n's HTTP Request node sending payloads to Hermes's webhook endpoint and receiving structured responses. No custom middleware, no shared database, no polling loops.
How the Webhook Bridge Works
The Hermes Agent webhook adapter runs an HTTP server (default port 8644) that exposes endpoints at /webhooks/<route-name>. Each route maps to a specific automation: one route for GitHub PR reviews, another for support ticket analysis, a third for lead scoring. When a POST request arrives, the adapter follows a fixed sequence:
- Validates the HMAC-SHA256 signature against the route's secret
- Parses the JSON payload and checks body size (1 MB default limit)
- Renders a prompt template using dot-notation (e.g.,
{issue.title},{pull_request.body}) - Sends the rendered prompt to the Hermes agent with any configured skills loaded
- Returns the agent's response as the HTTP response body
n8n enters the picture as the orchestrator that decides when to call Hermes and what to do with the response. A typical hermes agent n8n workflow looks like this:
- n8n webhook or schedule trigger fires
- n8n fetches data from an external service (GitHub, Jira, HubSpot, a database)
- n8n sends a formatted POST to
http://your-server:8644/webhooks/your-route - Hermes reasons over the payload using its memory and skills
- n8n receives the response and routes it to the next action (update a ticket, send an email, post to Slack)
The adapter supports platform-specific HMAC validation for GitHub (X-Hub-Signature-256 header), GitLab (X-Gitlab-Token header), and generic sources (X-Webhook-Signature header). For n8n workflows, you'll use the generic method: set a shared secret on the Hermes route, then include the HMAC-SHA256 hex digest in the X-Webhook-Signature header of n8n's HTTP Request node.
Rate limiting defaults to 30 requests per minute per route, and the adapter caches request IDs for one hour to prevent duplicate processing. Both settings are configurable per route.
Set Up the Hermes Webhook Adapter
Before n8n can call Hermes, the webhook adapter needs to be running. If you already have a Hermes installation, enabling webhooks takes a few minutes.
Enable the Adapter
The quickest path is the setup wizard:
hermes gateway setup
Select "webhook" when prompted for the platform. The wizard writes the configuration to ~/.hermes/config.yaml and generates a random HMAC secret.
For manual configuration, add these environment variables to ~/.hermes/.env:
WEBHOOK_ENABLED=true
WEBHOOK_PORT=8644
WEBHOOK_SECRET=your-global-hmac-secret
Verify the adapter is running by hitting the health endpoint:
curl http://localhost:8644/health
You should get back {"status": "ok", "platform": "webhook"}.
Create a Webhook Route
Each automation gets its own route with a dedicated secret, prompt template, and optional skill set. Use the CLI to create one:
hermes webhook subscribe n8n-ticket-triage \
--prompt "Analyze this support ticket and classify its priority. Title: {title}. Description: {body}. Customer tier: {customer.tier}" \
--skills "support-triage" \
--description "n8n sends support tickets for AI triage"
The command prints the full webhook URL and the auto-generated HMAC secret. Save both. You'll need the URL as the endpoint in n8n's HTTP Request node and the secret to compute the signature header.
Routes persist to ~/.hermes/webhook_subscriptions.json and hot-reload without restarting the adapter. You can list all active routes with hermes webhook list and remove them with hermes webhook remove <name>.
Verify the Route
Test it locally before connecting n8n:
hermes webhook test n8n-ticket-triage \
--payload '{"title": "Cannot upload files over 2GB", "body": "Getting timeout errors on large uploads", "customer": {"tier": "enterprise"}}'
The test command bypasses HMAC validation and prints the agent's response directly. If the output looks right, the route is ready for production traffic.
Persist Hermes Agent workflow outputs across sessions
Free 50GB workspace with MCP access. Store triage reports, code reviews, and analysis from your Hermes and n8n pipelines in one place, with versioning, semantic search, and human handoff built in. No credit card required.
Build the n8n Workflow
On the n8n side, you need three components: a trigger, a Code node that computes the HMAC signature, and an HTTP Request node that calls Hermes.
Configure the Trigger
Choose any n8n trigger that fits your use case. A Webhook trigger receives events from external services like GitHub or Zendesk. A Schedule trigger runs on a cron interval for batch processing. An app-specific trigger fires on events from n8n's 400+ integrations, such as a new Jira issue or a new HubSpot contact.
Compute the HMAC Signature
Add a Code node after your trigger to generate the X-Webhook-Signature header. Store your Hermes route secret in n8n's environment variables, then compute the digest:
const crypto = require('crypto');
const body = JSON.stringify($input.first().json);
const secret = $env.HERMES_WEBHOOK_SECRET;
const signature = crypto
.createHmac('sha256', secret)
.update(body)
.digest('hex');
return [{ json: { ...$input.first().json, hmac_signature: signature } }];
Send the Request
Add an HTTP Request node with these settings:
- Method: POST
- URL:
http://your-hermes-server:8644/webhooks/n8n-ticket-triage - Body Content Type: JSON
- Body: Map your trigger's output fields to match the Hermes prompt template
- Headers: Set
X-Webhook-Signatureto thehmac_signaturevalue from the Code node
Handle the Response
Hermes returns its analysis as the HTTP response body. Connect the HTTP Request node's output to whatever action makes sense: a Zendesk node to update ticket priority, a Slack node to post the analysis to a triage channel, an IF node to branch on Hermes's recommendation, or a Google Sheets node to log the classification.
A 200 status means Hermes processed the request successfully. A 502 means the agent or delivery target failed, and n8n can retry. Treat 401 (bad HMAC) and 404 (unknown route) as configuration errors that need manual attention.
Three Workflow Patterns Worth Building
The hermes n8n webhook automation bridge is generic, but some patterns come up repeatedly in production deployments.
PR Review Pipeline
GitHub sends a pull_request.opened event to n8n. n8n enriches the payload with the diff (fetched via GitHub's API node), then POSTs to a Hermes route configured with code review skills. Hermes reads the diff, checks it against the repository's conventions stored in its persistent memory, and returns a review summary. n8n posts the summary as a PR comment via the GitHub node.
This pattern works because Hermes remembers previous reviews. Over time, its feedback gets more consistent as it builds context about the codebase's patterns and conventions. n8n handles the GitHub API plumbing that would be tedious to replicate inside Hermes skills.
Support Ticket Triage
Zendesk, Intercom, or a custom webhook sends new tickets to n8n. n8n looks up the customer's account tier and recent ticket history, bundles everything into a JSON payload, and sends it to Hermes. The agent classifies priority, suggests a response, and flags tickets that need human attention. n8n updates the ticket metadata, assigns it to the right queue, and optionally sends the suggested response as a draft.
The advantage over rule-based triage is handling ambiguity. "My upload is slow" could be a network issue, a file size limit, or a server-side problem. Hermes reasons about context, while n8n handles the mechanical steps of routing and updating records.
Content Monitoring and Summarization n8n scrapes competitor pages, RSS feeds, or social mentions on a daily schedule. Each batch of new content goes to Hermes for analysis: what changed, what matters, and what action the team should take. Hermes maintains a running knowledge base of competitor positioning through its persistent memory, so each analysis builds on previous context rather than starting from scratch. n8n formats the summary and delivers it to Slack, email, or a reporting dashboard.
Store Workflow Outputs With Persistent Workspaces
Both Hermes and n8n produce artifacts that need to live somewhere after the workflow completes: review summaries, triage reports, analysis documents, exported data. Local filesystem storage works for a single-server setup, but breaks down when you need to share outputs with teammates, maintain audit trails, or hand off agent-generated work to humans.
For local setups, Hermes can write files to disk and n8n can read them through its Read Binary File node. S3 or Google Cloud Storage work if you already have cloud infrastructure and want programmatic access without a UI layer. But if you need shared access, versioning, and AI-powered search over your workflow outputs without managing storage infrastructure, Fast.io provides a workspace designed for that job.
Fast.io workspaces give both Hermes and n8n a shared file destination. Hermes writes analysis outputs to a workspace through the Fast.io MCP server, and n8n reads or writes files through Fast.io's REST API using the HTTP Request node. Both see the same files, and human teammates access the same workspace through the web UI.
The free agent plan includes 50GB of storage, 5,000 monthly credits, and 5 workspaces with no credit card required. Intelligence Mode auto-indexes every uploaded file for semantic search, so you can find workflow outputs by meaning rather than filename. When a Hermes analysis references a specific document, the citation points back to the indexed file.
For teams that need audit trails, Fast.io logs every file operation with timestamps and actor identity. When an n8n workflow updates a triage report and Hermes appends new analysis, you can trace exactly who changed what and when. Ownership transfer lets an agent build and populate a workspace, then hand full control to a human reviewer without losing any history. The workspace becomes the handoff point between automated pipelines and human decision-making.
Frequently Asked Questions
Can Hermes Agent connect to n8n?
Yes. Hermes Agent's webhook adapter accepts POST requests from any HTTP client, including n8n's HTTP Request node. You create a webhook route in Hermes with a prompt template and HMAC secret, then point n8n at the route URL. The adapter validates the signature, transforms the payload into an agent prompt, and returns the agent's response as the HTTP body.
How do I trigger Hermes Agent from an n8n workflow?
Add an HTTP Request node to your n8n workflow with the method set to POST and the URL pointing to your Hermes webhook route (for example, http://your-server:8644/webhooks/your-route). Set the body content type to JSON and map your workflow data to the fields expected by the Hermes prompt template. Include the HMAC-SHA256 signature in the X-Webhook-Signature header for authentication.
Is Hermes Agent better than n8n for automation?
They solve different problems and work best together. n8n excels at structured data pipelines, SaaS integrations (400+ connectors), and visual workflow building. Hermes Agent handles tasks that require reasoning, judgment, and persistent memory across sessions. The strongest setup uses n8n for the plumbing and scheduling, with Hermes for analysis and decision-making, connected through webhooks.
Does Hermes Agent support HMAC webhook validation?
Yes. Every webhook route requires an HMAC secret, either set directly on the route or inherited from the global webhook secret. The adapter supports GitHub's X-Hub-Signature-256 header, GitLab's X-Gitlab-Token header, and a generic X-Webhook-Signature header for services like n8n. Requests with invalid or missing signatures receive a 401 Unauthorized response.
Can I run Hermes Agent and n8n on the same server?
Yes. Hermes Agent's webhook adapter defaults to port 8644, and n8n typically runs on port 5678. Both coexist on a single VPS or Docker host without port conflicts. For production, run each in its own Docker container with a reverse proxy handling TLS termination and routing.
What happens if Hermes Agent is slow to respond?
n8n's HTTP Request node has a configurable timeout (default 300 seconds). If Hermes takes longer than the timeout to process a complex prompt, n8n treats it as a failed request. Set n8n's timeout high enough for your use case, and build retry logic in n8n for transient 502 failures. Treat 401 (bad HMAC) and 404 (unknown route) as configuration errors that need fixing, not retrying.
Related Resources
Persist Hermes Agent workflow outputs across sessions
Free 50GB workspace with MCP access. Store triage reports, code reviews, and analysis from your Hermes and n8n pipelines in one place, with versioning, semantic search, and human handoff built in. No credit card required.