Documentation Index
Fetch the complete documentation index at: https://docs.memanto.ai/llms.txt
Use this file to discover all available pages before exploring further.
Model Context Protocol (MCP)

memanto-mcp package exposes Memanto’s memory primitives — remember, recall, answer, and friends — as Model Context Protocol tools, so any MCP-compatible client can plug into long-term memory in a single config line.
One Moorcheh API key → typed semantic memory shared across every agent that uses the namespace, with sub-90 ms retrieval, conflict detection, and zero ingestion latency.
Universal
Works with every MCP host: Claude Desktop, Cursor, Windsurf, Cline, Continue, Goose, Codex, and custom agents using the MCP SDK.
Zero glue code
No client code, no vector DB. Add one JSON block to your client’s config and the agent gets 7 memory tools.
Typed memory
13 memory types (fact, preference, decision, goal, instruction, …) with confidence + provenance — built for LLM tool-selection.
Shared namespace
Different clients pointed at the same
agent_id share one memory. Remember in Claude Desktop, recall in Cursor.How It Works
Prerequisites
- Python 3.10+
- A Moorcheh API key (free tier: 100K ops/month)
- Any MCP-compatible client
Install
memanto-mcp console script that every client below launches over stdio.
Quickstart
Pick your client. The JSON shape is identical across most hosts — only the config file path changes.- Claude Desktop
- Cursor
- Windsurf
- Cline (VS Code)
- Continue
- Goose
Open the config file
- macOS:
~/Library/Application Support/Claude/claude_desktop_config.json - Windows:
%APPDATA%\Claude\claude_desktop_config.json
The first call auto-creates the
MEMANTO_DEFAULT_AGENT_ID namespace and activates a session. Every subsequent call (in any client pointed at the same agent) reuses the same persistent memory.Available Tools
The server registers 7 memory tools by default. SetMEMANTO_EXPOSE_ADMIN=true to also expose 4 agent-management tools.
Memory tools (always on)
| Tool | When the agent should call it |
|---|---|
remember | Persist a single fact, preference, decision, goal, or instruction. |
batch_remember | Persist up to 100 memories in one call (e.g. extracted from a document). |
recall | Semantic search — always check here before asking the user to repeat stable info. |
recall_recent | ”What did we just decide?” — newest-first, no query needed. |
recall_as_of | Point-in-time recall — “what did we know on 2025-11-01?” |
recall_changed_since | Differential recall — “what’s new since I last checked?” |
answer | RAG: a grounded LLM answer synthesized over the agent’s memories. |
Agent admin tools (opt-in)
Enabled whenMEMANTO_EXPOSE_ADMIN=true:
| Tool | Purpose |
|---|---|
create_agent | Create a new memory namespace. |
list_agents | List every agent the API key can see. |
get_agent | Look up an agent’s metadata. |
delete_agent | Remove an agent’s local metadata. |
Memory types accepted by remember / batch_remember
Memory types accepted by remember / batch_remember
fact, preference, goal, decision, artifact, learning, event, instruction, relationship, context, observation, commitment, error.See the Memory Types Reference for guidance on picking the right type.Provenance values
Provenance values
explicit_statement, inferred, corrected, validated, observed, imported.Use explicit_statement when the user said it directly, inferred when you deduced it, and corrected when overriding an earlier wrong memory.Configuration
All configuration is via environment variables (load order: process env →.env file in the working directory). Most clients let you set these inside the env block of the MCP server entry.
| Variable | Required | Default | Description |
|---|---|---|---|
MOORCHEH_API_KEY | yes | — | Moorcheh API key. |
MEMANTO_DEFAULT_AGENT_ID | recommended | — | Default agent. When set, tool calls may omit agent_id. |
MEMANTO_AGENT_PATTERN | no | tool | Pattern (support / project / tool) used when auto-creating the default agent. |
MEMANTO_AGENT_AUTO_CREATE | no | true | Create the default agent on first use if missing. |
MEMANTO_SESSION_DURATION_HOURS | no | 6 | Session lifetime in hours (1 – 720). |
MEMANTO_EXPOSE_ADMIN | no | false | Register the 4 agent-management tools. |
MEMANTO_MCP_TRANSPORT | no | stdio | stdio, sse, or streamable-http. |
MEMANTO_MCP_HOST | no | 127.0.0.1 | Bind host for sse / http transports. |
MEMANTO_MCP_PORT | no | 8765 | Bind port for sse / http transports. |
MEMANTO_MCP_LOG_LEVEL | no | INFO | Log level. Logs are always sent to stderr. |
Running over HTTP / SSE
For remote clients or multi-process setups, run the server over a network transport:- Streamable HTTP (recommended)
- SSE (legacy)
http://your-host:8765/mcp.Programmatic Embedding
Wiring the server into a larger Python process or custom MCP host:Sharing Memory Across Clients
Point multiple clients at the sameMEMANTO_DEFAULT_AGENT_ID and they share one persistent memory namespace:
Troubleshooting
| Symptom | Fix |
|---|---|
configuration error: MOORCHEH_API_KEY is required | Set the env var in your MCP client config’s env block. |
Agent '…' does not exist and MEMANTO_AGENT_AUTO_CREATE is disabled | Re-enable auto-create, or call create_agent (admin tools) / memanto agent create <id> once. |
| Tools never appear in the client | Confirm the client supports MCP and the config path matches. Check the client’s MCP log: memanto_mcp lines on startup come from this server. |
| Garbled output in stdio mode | Something on your side is writing to stdout — that channel is reserved for JSON-RPC. Move logs to stderr. The server itself only writes to stderr. |
| Slow first call | Cold-start cost: SDK import + first session activation. Subsequent calls reuse the live session. |
| Session-expired errors mid-conversation | The server auto-renews before expiry. If you still see this, bump MEMANTO_SESSION_DURATION_HOURS. |
Next Steps
Memory Types Reference
Learn which memory type to pick for each piece of information.
Agent Management
Create, activate, and switch Memanto agents.
Remember API
The REST endpoint the
remember MCP tool wraps.Recall API
The REST endpoint the
recall MCP tool wraps.Links