Class McpServerToolCallbackConfiguration

java.lang.Object
io.meeds.mcp.server.configuration.McpServerToolCallbackConfiguration

@Configuration @EnableConfigurationProperties({org.springframework.ai.mcp.server.common.autoconfigure.properties.McpServerProperties.class,org.springframework.ai.mcp.server.common.autoconfigure.properties.McpServerStreamableHttpProperties.class,io.meeds.mcp.server.model.McpServerOAuthClientProperties.class}) public class McpServerToolCallbackConfiguration extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    org.springframework.ai.tool.ToolCallbackProvider
    mcpToolCallbackProvider(org.springframework.context.ApplicationContext applicationContext, io.meeds.mcp.server.service.McpServerToolService mcpServerToolService, io.meeds.mcp.server.service.McpToolApprovalService mcpToolApprovalService, io.meeds.mcp.server.service.McpToolGrantService mcpToolGrantService, io.meeds.mcp.server.service.McpToolSpaceScopeService mcpToolSpaceScopeService, org.exoplatform.portal.config.UserACL userAcl, List<io.meeds.mcp.server.plugin.McpToolPlugin> tools)
    Builds the provider turning every McpToolPlugin method into a tool callback guarded by the scope check, the space scope check, the standing approvals and the approval cards.

    Methods inherited from class Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • McpServerToolCallbackConfiguration

      public McpServerToolCallbackConfiguration()
  • Method Details

    • mcpToolCallbackProvider

      @Bean public org.springframework.ai.tool.ToolCallbackProvider mcpToolCallbackProvider(org.springframework.context.ApplicationContext applicationContext, io.meeds.mcp.server.service.McpServerToolService mcpServerToolService, io.meeds.mcp.server.service.McpToolApprovalService mcpToolApprovalService, io.meeds.mcp.server.service.McpToolGrantService mcpToolGrantService, io.meeds.mcp.server.service.McpToolSpaceScopeService mcpToolSpaceScopeService, org.exoplatform.portal.config.UserACL userAcl, List<io.meeds.mcp.server.plugin.McpToolPlugin> tools)
      Builds the provider turning every McpToolPlugin method into a tool callback guarded by the scope check, the space scope check, the standing approvals and the approval cards.
      Parameters:
      applicationContext - the context, to reach the MCP server bean
      mcpServerToolService - the tool registry
      mcpToolApprovalService - the approval cards
      mcpToolGrantService - the standing approvals
      mcpToolSpaceScopeService - the space scope check
      userAcl - the platform ACL
      tools - the contributed tool plugins
      Returns:
      the provider