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 PaymentRecord {
    /// AmountCents is the credited amount in whole cents.
    #[serde(rename = "amountCents", skip_serializing_if = "Option::is_none")]
    pub amount_cents: Option<i32>,
    /// CreatedAt is when the credit was written, RFC3339.
    #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
    pub created_at: Option<String>,
    /// Currency is the ISO 4217 code.
    #[serde(rename = "currency", skip_serializing_if = "Option::is_none")]
    pub currency: Option<String>,
    /// ID is the ledger transaction id.
    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
    pub id: Option<String>,
    /// Notes is the ledger memo, carrying the processor and its reference.
    #[serde(rename = "notes", skip_serializing_if = "Option::is_none")]
    pub notes: Option<String>,
    /// Status is the payment's state. This ledger writes a deposit only AFTER the processor settled, so a payment that can be read is one that succeeded.
    #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
    pub status: Option<String>,
    /// Subject is the billing key this payment credited.
    #[serde(rename = "subject", skip_serializing_if = "Option::is_none")]
    pub subject: Option<String>,
    /// Test reports whether this was a sandbox charge (test balance) or live money.
    #[serde(rename = "test", skip_serializing_if = "Option::is_none")]
    pub test: Option<bool>,
}

impl PaymentRecord {
    pub fn new() -> PaymentRecord {
        PaymentRecord {
            amount_cents: None,
            created_at: None,
            currency: None,
            id: None,
            notes: None,
            status: None,
            subject: None,
            test: None,
        }
    }
}