-
Notifications
You must be signed in to change notification settings - Fork 310
Description
While rmcp 0.3.0 allows enabling resources capability via .enable_resources()
in the ServerCapabilities builder, it appears there may not be a trait or infrastructure provided to implement resources handlers. The MCP specification defines resources/list
and resources/read
methods, but it seems rmcp might not currently provide a ResourcesProvider trait similar to how it provides tool handling through the #[tool_router]
macro.
Describe the solution you'd like
It would be great to have first-class support for resources in rmcp, similar to the existing tools support:
- A ResourcesProvider trait with
list_resources()
andread_resource()
methods - Automatic JSON-RPC method routing for
resources/list
andresources/read
- Macros for easy resource implementation (similar to
#[tool_router]
) - Optional Support for resource subscriptions would be a plus
Describe alternatives you've considered
I specifically chose rmcp because it successfully handles the SSE transport layer that I struggled to implement correctly. Going back to manual implementation would mean losing this valuable functionality.
Additional context
Currently building an MCP server for browsing and reading content. It seems that without built-in resources support, implementing the full MCP specification might be more challenging than expected.