| Package | Description |
|---|---|
| io.modelcontextprotocol.server | |
| org.noear.solon.ai.mcp.server.manager |
| Modifier and Type | Method and Description |
|---|---|
McpServer.SyncSpecification |
McpServer.SyncSpecification.capabilities(McpSchema.ServerCapabilities serverCapabilities)
Sets the server capabilities that will be advertised to clients during
connection initialization.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.objectMapper(com.fasterxml.jackson.databind.ObjectMapper objectMapper)
Sets the object mapper to use for serializing and deserializing JSON messages.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.prompts(List<McpServerFeatures.SyncPromptSpecification> prompts)
Registers multiple prompts with their handlers using a List.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.prompts(Map<String,McpServerFeatures.SyncPromptSpecification> prompts)
Registers multiple prompts with their handlers using a Map.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.prompts(McpServerFeatures.SyncPromptSpecification... prompts)
Registers multiple prompts with their handlers using varargs.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.resources(List<McpServerFeatures.SyncResourceSpecification> resourceSpecifications)
Registers multiple resources with their handlers using a List.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.resources(Map<String,McpServerFeatures.SyncResourceSpecification> resourceSpecifications)
Registers multiple resources with their handlers using a Map.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.resources(McpServerFeatures.SyncResourceSpecification... resourceSpecifications)
Registers multiple resources with their handlers using varargs.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.resourceTemplates(List<McpServerFeatures.SyncResourceTemplateSpecification> resourceTemplates)
Sets the resource templates that define patterns for dynamic resource access.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.resourceTemplates(McpServerFeatures.SyncResourceTemplateSpecification... resourceTemplates)
Sets the resource templates using varargs for convenience.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.rootsChangeHandler(BiConsumer<McpSyncServerExchange,List<McpSchema.Root>> handler)
Registers a consumer that will be notified when the list of roots changes.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.rootsChangeHandlers(BiConsumer<McpSyncServerExchange,List<McpSchema.Root>>... handlers)
Registers multiple consumers that will be notified when the list of roots
changes using varargs.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.rootsChangeHandlers(List<BiConsumer<McpSyncServerExchange,List<McpSchema.Root>>> handlers)
Registers multiple consumers that will be notified when the list of roots
changes.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.serverInfo(McpSchema.Implementation serverInfo)
Sets the server implementation information that will be shared with clients
during connection initialization.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.serverInfo(String name,
String version)
Sets the server implementation information using name and version strings.
|
static McpServer.SyncSpecification |
McpServer.sync(McpServerTransportProvider transportProvider)
Starts building a synchronous MCP server that provides blocking operations.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.tool(McpSchema.Tool tool,
BiFunction<McpSyncServerExchange,Map<String,Object>,McpSchema.CallToolResult> handler)
Adds a single tool with its implementation handler to the server.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.tools(List<McpServerFeatures.SyncToolSpecification> toolSpecifications)
Adds multiple tools with their handlers to the server using a List.
|
McpServer.SyncSpecification |
McpServer.SyncSpecification.tools(McpServerFeatures.SyncToolSpecification... toolSpecifications)
Adds multiple tools with their handlers to the server using varargs.
|
| Modifier and Type | Method and Description |
|---|---|
void |
PromptMcpServerManager.add(McpSyncServer server,
McpServer.SyncSpecification mcpServerSpec,
FunctionPrompt functionPrompt) |
void |
ResourceMcpServerManager.add(McpSyncServer server,
McpServer.SyncSpecification mcpServerSpec,
FunctionResource functionResource) |
void |
ToolMcpServerManager.add(McpSyncServer server,
McpServer.SyncSpecification mcpServerSpec,
org.noear.solon.ai.chat.tool.FunctionTool functionTool) |
void |
McpServerManager.add(McpSyncServer server,
McpServer.SyncSpecification mcpServerSpec,
T item)
添加
|
Copyright © 2025. All rights reserved.