pub enum ServerResult {
Result(Result),
InitializeResult(InitializeResult),
ListResourcesResult(ListResourcesResult),
ReadResourceResult(ReadResourceResult),
ListPromptsResult(ListPromptsResult),
GetPromptResult(GetPromptResult),
ListToolsResult(ListToolsResult),
CallToolResult(CallToolResult),
CompleteResult(CompleteResult),
}
Expand description
Generated from JSON schema definition for ServerResult
Variants§
Result(Result)
InitializeResult(InitializeResult)
After receiving an initialize request from the client, the server sends this response.
ListResourcesResult(ListResourcesResult)
The server’s response to a resources/list request from the client.
ReadResourceResult(ReadResourceResult)
The server’s response to a resources/read request from the client.
ListPromptsResult(ListPromptsResult)
The server’s response to a prompts/list request from the client.
GetPromptResult(GetPromptResult)
The server’s response to a prompts/get request from the client.
ListToolsResult(ListToolsResult)
The server’s response to a tools/list request from the client.
CallToolResult(CallToolResult)
The server’s response to a tool call.
Any errors that originate from the tool SHOULD be reported inside the result
object, with isError
set to true, not as an MCP protocol-level error
response. Otherwise, the LLM would not be able to see that an error occurred
and self-correct.
However, any errors in finding the tool, an error indicating that the server does not support tool calls, or any other exceptional conditions, should be reported as an MCP error response.
CompleteResult(CompleteResult)
The server’s response to a completion/complete request
Trait Implementations§
Source§impl Clone for ServerResult
impl Clone for ServerResult
Source§fn clone(&self) -> ServerResult
fn clone(&self) -> ServerResult
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more