Add initial support for Resource Templates#18
Merged
stephentoub merged 19 commits intomodelcontextprotocol:mainfrom Mar 21, 2025
Merged
Add initial support for Resource Templates#18stephentoub merged 19 commits intomodelcontextprotocol:mainfrom
stephentoub merged 19 commits intomodelcontextprotocol:mainfrom
Conversation
The server was throwing if this handler wasn't specified, and it should probably be optional anyway.
PederHP
previously requested changes
Mar 21, 2025
Member
PederHP
left a comment
There was a problem hiding this comment.
This looks correct to me, apart from Annotations which are a draft spec feature and not in the protocol version currently supported and advertised during initialization.
stephentoub
reviewed
Mar 21, 2025
stephentoub
reviewed
Mar 21, 2025
stephentoub
reviewed
Mar 21, 2025
Co-authored-by: Stephen Toub <[email protected]>
stephentoub
reviewed
Mar 21, 2025
Co-authored-by: Stephen Toub <[email protected]>
Co-authored-by: Stephen Toub <[email protected]>
If no ListResourceTemplatesHandler is specified, use a default one that returns an empty result.
stephentoub
reviewed
Mar 21, 2025
Contributor
|
Looks good, @Redth, thanks. Presumably we also want the client-side equivalent, e.g. csharp-sdk/src/ModelContextProtocol/Client/McpClientExtensions.cs Lines 142 to 178 in c8c974a ? |
Contributor
Author
Ok, added client extensions and an integration test. |
stephentoub
approved these changes
Mar 21, 2025
Co-authored-by: Stephen Toub <[email protected]>
Co-authored-by: Stephen Toub <[email protected]>
Co-authored-by: Stephen Toub <[email protected]>
Co-authored-by: Stephen Toub <[email protected]>
Co-authored-by: Stephen Toub <[email protected]>
halter73
reviewed
Mar 21, 2025
Co-authored-by: Stephen Halter <[email protected]>
stephentoub
approved these changes
Mar 21, 2025
PederHP
approved these changes
Mar 21, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds some new types and handlers to implement Resource Template functionality according to the spec.
Motivation and Context
Adds more functionality from the spec :)
How Has This Been Tested?
Types of changes
Checklist
Fixes #20