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 LightningPaymentData {
    /// The payment's ID
    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
    pub id: Option<String>,
    #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
    pub status: Option<crate::models::LightningPaymentStatus>,
    /// The BOLT11 representation of the payment
    #[serde(rename = "BOLT11", skip_serializing_if = "Option::is_none")]
    pub bolt11: Option<String>,
    /// The payment hash
    #[serde(rename = "paymentHash", skip_serializing_if = "Option::is_none")]
    pub payment_hash: Option<String>,
    /// The payment preimage (available when status is complete)
    #[serde(rename = "preimage", skip_serializing_if = "Option::is_none")]
    pub preimage: Option<String>,
    /// The unix timestamp when the payment got created
    #[serde(rename = "createdAt", skip_serializing_if = "Option::is_none")]
    pub created_at: Option<f32>,
    /// The total amount (including fees) in millisatoshi
    #[serde(rename = "totalAmount", skip_serializing_if = "Option::is_none")]
    pub total_amount: Option<String>,
    /// The total fees in millisatoshi
    #[serde(rename = "feeAmount", skip_serializing_if = "Option::is_none")]
    pub fee_amount: Option<String>,
}

impl LightningPaymentData {
    pub fn new() -> LightningPaymentData {
        LightningPaymentData {
            id: None,
            status: None,
            bolt11: None,
            payment_hash: None,
            preimage: None,
            created_at: None,
            total_amount: None,
            fee_amount: None,
        }
    }
}