8000 SEP-1533: Metadata in Resource Read Response by pja-ant · Pull Request #1535 · modelcontextprotocol/modelcontextprotocol · GitHub
[go: up one dir, main page]

Skip to content

Conversation

pja-ant
Copy link
Contributor
@pja-ant pja-ant commented Sep 24, 2025

PR for #1533

pja-ant and others added 2 commits September 24, 2025 13:58
Extends resources/read to optionally return resource metadata fields
(name, title, description, icons, annotations, size) matching what
resources/list provides. Adds metadataOnly parameter to enable
efficient metadata-only reads without fetching content.

This improves API consistency and enables use cases like checking
resource modifications, validating size before loading, and refreshing
UI metadata without fetching large contents.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
Add notes explaining that top-level uri and mimeType fields are
deprecated in favor of metadata.uri and metadata.mimeType, with
requirement that they must match when present.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
- Add required metadata: Resource field to TextResourceContents and BlobResourceContents
- Deprecate top-level uri and mimeType fields (must match metadata values)
- Add metadataOnly parameter to ReadResourceRequest
- Make text/blob optional (required when metadataOnly=false, absent when true)
- Update documentation with deprecation notes and examples
- Fix formatting in security best practices

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
- Remove metadataOnly parameter from resources/read
- Add new resources/metadata endpoint for metadata-only queries
- Make TextResourceContents and BlobResourceContents extend Resource directly
- Eliminate ResourceContents interface to avoid deprecation
- Update documentation with new approach

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
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.

1 participant

0