java-sdk/mcp-test
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Luca Chang fb40047c39 refactor: consolidate content annotations into Annotations (#242)
Updates all Content types to represent annotations as nested objects
instead of directly on the content itself.

- Refactor TextContent, ImageContent, and EmbeddedResource to use Annotations object instead of separate audience/priority fields
- Add backward-compatible deprecated methods for audience() and priority() accessors
- Add parameterized tests for message annotations across different message types (success, error, debug)
- Test both text and image content annotations with proper priority and audience validation

This brings the implementation in line with the content types as modeled by the specification:
c87a0da6d8/schema/2025-03-26/schema.json (L1970-L1973)
2025-06-17 17:37:23 +02:00
..
src/main/java/io/modelcontextprotocol refactor: consolidate content annotations into Annotations (#242) 2025-06-17 17:37:23 +02:00
pom.xml refactor: consolidate content annotations into Annotations (#242) 2025-06-17 17:37:23 +02:00