Annotation Interface McpTool
- Author:
- Christian Tzolov, Alexandros Pappas, Vadzim Shurmialiou, Craig Walls
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic @interfaceAdditional properties describing a Tool to clients. -
Optional Element Summary
Optional ElementsModifier and TypeOptional ElementDescriptionAdditional hints for clients.The description of the tool.booleanIf true, the tool will generate an output schema for non-primitive output types.Class<? extends MetaProvider> "_meta" field for the tool declaration.The name of the tool.Intended for UI and end-user contexts — optimized to be human-readable and easily understood, even by those unfamiliar with domain-specific terminology.
-
Element Details
-
name
-
description
String descriptionThe description of the tool. If not provided, the method name will be used.- Default:
""
-
annotations
McpTool.McpAnnotations annotationsAdditional hints for clients.- Default:
@org.springframework.ai.mcp.annotation.McpTool.McpAnnotations
-
generateOutputSchema
boolean generateOutputSchemaIf true, the tool will generate an output schema for non-primitive output types. If false, the tool will not automatically generate an output schema.- Default:
false
-
title
String titleIntended for UI and end-user contexts — optimized to be human-readable and easily understood, even by those unfamiliar with domain-specific terminology. If not provided, the name should be used for display (except for Tool, where annotations.title should be given precedence over using name, if present).- Default:
""
-
metaProvider
Class<? extends MetaProvider> metaProvider"_meta" field for the tool declaration. If not provided, no "_meta" appended to the tool specification.- Default:
org.springframework.ai.mcp.annotation.context.DefaultMetaProvider.class
-