pub struct GetPromptResult {
pub description: Option<String>,
pub messages: Vec<PromptMessage>,
pub meta: Map<String, Value>,
}
Expand description
The server’s response to a prompts/get request from the client.
JSON schema
{
"description": "The server's response to a prompts/get request from the client.",
"type": "object",
"required": [
"messages"
],
"properties": {
"_meta": {
"description": "This result property is reserved by the protocol to allow clients and servers to attach additional metadata to their responses.",
"type": "object",
"additionalProperties": {}
},
"description": {
"description": "An optional description for the prompt.",
"type": "string"
},
"messages": {
"type": "array",
"items": {
"$ref": "#/definitions/PromptMessage"
}
}
}
}
Fields§
§description: Option<String>
An optional description for the prompt.
messages: Vec<PromptMessage>
§meta: Map<String, Value>
This result property is reserved by the protocol to allow clients and servers to attach additional metadata to their responses.
Trait Implementations§
Source§impl Clone for GetPromptResult
impl Clone for GetPromptResult
Source§fn clone(&self) -> GetPromptResult
fn clone(&self) -> GetPromptResult
Returns a copy 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 GetPromptResult
impl Debug for GetPromptResult
Source§impl Default for GetPromptResult
impl Default for GetPromptResult
Source§fn default() -> GetPromptResult
fn default() -> GetPromptResult
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for GetPromptResult
impl<'de> Deserialize<'de> for GetPromptResult
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<&EmbeddedResource> for GetPromptResult
impl From<&EmbeddedResource> for GetPromptResult
Source§fn from(value: &EmbeddedResource) -> Self
fn from(value: &EmbeddedResource) -> Self
Converts to this type from the input type.
Source§impl From<&GetPromptResult> for GetPromptResult
impl From<&GetPromptResult> for GetPromptResult
Source§fn from(value: &GetPromptResult) -> Self
fn from(value: &GetPromptResult) -> Self
Converts to this type from the input type.
Source§impl From<&GetPromptResult> for ServerResult
impl From<&GetPromptResult> for ServerResult
Source§fn from(value: &GetPromptResult) -> Self
fn from(value: &GetPromptResult) -> Self
Converts to this type from the input type.
Source§impl From<&ImageContent> for GetPromptResult
impl From<&ImageContent> for GetPromptResult
Source§fn from(value: &ImageContent) -> Self
fn from(value: &ImageContent) -> Self
Converts to this type from the input type.
Source§impl From<&PromptMessage> for GetPromptResult
impl From<&PromptMessage> for GetPromptResult
Source§fn from(value: &PromptMessage) -> Self
fn from(value: &PromptMessage) -> Self
Converts to this type from the input type.
Source§impl From<&PromptMessageContent> for GetPromptResult
impl From<&PromptMessageContent> for GetPromptResult
Source§fn from(value: &PromptMessageContent) -> Self
fn from(value: &PromptMessageContent) -> Self
Converts to this type from the input type.
Source§impl From<&TextContent> for GetPromptResult
impl From<&TextContent> for GetPromptResult
Source§fn from(value: &TextContent) -> Self
fn from(value: &TextContent) -> Self
Converts to this type from the input type.
Source§impl From<&str> for GetPromptResult
impl From<&str> for GetPromptResult
Source§impl From<EmbeddedResource> for GetPromptResult
impl From<EmbeddedResource> for GetPromptResult
Source§fn from(value: EmbeddedResource) -> Self
fn from(value: EmbeddedResource) -> Self
Converts to this type from the input type.
Source§impl From<GetPromptResult> for ServerResult
impl From<GetPromptResult> for ServerResult
Source§fn from(value: GetPromptResult) -> Self
fn from(value: GetPromptResult) -> Self
Converts to this type from the input type.
Source§impl From<ImageContent> for GetPromptResult
impl From<ImageContent> for GetPromptResult
Source§fn from(value: ImageContent) -> Self
fn from(value: ImageContent) -> Self
Converts to this type from the input type.
Source§impl From<PromptMessage> for GetPromptResult
impl From<PromptMessage> for GetPromptResult
Source§fn from(message: PromptMessage) -> Self
fn from(message: PromptMessage) -> Self
Converts to this type from the input type.
Source§impl From<PromptMessageContent> for GetPromptResult
impl From<PromptMessageContent> for GetPromptResult
Source§fn from(value: PromptMessageContent) -> Self
fn from(value: PromptMessageContent) -> Self
Converts to this type from the input type.
Source§impl From<String> for GetPromptResult
impl From<String> for GetPromptResult
Source§impl From<TextContent> for GetPromptResult
impl From<TextContent> for GetPromptResult
Source§fn from(value: TextContent) -> Self
fn from(value: TextContent) -> Self
Converts to this type from the input type.
Source§impl<T: Into<PromptMessage>> From<Vec<T>> for GetPromptResult
impl<T: Into<PromptMessage>> From<Vec<T>> for GetPromptResult
Source§impl PartialEq for GetPromptResult
impl PartialEq for GetPromptResult
Source§impl Serialize for GetPromptResult
impl Serialize for GetPromptResult
impl StructuralPartialEq for GetPromptResult
Auto Trait Implementations§
impl Freeze for GetPromptResult
impl RefUnwindSafe for GetPromptResult
impl Send for GetPromptResult
impl Sync for GetPromptResult
impl Unpin for GetPromptResult
impl UnwindSafe for GetPromptResult
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