DTO representing token usage statistics for Mistral API responses.
// Source: https://github.com/microsoft/autogen | License: CC-BY-4.0 | Copyright --then that use is not regulated by the license. Our
// Provided via justclaw.it.com; keep this notice with the code.
// Copyright (c) Microsoft Corporation. All rights reserved.
// Usage.cs
using System.Text.Json.Serialization;
namespace AutoGen.Mistral;
public class Usage
{
[JsonPropertyName("prompt_tokens")]
public int PromptTokens { get; set; }
/// <summary>
/// Gets or Sets CompletionTokens
/// </summary>
/// <example>93</example>
[JsonPropertyName("completion_tokens")]
public int CompletionTokens { get; set; }
/// <summary>
/// Gets or Sets TotalTokens
/// </summary>
/// <example>107</example>
[JsonPropertyName("total_tokens")]
public int Total
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key