1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
/*
* Hanzo Cloud API
*
* The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
*
* The version of the OpenAPI document: v1
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct TotalView {
/// Confidence says how real the row's numbers are.
#[serde(rename = "confidence", skip_serializing_if = "Option::is_none")]
pub confidence: Option<String>,
/// CostCents is the period's spend in cents, in the row's own ledger.
#[serde(rename = "costCents", skip_serializing_if = "Option::is_none")]
pub cost_cents: Option<i32>,
/// Provider is the provider the row totals.
#[serde(rename = "provider", skip_serializing_if = "Option::is_none")]
pub provider: Option<String>,
/// Requests is the period's request count.
#[serde(rename = "requests", skip_serializing_if = "Option::is_none")]
pub requests: Option<i32>,
/// Scope is whose usage the row measures: user or org.
#[serde(rename = "scope", skip_serializing_if = "Option::is_none")]
pub scope: Option<String>,
/// Source is whose meter the row came from: account or hanzo.
#[serde(rename = "source", skip_serializing_if = "Option::is_none")]
pub source: Option<String>,
/// Tokens is the period's total token count.
#[serde(rename = "tokens", skip_serializing_if = "Option::is_none")]
pub tokens: Option<i32>,
/// UsedPct is the plan consumption percentage, on the account side.
#[serde(rename = "usedPct", skip_serializing_if = "Option::is_none")]
pub used_pct: Option<f64>,
/// Window is the window class the row totals, on the account side.
#[serde(rename = "window", skip_serializing_if = "Option::is_none")]
pub window: Option<String>,
/// Windows is how many window instances the row folds.
#[serde(rename = "windows", skip_serializing_if = "Option::is_none")]
pub windows: Option<i32>,
}
impl TotalView {
pub fn new() -> TotalView {
TotalView {
confidence: None,
cost_cents: None,
provider: None,
requests: None,
scope: None,
source: None,
tokens: None,
used_pct: None,
window: None,
windows: None,
}
}
}