Getting stuck trying to log chat sessions onto an Airtable

Hey there,

I’m getting stuck trying to do something, I feel, relatively simple. Spend hours looking into previous post, videos, and documentation but I can’t seem to figure this one out.

My goal is simple, to embed a chat function on my website, and store each chat session onto an Airtable.

Describe the problem/error/question

So I’m not sure my workflow is the correct approach, I’ve based it off some examples I saw online but none had the entire flow exactly how I need it to achieve my goal.

The issue is that somehow the ‘Chat Memory’ node isn’t receiving the Session ID, and the ‘Chat Memory Manager’ isn’t triggered to store anything in the Airtable database. Also, in it’s current form, where the ‘AI Agent’ is directly connected to ‘Chat Memory Manager’, I get a fault message in my embedded chat ‘{ “message”: “Error in workflow” }’

What is the error message (if any)?

Error in sub-node: ‘Simple Memory’
No session ID found

Please share your workflow

Share the output returned by the last node

{
“errorMessage”: “Error in sub-node ‘Simple Memory’”,
“errorDescription”: “No session ID found”,
“errorDetails”: {},
“n8nDetails”: {
“nodeName”: “Simple Memory”,
“nodeType”: “@n8n/n8n-nodes-langchain.memoryBufferWindow”,
“nodeVersion”: 1.3,
“itemIndex”: 0,
“time”: “24/04/2025, 19:03:25”,
“n8nVersion”: “1.86.1 (Cloud)”,
“binaryDataMode”: “filesystem”,
“stackTrace”: [
“NodeOperationError: Error in sub-node Simple Memory”,
" at ExecuteContext.getInputConnectionData (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/node-execution-context/utils/get-input-connection-data.js:99:23)“,
" at ExecuteContext.getInputConnectionData (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/node-execution-context/execute-context.js:45:16)”,
" at ExecuteContext.execute (/usr/local/lib/node_modules/n8n/node_modules/@n8n/n8n-nodes-langchain/dist/nodes/memory/MemoryManager/MemoryManager.node.js:296:20)“,
" at WorkflowExecute.runNode (/usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/workflow-execute.js:681:27)”,
" at /usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/workflow-execute.js:913:51",
" at /usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/execution-engine/workflow-execute.js:1246:20"
]
}
}

Information on your n8n setup

  • n8n version: 1.86.1
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): n8n cloud
  • **Operating system: **

Thank you so much in advance to anyone who can help me out on this, its truly my last resort!

Kind regards,
Mitch

Hi @M1tch

The “Simple Memory” node is not receiving a session ID, which is required to track conversations.

The direct connection between the “AI Agent” and the “Chat Memory Manager” is not passing the required data.

The current flow is not correctly processing conversation data for storage.

See this suggested fix that may help you.

Open a separate workflow and test this suggestion. Start the nodes separately before starting the workflow. Confirm the credentials

I added an “Add Session ID” node that explicitly sets the session ID using the execution ID.
This node is crucial as it ensures that each conversation has a unique identifier.

I want to correctly configure the session ID on the memory nodes, so I added the sessionId option to the “Simple Memory” node that uses either the JSON session ID or the execution ID as a fallback.

I also added the same option to the “Chat Memory Manager”.

The flow now passes through the “Add Session ID” node before going to the “AI Agent”.

This ensures that the session ID is available on all subsequent nodes.

I hope I have helped in some way

Big hug

Hey interss,

Thanks so much for your help – really appreciate the clear reply and the time you took!

I tried adding a node between “When chat message received” and “AI Agent”, but the only option I can use is a Set node. The problem is, it only lets me set a field, not a value, so I can’t actually assign the session ID. I tried setting sessionId as the field, but then I get a different error in the AI Agent this time:

No prompt specified

Expected to find the prompt in an input field called ‘chatInput’ (this is what the chat trigger node outputs). To use something else, change the ‘Prompt’ parameter’

Could you let me know which node you used to add the session ID?

Many thanx!
Mitch

Hello @M1tch!

I bumpt into the same error and I have found this thread in Skool: [resolved] Memory for Ai agent · AI Automation Society

Hope it will be helpful!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.