pub struct UsageReceipt {Show 13 fields
pub version: u32,
pub id: Uuid,
pub recorded_at: DateTime<Utc>,
pub user_id: String,
pub operation_id: Option<Uuid>,
pub parent_operation_id: Option<Uuid>,
pub operation: String,
pub requested_model: String,
pub actual_model: String,
pub provider_request_id: Option<String>,
pub provider_thread_id: Option<String>,
pub metering: Metering,
pub cost: Option<CostEstimate>,
}Expand description
Durable evidence for one completed provider call.
Fields§
§version: u32§id: Uuid§recorded_at: DateTime<Utc>§user_id: String§operation_id: Option<Uuid>Stable identity assigned by the application to this provider call.
parent_operation_id: Option<Uuid>Causal parent operation, when this call is descendant inference.
operation: String§requested_model: String§actual_model: String§provider_request_id: Option<String>§provider_thread_id: Option<String>§metering: Metering§cost: Option<CostEstimate>Locally calculated standard-tier provider cost, when the model and provider usage can be priced.
Trait Implementations§
Source§impl Clone for UsageReceipt
impl Clone for UsageReceipt
Source§fn clone(&self) -> UsageReceipt
fn clone(&self) -> UsageReceipt
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 UsageReceipt
impl Debug for UsageReceipt
Source§impl<'de> Deserialize<'de> for UsageReceipt
impl<'de> Deserialize<'de> for UsageReceipt
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 PartialEq for UsageReceipt
impl PartialEq for UsageReceipt
Source§impl Serialize for UsageReceipt
impl Serialize for UsageReceipt
impl StructuralPartialEq for UsageReceipt
Auto Trait Implementations§
impl Freeze for UsageReceipt
impl RefUnwindSafe for UsageReceipt
impl Send for UsageReceipt
impl Sync for UsageReceipt
impl Unpin for UsageReceipt
impl UnsafeUnpin for UsageReceipt
impl UnwindSafe for UsageReceipt
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