hanzo-client 8.5.156

Generated client for the Hanzo API — every service, one crate.
Documentation
/*
 * 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 Charge {
    /// AmountCents is what this line costs.
    #[serde(rename = "amountCents", skip_serializing_if = "Option::is_none")]
    pub amount_cents: Option<i32>,
    /// AsOf is when a pass-through amount was last checked against its source.
    #[serde(rename = "asOf", skip_serializing_if = "Option::is_none")]
    pub as_of: Option<String>,
    /// Code names the line so a caller can branch on it without reading prose.
    #[serde(rename = "code", skip_serializing_if = "Option::is_none")]
    pub code: Option<String>,
    /// Label is what the payer sees on the invoice.
    #[serde(rename = "label", skip_serializing_if = "Option::is_none")]
    pub label: Option<String>,
    /// PassThrough marks money we collect and remit rather than keep — the state's fee is not our revenue, and a quote that hides that is a quote that reads as a bigger margin than it is.
    #[serde(rename = "passThrough", skip_serializing_if = "Option::is_none")]
    pub pass_through: Option<bool>,
    /// Recurring marks a line that repeats. An agent of record is billed every year for as long as the entity stands, and a payer agreeing to a one-time total is not agreeing to that.
    #[serde(rename = "recurring", skip_serializing_if = "Option::is_none")]
    pub recurring: Option<String>,
    /// Source names who publishes this amount, for a line we merely pass through. Empty for a price of ours, which needs no external authority.
    #[serde(rename = "source", skip_serializing_if = "Option::is_none")]
    pub source: Option<String>,
    /// Stale reports that AsOf is older than the review window — the figure may have moved and nobody has looked. It does not block; it tells.
    #[serde(rename = "stale", skip_serializing_if = "Option::is_none")]
    pub stale: Option<bool>,
}

impl Charge {
    pub fn new() -> Charge {
        Charge {
            amount_cents: None,
            as_of: None,
            code: None,
            label: None,
            pass_through: None,
            recurring: None,
            source: None,
            stale: None,
        }
    }
}