Skip to main content

Module priced

Module priced 

Source
Expand description

Priced usage rows: the library-owned usage --json payload.

Joining each model’s tokens with its resolved USD cost used to live in the binary, so a non-CLI consumer (e.g. a future GUI backend) could not produce the same shape. price_usage_data returns a Serialize-able row set with the same matched_model-only-when-present behavior the CLI has always emitted.

Structs§

PricedUsageRow
One priced model row of the usage --json output.

Functions§

price_usage_data
Builds the priced usage --json payload, joining each model’s token counts with its resolved USD cost.