Skip to main content

GenericResult

Type Alias GenericResult 

Source
pub type GenericResult = Result;
Expand description

Latest MCP Protocol 2026_07_28 Alias to avoid conflicts with Rust’s standard Result type.

Aliased Type§

pub struct GenericResult {
    pub meta: Option<ResultMetaObject>,
    pub result_type: String,
    pub extra: Option<Map<String, Value>>,
}

Fields§

§meta: Option<ResultMetaObject>§result_type: String

Indicates the type of the result, which allows the client to determine how to parse the result object. Servers implementing this protocol version MUST include this field. For backward compatibility, when a client receives a result from a server implementing an earlier protocol version (which does not include resultType), the client MUST treat the absent field as “complete”.

§extra: Option<Map<String, Value>>

Trait Implementations§

Source§

impl From<CallToolResult> for GenericResult

Source§

fn from(value: CallToolResult) -> Self

Converts to this type from the input type.
Source§

impl From<CompleteResult> for GenericResult

Source§

fn from(value: CompleteResult) -> Self

Converts to this type from the input type.
Source§

impl From<DiscoverResult> for GenericResult

Source§

fn from(value: DiscoverResult) -> Self

Converts to this type from the input type.
Source§

impl From<GetPromptResult> for GenericResult

Source§

fn from(value: GetPromptResult) -> Self

Converts to this type from the input type.
Source§

impl From<InputRequiredResult> for GenericResult

Source§

fn from(value: InputRequiredResult) -> Self

Converts to this type from the input type.
Source§

impl From<ListPromptsResult> for GenericResult

Source§

fn from(value: ListPromptsResult) -> Self

Converts to this type from the input type.
Source§

impl From<ListResourceTemplatesResult> for GenericResult

Source§

fn from(value: ListResourceTemplatesResult) -> Self

Converts to this type from the input type.
Source§

impl From<ListResourcesResult> for GenericResult

Source§

fn from(value: ListResourcesResult) -> Self

Converts to this type from the input type.
Source§

impl From<ListToolsResult> for GenericResult

Source§

fn from(value: ListToolsResult) -> Self

Converts to this type from the input type.
Source§

impl From<ReadResourceResult> for GenericResult

Source§

fn from(value: ReadResourceResult) -> Self

Converts to this type from the input type.
Source§

impl From<SubscriptionsListenResult> for GenericResult

Source§

fn from(value: SubscriptionsListenResult) -> Self

Converts to this type from the input type.
Source§

impl TryFrom<ResultFromClient> for GenericResult

Source§

type Error = RpcError

The type returned in the event of a conversion error.
Source§

fn try_from(value: ResultFromClient) -> Result<Self, Self::Error>

Performs the conversion.
Source§

impl TryFrom<ServerResult> for GenericResult

Source§

type Error = RpcError

The type returned in the event of a conversion error.
Source§

fn try_from(value: ServerResult) -> Result<Self, Self::Error>

Performs the conversion.