MCP Tools Reference
All tools exposed by the MemoryLayer MCP server. These are available to any MCP-compatible agent.
Memory operations
Store a new memory. Embeddings are generated locally — content never leaves your machine.
memory_id: string — the ID of the created memory
// Store a preference
memory_store({
content: "User prefers Python with type hints and black formatter",
namespace: "preferences"
})
// → { memory_id: "mem_abc123", status: "stored" }Search memories using hybrid semantic + keyword retrieval with cross-encoder reranking. Returns the most relevant results.
Array of { memory_id, content, score, namespace, metadata, created_at }
// Find coding preferences
memory_search({
query: "what are the user's coding preferences?",
namespace: "preferences",
top_k: 3
})
// → [
// { content: "User prefers Python...", score: 0.94, ... },
// ...
// ]Retrieve a specific memory by ID.
Memory object with content, metadata, and timestamps
memory_get({ memory_id: "mem_abc123" })
// → { memory_id: "mem_abc123", content: "...", namespace: "preferences", ... }Update an existing memory's content or metadata.
Updated memory object
memory_update({
memory_id: "mem_abc123",
content: "User prefers Python with type hints, black, and ruff"
})Permanently delete a memory.
{ status: "deleted" }
memory_delete({ memory_id: "mem_abc123" })Namespace operations
List all namespaces with memory counts.
Array of { namespace, count, last_updated }
memory_list_namespaces()
// → [
// { namespace: "preferences", count: 12, last_updated: "2025-05-01T..." },
// { namespace: "work", count: 47, ... }
// ]List memories in a namespace, sorted by recency.
Array of memory objects
memory_list({ namespace: "work", limit: 10 })Rate limits
Limits are per API key per UTC calendar day. Exceeded calls return a clear error message with an upgrade link.