Class HttpStreamableMcpServer.HttpStreamableToolSpecificationBuilder

java.lang.Object
org.machanism.machai.mcp.server.HttpStreamableMcpServer.HttpStreamableToolSpecificationBuilder
All Implemented Interfaces:
AbstractMcpServer.ToolSpecificationBuilder<io.modelcontextprotocol.server.McpSyncServerExchange>
Enclosing class:
HttpStreamableMcpServer

public class HttpStreamableMcpServer.HttpStreamableToolSpecificationBuilder extends Object implements AbstractMcpServer.ToolSpecificationBuilder<io.modelcontextprotocol.server.McpSyncServerExchange>
  • Constructor Details

    • HttpStreamableToolSpecificationBuilder

      public HttpStreamableToolSpecificationBuilder()
  • Method Details

    • buildSpecification

      public io.modelcontextprotocol.server.McpServerFeatures.SyncToolSpecification buildSpecification(Object tool, BiFunction<io.modelcontextprotocol.server.McpSyncServerExchange,io.modelcontextprotocol.spec.McpSchema.CallToolRequest,io.modelcontextprotocol.spec.McpSchema.CallToolResult> callHandler)
      Builds a SyncToolSpecification for the Remote MCP server.
      Specified by:
      buildSpecification in interface AbstractMcpServer.ToolSpecificationBuilder<io.modelcontextprotocol.server.McpSyncServerExchange>
      Parameters:
      tool - the tool object (should be a McpSchema.Tool)
      callHandler - the handler function for tool invocation
      Returns:
      a built SyncToolSpecification object