pub struct ListPromptsResult {
pub result_type: Option<ResultType>,
pub meta: Option<MetaObject>,
pub next_cursor: Option<String>,
pub ttl_ms: Option<u64>,
pub cache_scope: Option<CacheScope>,
pub prompts: Vec<Prompt>,
}Fields§
§result_type: Option<ResultType>Result type discriminator (SEP-2322). Required by the spec schema
for servers implementing protocol version 2026-07-28, but optional
here because this type also models results from older protocol
versions, which do not carry the field: None means absent on the
wire, and per the spec “the client MUST treat the absent field as
"complete"”. Constructors default to Some(ResultType::COMPLETE);
the server handler clears the field when responding to peers that
negotiated an older version.
meta: Option<MetaObject>§next_cursor: Option<String>§ttl_ms: Option<u64>Time, in milliseconds, that this result may be treated as fresh (SEP-2549). Required by spec version 2026-07-28, but optional here to maintain compatibility with older spec versions.
cache_scope: Option<CacheScope>Scope describing who may cache this result (SEP-2549). Required by spec version 2026-07-28, but optional here to maintain compatibility with older spec versions.
prompts: Vec<Prompt>Implementations§
Source§impl ListPromptsResult
impl ListPromptsResult
pub fn with_all_items(items: Vec<Prompt>) -> ListPromptsResult
Sourcepub fn with_ttl_ms(self, ttl_ms: u64) -> ListPromptsResult
pub fn with_ttl_ms(self, ttl_ms: u64) -> ListPromptsResult
Set the time, in milliseconds, that this result may be treated as fresh.
Sourcepub fn with_cache_scope(self, cache_scope: CacheScope) -> ListPromptsResult
pub fn with_cache_scope(self, cache_scope: CacheScope) -> ListPromptsResult
Set the cache scope for this result.
Trait Implementations§
Source§impl Clone for ListPromptsResult
impl Clone for ListPromptsResult
Source§fn clone(&self) -> ListPromptsResult
fn clone(&self) -> ListPromptsResult
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ListPromptsResult
impl Debug for ListPromptsResult
Source§impl Default for ListPromptsResult
impl Default for ListPromptsResult
Source§fn default() -> ListPromptsResult
fn default() -> ListPromptsResult
Source§impl<'de> Deserialize<'de> for ListPromptsResult
impl<'de> Deserialize<'de> for ListPromptsResult
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ListPromptsResult, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ListPromptsResult, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl From<ListPromptsResult> for ServerResult
impl From<ListPromptsResult> for ServerResult
Source§fn from(value: ListPromptsResult) -> ServerResult
fn from(value: ListPromptsResult) -> ServerResult
Source§impl JsonSchema for ListPromptsResult
impl JsonSchema for ListPromptsResult
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreSource§impl PartialEq for ListPromptsResult
impl PartialEq for ListPromptsResult
Source§impl Serialize for ListPromptsResult
impl Serialize for ListPromptsResult
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,
impl StructuralPartialEq for ListPromptsResult
Auto Trait Implementations§
impl Freeze for ListPromptsResult
impl RefUnwindSafe for ListPromptsResult
impl Send for ListPromptsResult
impl Sync for ListPromptsResult
impl Unpin for ListPromptsResult
impl UnsafeUnpin for ListPromptsResult
impl UnwindSafe for ListPromptsResult
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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> ⓘ
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> ⓘ
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 more