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 PullPaymentsCreatePullPaymentRequest {
    /// The name of the pull payment
    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
    pub name: Option<String>,
    /// The description of the pull payment
    #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
    pub description: Option<String>,
    /// The amount in `currency` of this pull payment as a decimal string
    #[serde(rename = "amount", skip_serializing_if = "Option::is_none")]
    pub amount: Option<String>,
    /// The currency of the amount.
    #[serde(rename = "currency", skip_serializing_if = "Option::is_none")]
    pub currency: Option<String>,
    /// The length of each period in seconds.
    #[serde(rename = "period", skip_serializing_if = "Option::is_none")]
    pub period: Option<i32>,
    /// If lightning is activated, do not accept BOLT11 invoices with expiration less than … days
    #[serde(rename = "BOLT11Expiration", skip_serializing_if = "Option::is_none")]
    pub bolt11_expiration: Option<String>,
    /// Any payouts created for this pull payment will skip the approval phase upon creation
    #[serde(rename = "autoApproveClaims", skip_serializing_if = "Option::is_none")]
    pub auto_approve_claims: Option<bool>,
    /// When this pull payment is effective. Already started if null or unspecified.
    #[serde(rename = "startsAt", skip_serializing_if = "Option::is_none")]
    pub starts_at: Option<i32>,
    /// When this pull payment expires. Never expires if null or unspecified.
    #[serde(rename = "expiresAt", skip_serializing_if = "Option::is_none")]
    pub expires_at: Option<i32>,
    /// The list of supported payment methods supported by this pull payment. Available options can be queried from the `StorePaymentMethods_GetStorePaymentMethods` endpoint
    #[serde(rename = "paymentMethods", skip_serializing_if = "Option::is_none")]
    pub payment_methods: Option<Vec<String>>,
}

impl PullPaymentsCreatePullPaymentRequest {
    pub fn new() -> PullPaymentsCreatePullPaymentRequest {
        PullPaymentsCreatePullPaymentRequest {
            name: None,
            description: None,
            amount: None,
            currency: None,
            period: None,
            bolt11_expiration: None,
            auto_approve_claims: None,
            starts_at: None,
            expires_at: None,
            payment_methods: None,
        }
    }
}