Memori MCP (Model Context Protocol)
MCP (Model Context Protocol) is a standard way for AI agents to connect to external tools and APIs. With Memori's MCP server, your agent can retrieve relevant memories before answering and store durable facts after responding — keeping context across sessions without any SDK integration.
Why Use MCP
Without MCP, your agent only sees the current conversation. With MCP, it can:
- Store stable user facts and preferences after answering using the
advanced_augmentationtool - Recall relevant memories before answering using the
recalltool - Maintain context across sessions using
entity_id,process_id, andsession_id
MCP is ideal for IDE agents (Cursor, Claude Code, Codex, Warp, Antigravity) and other MCP-compatible clients where you want persistent memory without writing integration code.
Server Details
| Property | Value |
|---|---|
| Server | Memori MCP |
| Endpoint | https://api.memorilabs.ai/mcp/ |
| Transport | Stateless HTTP |
| Auth | API key via request headers |
Headers
- Name
X-Memori-API-Key- Type
- string
- Required
- Required
- Description
Your Memori API key from app.memorilabs.ai.
- Name
X-Memori-Entity-Id- Type
- string
- Required
- Required
- Description
Stable end-user or entity identifier (e.g.
user_123).
- Name
X-Memori-Process-Id- Type
- string
- Description
Optional process, app, or workflow identifier (e.g.
my_agent) for memory isolation.
session_id is derived automatically as <entity_id>-<UTC year-month-day:hour>. You do not need to provide it.
Tools
recall
Fetches relevant memories at the start of a user turn.
- Name
query- Type
- string
- Required
- Required
- Description
The latest user message — typically passed verbatim.
entity_id is read from MCP headers. process_id is read when provided. Returns a structured memory payload with relevant context.
advanced_augmentation
Stores durable memory after the agent has drafted a response.
- Name
user_message- Type
- string
- Required
- Required
- Description
The user's message for this turn.
- Name
assistant_response- Type
- string
- Required
- Required
- Description
The assistant's response for this turn.
entity_id is read from MCP headers. process_id is read when provided. Returns a confirmation: memory being created.
Example Agent Flow
Given the user message: "I prefer Python and use uv for dependency management."
- Agent calls
recallwith the user message asquery - Agent composes a response using any returned facts
- Agent sends the response to the user
- Agent calls
advanced_augmentationwith theuser_messageandassistant_response
On a later turn like "Write a hello world script", the agent recalls the Python + uv preference and personalizes its response.
Validation Checklist
After configuring your client, verify the setup:
- MCP server shows as connected and healthy in your client UI
- Tools list includes
recallandadvanced_augmentation - Calls return non-401 responses
recallreturns memories for known entitiesadvanced_augmentationreturnsmemory being created