n8n Integration
Add encrypted persistent memory to your n8n workflows using HTTP Request nodes and the Synapse Layer REST API. No custom code required — just configure and connect.
Overview
n8n is a workflow automation platform that supports HTTP requests natively. By using n8n's HTTP Request node with the Synapse Layer REST API, you can add persistent, encrypted memory to any automation workflow — CRM enrichment, support ticket context, lead scoring with memory, and more.
All data passes through the Cognitive Security Pipeline: PII sanitization, intent classification, and AES-256-GCM encryption at rest.
Store Memory Node
Configure an HTTP Request node to store memories:
https://your-forge-url/api/v1/memory/commitx-connect-token: YOUR_TOKENContent-Type: application/jsonRequest body:
{
"content": "{{ $json.message }}",
"agentId": "n8n-workflow",
"metadata": {
"source": "n8n",
"workflow": "{{ $workflow.name }}"
}
}Note
{{ $json.field }}) to dynamically inject data from previous nodes into the memory content.Recall Memory Node
Configure an HTTP Request node to recall memories:
https://your-forge-url/api/v1/sdk/recallRequest body:
{
"query": "{{ $json.searchQuery }}",
"agentId": "n8n-workflow",
"topK": 5
}Workflow Pattern
A typical n8n workflow with Synapse Layer memory:
The workflow recalls relevant context before processing, then stores new insights for future runs. Over time, the workflow builds up a persistent knowledge base that improves with each execution.
Authentication
Store your Synapse Layer connect token as an n8n credential:
- Go to Credentials in your n8n instance
- Create a new Header Auth credential
- Set the header name to
x-connect-token - Set the value to your connect token
- Reference this credential in all HTTP Request nodes
Warning