Skip to content

feat: paginate MCP memories list#20993

Merged
jif-oai merged 1 commit into
mainfrom
jif/list-pagniation
May 4, 2026
Merged

feat: paginate MCP memories list#20993
jif-oai merged 1 commit into
mainfrom
jif/list-pagniation

Conversation

@jif-oai
Copy link
Copy Markdown
Collaborator

@jif-oai jif-oai commented May 4, 2026

Why

Large memories trees do not fit well into a single MCP list response. This change makes the memories MCP server page list results so callers can continue walking the tree without overfetching or relying on ambiguous truncation.

What changed

  • add an optional cursor input to the memories MCP list API and return next_cursor alongside truncated in the response
  • paginate recursive local-memory traversal while preserving lexicographic path order across directories
  • reject malformed and out-of-range cursors as invalid MCP requests
  • update the server/schema wiring and add coverage for pagination, ordering, and cursor validation in memories/mcp/src/local_tests.rs

Testing

  • cargo test -p codex-memories-mcp
@jif-oai jif-oai changed the title feat: mcp memories get pagination feat: paginate MCP memories list May 4, 2026
@jif-oai jif-oai merged commit 5730615 into main May 4, 2026
26 checks passed
@jif-oai jif-oai deleted the jif/list-pagniation branch May 4, 2026 12:59
@github-actions github-actions Bot locked and limited conversation to collaborators May 4, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

1 participant