pub struct SessionMetadata {
pub key: String,
pub name: Option<String>,
pub created_at: DateTime<Utc>,
pub last_activity: DateTime<Utc>,
pub message_count: usize,
pub agent_alias: Option<String>,
pub channel_id: Option<String>,
pub room_id: Option<String>,
pub sender_id: Option<String>,
}Expand description
Metadata about a persisted session.
Fields§
§key: StringSession key (e.g. telegram_user123).
name: Option<String>Optional human-readable name (e.g. eyrie-commander-briefing).
created_at: DateTime<Utc>When the session was first created.
last_activity: DateTime<Utc>When the last message was appended.
message_count: usizeTotal number of messages in the session.
agent_alias: Option<String>Alias of the agent that owned this session (HashMap key in
config.agents). None for sessions persisted before per-agent
attribution landed, or for backends that don’t track it.
channel_id: Option<String>Dotted ChannelRef the session belongs to (<type>.<alias>,
e.g. discord.clamps). None for non-channel sessions (CLI,
internal cron runs) or backends without routing columns.
room_id: Option<String>Platform-side room / thread identifier (Discord channel id,
Matrix room id, Slack thread ts, …). None for direct messages
or backends that don’t track it.
sender_id: Option<String>Inbound sender id verbatim (Discord username, phone number, …). Not an FK — sessions can survive deletion of the upstream user.
Trait Implementations§
Source§impl Clone for SessionMetadata
impl Clone for SessionMetadata
Source§fn clone(&self) -> SessionMetadata
fn clone(&self) -> SessionMetadata
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for SessionMetadata
impl RefUnwindSafe for SessionMetadata
impl Send for SessionMetadata
impl Sync for SessionMetadata
impl Unpin for SessionMetadata
impl UnsafeUnpin for SessionMetadata
impl UnwindSafe for SessionMetadata
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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