Skip to content

feat: add listMemories tool to the Supermemory MCP server#1044

Open
mvanhorn wants to merge 1 commit into
supermemoryai:mainfrom
mvanhorn:fix/1030-listmemories-mcp-tool
Open

feat: add listMemories tool to the Supermemory MCP server#1044
mvanhorn wants to merge 1 commit into
supermemoryai:mainfrom
mvanhorn:fix/1030-listmemories-mcp-tool

Conversation

@mvanhorn
Copy link
Copy Markdown

@mvanhorn mvanhorn commented Jun 4, 2026

Summary

Agents can now enumerate stored memories through a new listMemories tool on the Supermemory MCP server, returning a page of memory records plus a nextCursor for paging rather than only the top-K of a recall query.

Why this matters

Issue #1030 notes the MCP server in apps/mcp/src/server.ts only exposed memory, recall, and listProjects, so there was no way to list memories to audit, bulk-clean, or diff them before a save/forget. The new SupermemoryClient.listMemories in apps/mcp/src/client.ts accepts containerTag, limit, cursor, sort, and a substring filter, normalizing results the same way search() does, and the fourth registerTool block in server.ts mirrors the recall registration with a Zod schema that clamps limit to 1..200 and validates sort, returning { memories, nextCursor } scoped by the existing containerTag semantics.

Testing

The Zod input schema is exercised at registration: out-of-range limit and invalid sort are rejected with validation messages before reaching the API, and the empty-store path returns an empty list with a null cursor. Verified by building the MCP package; full suite runs in CI.

Fixes #1030

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature] Add 'listMemories' tool to MCP server for enumerating user memories

1 participant