btcpay-client 0.1.0

A client library for BTCPay Server.
Documentation
/*
 * BTCPay Greenfield API
 *
 * A full API to use your BTCPay Server
 *
 * The version of the OpenAPI document: v1
 * 
 * Generated by: https://openapi-generator.tech
 */




#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct InvoicePaymentMethodDataModel {
    /// Payment method available for the invoice (e.g., \"BTC\" or \"BTC-LightningNetwork\" or \"BTC-LNURLPAY\")
    #[serde(rename = "paymentMethod", skip_serializing_if = "Option::is_none")]
    pub payment_method: Option<String>,
    /// Crypto code of the payment method (e.g., \"BTC\" or \"LTC\")
    #[serde(rename = "cryptoCode", skip_serializing_if = "Option::is_none")]
    pub crypto_code: Option<String>,
    /// The destination the payment must be made to
    #[serde(rename = "destination", skip_serializing_if = "Option::is_none")]
    pub destination: Option<String>,
    /// A payment link that helps pay to the payment destination
    #[serde(rename = "paymentLink", skip_serializing_if = "Option::is_none")]
    pub payment_link: Option<String>,
    /// The rate between this payment method's currency and the invoice currency
    #[serde(rename = "rate", skip_serializing_if = "Option::is_none")]
    pub rate: Option<String>,
    /// The amount paid by this payment method
    #[serde(rename = "paymentMethodPaid", skip_serializing_if = "Option::is_none")]
    pub payment_method_paid: Option<String>,
    /// The total amount paid by all payment methods to the invoice, converted to this payment method's currency
    #[serde(rename = "totalPaid", skip_serializing_if = "Option::is_none")]
    pub total_paid: Option<String>,
    /// The total amount left to be paid, converted to this payment method's currency (will be negative if overpaid)
    #[serde(rename = "due", skip_serializing_if = "Option::is_none")]
    pub due: Option<String>,
    /// The invoice amount, converted to this payment method's currency
    #[serde(rename = "amount", skip_serializing_if = "Option::is_none")]
    pub amount: Option<String>,
    /// The added merchant fee to pay for network costs of this payment method.
    #[serde(rename = "networkFee", skip_serializing_if = "Option::is_none")]
    pub network_fee: Option<String>,
    /// Payments made with this payment method.
    #[serde(rename = "payments", skip_serializing_if = "Option::is_none")]
    pub payments: Option<Vec<crate::models::Payment>>,
    /// If the payment method is activated (when lazy payments option is enabled
    #[serde(rename = "activated", skip_serializing_if = "Option::is_none")]
    pub activated: Option<bool>,
    #[serde(rename = "additionalData", skip_serializing_if = "Option::is_none")]
    pub additional_data: Option<Box<crate::models::InvoicePaymentMethodDataModelAdditionalData>>,
}

impl InvoicePaymentMethodDataModel {
    pub fn new() -> InvoicePaymentMethodDataModel {
        InvoicePaymentMethodDataModel {
            payment_method: None,
            crypto_code: None,
            destination: None,
            payment_link: None,
            rate: None,
            payment_method_paid: None,
            total_paid: None,
            due: None,
            amount: None,
            network_fee: None,
            payments: None,
            activated: None,
            additional_data: None,
        }
    }
}