pub struct AgentSessionRow {Show 13 fields
pub id: String,
pub kind: SessionKind,
pub status: SessionStatus,
pub channel: SessionChannel,
pub model: String,
pub created_at: String,
pub last_active_at: String,
pub turns: u32,
pub prompt_tokens: u64,
pub completion_tokens: u64,
pub reasoning_tokens: u64,
pub cost_cents: f64,
pub goal_text: Option<String>,
}Expand description
A row from the agent_sessions table.
Each field maps directly to a column. Token fields are informational; reasoning_tokens
is a subset of completion_tokens and must not be added separately to cost.
Fields§
§id: StringStable session identifier (UUID).
kind: SessionKindSession type discriminant.
status: SessionStatusCurrent lifecycle state.
channel: SessionChannelChannel over which the session runs.
model: StringLLM model name (e.g. claude-sonnet-4-6).
created_at: StringISO-8601 creation timestamp (UTC).
last_active_at: StringISO-8601 timestamp of the most recent agent turn (UTC).
turns: u32Number of completed agent turns.
prompt_tokens: u64Prompt (input) tokens consumed across all turns.
completion_tokens: u64Completion (output) tokens generated across all turns.
reasoning_tokens: u64Reasoning tokens (subset of completion_tokens; OpenAI only, others are 0).
cost_cents: f64Estimated session cost in US cents.
goal_text: Option<String>Goal description for autonomous sessions; None for interactive sessions.
Trait Implementations§
Source§impl Clone for AgentSessionRow
impl Clone for AgentSessionRow
Source§fn clone(&self) -> AgentSessionRow
fn clone(&self) -> AgentSessionRow
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreAuto Trait Implementations§
impl Freeze for AgentSessionRow
impl RefUnwindSafe for AgentSessionRow
impl Send for AgentSessionRow
impl Sync for AgentSessionRow
impl Unpin for AgentSessionRow
impl UnsafeUnpin for AgentSessionRow
impl UnwindSafe for AgentSessionRow
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,
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 moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request