pub struct GetPromptParams {
pub name: String,
pub arguments: Option<HashMap<String, String>>,
pub meta: Option<HashMap<String, Value>>,
}Expand description
Parameters for prompts/get request (matches MCP GetPromptRequest.params exactly)
Fields§
§name: StringName of the prompt to get
arguments: Option<HashMap<String, String>>Arguments to pass to the prompt (MCP spec: { [key: string]: string })
meta: Option<HashMap<String, Value>>Meta information (optional _meta field inside params)
Implementations§
Source§impl GetPromptParams
impl GetPromptParams
pub fn new(name: impl Into<String>) -> GetPromptParams
pub fn with_arguments( self, arguments: HashMap<String, String>, ) -> GetPromptParams
pub fn with_meta(self, meta: HashMap<String, Value>) -> GetPromptParams
Trait Implementations§
Source§impl Clone for GetPromptParams
impl Clone for GetPromptParams
Source§fn clone(&self) -> GetPromptParams
fn clone(&self) -> GetPromptParams
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for GetPromptParams
impl Debug for GetPromptParams
Source§impl<'de> Deserialize<'de> for GetPromptParams
impl<'de> Deserialize<'de> for GetPromptParams
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<GetPromptParams, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<GetPromptParams, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl HasGetPromptParams for GetPromptParams
impl HasGetPromptParams for GetPromptParams
Source§impl HasMetaParam for GetPromptParams
impl HasMetaParam for GetPromptParams
Source§impl SerdeParamExtractor<GetPromptParams> for GetPromptParams
impl SerdeParamExtractor<GetPromptParams> for GetPromptParams
type Error = McpError
Source§fn extract_serde(
params: RequestParams,
) -> Result<GetPromptParams, <GetPromptParams as SerdeParamExtractor<GetPromptParams>>::Error>
fn extract_serde( params: RequestParams, ) -> Result<GetPromptParams, <GetPromptParams as SerdeParamExtractor<GetPromptParams>>::Error>
Extract parameters using serde deserialization
Source§impl Serialize for GetPromptParams
impl Serialize for GetPromptParams
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Params for GetPromptParams
Auto Trait Implementations§
impl Freeze for GetPromptParams
impl RefUnwindSafe for GetPromptParams
impl Send for GetPromptParams
impl Sync for GetPromptParams
impl Unpin for GetPromptParams
impl UnwindSafe for GetPromptParams
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreCreates a shared type from an unshared type.