Skip to content

SEP-2564: Server-Side Filtering for List Methods#2564

Open
anagh96 wants to merge 1 commit intomodelcontextprotocol:mainfrom
anagh96:sep/server-side-filtering-for-list-methods
Open

SEP-2564: Server-Side Filtering for List Methods#2564
anagh96 wants to merge 1 commit intomodelcontextprotocol:mainfrom
anagh96:sep/server-side-filtering-for-list-methods

Conversation

@anagh96
Copy link
Copy Markdown

@anagh96 anagh96 commented Apr 14, 2026

This SEP introduces optional server-side filtering for MCP */list methods (tools/list, resources/list, prompts/list, resources/templates/list). Clients may include a filter object to receive only capabilities matching specified criteria.

Motivation and Context

As MCP server ecosystems grow, tool catalog sizes become a concrete scaling problem. Enterprise deployments use MCP gateways that aggregate capabilities from multiple upstream servers, and a single tools/list call can return hundreds of tools. Every response serializes full tool definitions (name, description, inputSchema, outputSchema, annotations) into the client's context window.

Without server-side filtering, servers serialize their full capability catalog on every */list call regardless of what the client needs, gateways must fan out to every upstream server, and each implementation independently reinvents tool catalog management. Client-side filtering cannot address these server-side costs.

This SEP proposes a minimal, backward-compatible extension: an optional filter parameter on */list requests with glob-based pattern matching (namePatterns for all methods, uriPatterns for resources). Servers advertise supported filter fields via capability negotiation during initialize. Clients that omit the filter receive the full unfiltered list, preserving backward compatibility.

How Has This Been Tested?

A reference implementation is TBD in both the TypeScript and Python MCP SDKs.

Breaking Changes

None. Fully backward compatible.

Sponsor

@LucaButBoring

AI Disclosure

The design, technical specification, and rationale were authored by me based on real-world experience building MCP gateway services. AI assistance was used to help structure the document to the SEP template format and refine wording for clarity. The sponsor reviewed and provided feedback on the full proposal.

Introduce optional server-side filtering for MCP */list methods.
Clients may include a filter object in tools/list, resources/list,
prompts/list, and resources/templates/list requests to receive only
capabilities matching specified criteria.
@anagh96 anagh96 force-pushed the sep/server-side-filtering-for-list-methods branch from 25d4705 to 6839104 Compare April 14, 2026 00:36
@anagh96 anagh96 changed the title SEP-0000: Server-Side Filtering for List Methods SEP-2564: Server-Side Filtering for List Methods Apr 14, 2026
@LucaButBoring LucaButBoring self-assigned this Apr 14, 2026
@dend dend added proposal SEP proposal without a sponsor. SEP labels Apr 14, 2026
@sep-automation-bot sep-automation-bot bot removed the proposal SEP proposal without a sponsor. label Apr 14, 2026
@sep-automation-bot
Copy link
Copy Markdown

State Transition: proposal → draft

This SEP has been transitioned from proposal to draft.

@LucaButBoring has been assigned as the sponsor for this SEP.


This is an automated message from the SEP lifecycle bot.

@sep-automation-bot sep-automation-bot bot added the draft SEP proposal with a sponsor. label Apr 14, 2026
@sep-automation-bot
Copy link
Copy Markdown

State Transition: proposal → draft

This SEP has been transitioned from proposal to draft.

@LucaButBoring has been assigned as the sponsor for this SEP.


This is an automated message from the SEP lifecycle bot.

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

Labels

draft SEP proposal with a sponsor. SEP

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

3 participants