CLÉ DÉMO GRATUITE →AccueilProduit
FonctionnalitésCas d'usageComparerEntreprise
Docs
DocumentationDémarrage rapideServeur MCPIntégrationsBenchmark
TarifsBlogLive DemoTABLEAU DE BORD →CONNEXION →
Tutorial n8n No-code March 19, 2026 · 7 min read

Persistent Memory in
n8n AI Workflows

n8n's AI Agent node is powerful — but every workflow run starts with a blank slate. Here's how to connect it to Kronvex so your agents remember users, past interactions, and accumulated knowledge across every run.

✦ Update — Official n8n community node now available: n8n-nodes-kronvex v0.1.1. Install directly from n8n Community Nodes settings. This guide also covers the HTTP Request method.
In this article
  1. Why n8n agents forget
  2. Prerequisites — 5 minutes
  3. Node 1: Store a memory
  4. Node 2: Recall memories
  5. Node 3: Inject context into prompt
  6. Full workflow pattern
  7. Production tips

Why n8n agents forget

n8n's built-in "Window Buffer Memory" node keeps context within a single workflow execution. The moment the run ends — triggered by a webhook, a cron job, or manually — the memory is gone. The next run knows nothing about previous conversations.

For automations that interact with the same user over time (support bots, sales follow-ups, onboarding sequences), this is a fundamental limitation. Kronvex solves it with three HTTP Request nodes that take under 5 minutes to set up.

No code required. Everything in this tutorial uses n8n's built-in HTTP Request node — no custom code nodes, no npm packages. If you can configure an HTTP request, you can add persistent memory to any n8n workflow.

Prerequisites

Store your API key as an n8n credential: Credentials → New → Header Auth, Name: Kronvex, Header Name: X-API-Key, Value: kv-your-key.

Node 1 — Store a memory

After your AI generates a response (or at any point where you want to store context), add an HTTP Request node:

HTTP REQUEST — /remember
FieldValue
MethodPOST
URLhttps://api.kronvex.io/api/v1/agents/YOUR_AGENT_ID/remember
AuthenticationHeader Auth → Kronvex credential
Body (JSON)
{
  "content": "{{ $json.userMessage }}",
  "memory_type": "episodic",
  "session_id": "{{ $json.userId }}"
}

The session_id field scopes memories per user — critical for multi-user workflows. Use any stable user identifier: email, user ID, phone number.

Memory types:

Node 2 — Recall memories

At the start of your workflow (before the AI node), add a recall node to load relevant context:

HTTP REQUEST — /recall
FieldValue
MethodPOST
URLhttps://api.kronvex.io/api/v1/agents/YOUR_AGENT_ID/recall
AuthenticationHeader Auth → Kronvex credential
Body (JSON)
{
  "query": "{{ $json.userMessage }}",
  "top_k": 5,
  "session_id": "{{ $json.userId }}"
}

The response contains a memories array. Each memory has content, memory_type, and a score (0–1 relevance). Access them in later nodes with {{ $json.memories[0].content }}.

Node 3 — Inject context (recommended)

Instead of manually formatting memories, use the /inject-context endpoint which returns a ready-to-use context string formatted for LLM prompts:

HTTP REQUEST — /inject-context
FieldValue
MethodPOST
URLhttps://api.kronvex.io/api/v1/agents/YOUR_AGENT_ID/inject-context
AuthenticationHeader Auth → Kronvex credential
Body (JSON)
{
  "query": "{{ $json.userMessage }}",
  "top_k": 5,
  "session_id": "{{ $json.userId }}"
}

The response has a context string ready to prepend to your system prompt. In your AI Agent node's system message:

AI Agent — System Prompt
You are a helpful assistant.

{{ $('Inject Context').item.json.context }}

Answer the user's question based on the context above.

Full workflow pattern

Here's the recommended node order for a webhook-triggered AI workflow:

1
Webhook — receives userId + userMessage
2
HTTP Request: /inject-context — loads relevant past memories for this user
3
AI Agent node — system prompt includes context from step 2
4
HTTP Request: /remember (×2) — store user message + AI response
5
Respond to Webhook — return AI response to caller
Pro tip — parallel recall: Use n8n's parallel execution to run /inject-context at the same time as other setup nodes. Since recall is under 40ms, it rarely adds latency to your workflow.

Production tips

Related articles
Free access
Get your API key

100 free memories. No credit card required.

Vous avez déjà un compte ? Se connecter →