Annotation Type McpToolProperty
-
@Target(PARAMETER) @Retention(RUNTIME) public @interface McpToolPropertyDefines a strongly-typed input property for an MCP tool function parameter.Alternative to using JSON format in
McpToolTrigger.toolProperties(). Each annotated parameter receives a specific value from the tool invocation arguments.Example:
@FunctionName("searchFiles") public HttpResponseMessage search( @McpToolTrigger(name = "context", description = "Search files") String context, @McpToolProperty( name = "query", propertyName = "searchTerm", propertyType = "string", description = "Search term", required = true ) String searchTerm ) { // Use searchTerm directly }- Since:
- 3.2.0
- See Also:
McpToolTrigger
-
-
Required Element Summary
Required Elements Modifier and Type Required Element Description java.lang.StringnameThe parameter binding name for the Azure Functions runtime.java.lang.StringpropertyTypeThe expected data type (e.g., "string", "number", "boolean", "array", "object").
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description java.lang.StringdescriptionDescription of the property's purpose and usage.booleanisArrayWhether this property is an array.booleanisRequiredWhether this property is required for tool execution.
-