Package org.springframework.ai.mcp.annotation.common
package org.springframework.ai.mcp.annotation.common
Common utilities for working with MCP annotation metadata.
-
ClassesClassDescriptionConverts
McpIconannotations into schema icons.Helper for therequiredCapabilitiesattribute of@McpTool,@McpPromptand@McpResource, which only the 2026-07-28 ("modern") MCP server enforces.Helpers for theMcpResource.ttlMs()andMcpResource.cacheScope()cache hints, which only the 2026-07-28 ("modern") MCP server can transmit.Utility methods for working withMetaProvidermetadata.Lets a client-side handler method serve MCP connections of both protocols, whichever schema types it is written against: those of the legacy protocol (io.modelcontextprotocol.spec.McpSchema, referred to asMcpSchemain this class) or those of the 2026-07-28 ("modern") revision (io.modelcontextprotocol.modern.McpSchema).Parameter handling shared by the method callbacks of a 2026-07-28 ("modern") MCP server.Return-value handling shared by the asynchronous method callbacks of a 2026-07-28 ("modern") MCP server.