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
 */

/// InvoiceMetadata : Additional information around the invoice that can be supplied. The mentioned properties are all optional and you can introduce any json format you wish.



#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct InvoiceMetadata {
    /// You can use this property to store the ID of an external system. We allow you to search in the invoice list based on this ID.
    #[serde(rename = "orderId", skip_serializing_if = "Option::is_none")]
    pub order_id: Option<String>,
    /// You can use this property to store the URL to the order of an external system. This makes navigating to the order easier.
    #[serde(rename = "orderUrl", skip_serializing_if = "Option::is_none")]
    pub order_url: Option<String>,
    #[serde(rename = "posData", skip_serializing_if = "Option::is_none")]
    pub pos_data: Option<String>, // Could not be rendered
    #[serde(rename = "buyerName", skip_serializing_if = "Option::is_none")]
    pub buyer_name: Option<String>,
    #[serde(rename = "buyerEmail", skip_serializing_if = "Option::is_none")]
    pub buyer_email: Option<String>,
    #[serde(rename = "buyerCountry", skip_serializing_if = "Option::is_none")]
    pub buyer_country: Option<String>,
    #[serde(rename = "buyerZip", skip_serializing_if = "Option::is_none")]
    pub buyer_zip: Option<String>,
    #[serde(rename = "buyerState", skip_serializing_if = "Option::is_none")]
    pub buyer_state: Option<String>,
    #[serde(rename = "buyerCity", skip_serializing_if = "Option::is_none")]
    pub buyer_city: Option<String>,
    #[serde(rename = "buyerAddress1", skip_serializing_if = "Option::is_none")]
    pub buyer_address1: Option<String>,
    #[serde(rename = "buyerAddress2", skip_serializing_if = "Option::is_none")]
    pub buyer_address2: Option<String>,
    #[serde(rename = "buyerPhone", skip_serializing_if = "Option::is_none")]
    pub buyer_phone: Option<String>,
    #[serde(rename = "itemDesc", skip_serializing_if = "Option::is_none")]
    pub item_desc: Option<String>,
    #[serde(rename = "itemCode", skip_serializing_if = "Option::is_none")]
    pub item_code: Option<String>,
    #[serde(rename = "physical", skip_serializing_if = "Option::is_none")]
    pub physical: Option<String>,
    #[serde(rename = "taxIncluded", skip_serializing_if = "Option::is_none")]
    pub tax_included: Option<f32>,
}

impl InvoiceMetadata {
    /// Additional information around the invoice that can be supplied. The mentioned properties are all optional and you can introduce any json format you wish.
    pub fn new() -> InvoiceMetadata {
        InvoiceMetadata {
            order_id: None,
            order_url: None,
            pos_data: None,
            buyer_name: None,
            buyer_email: None,
            buyer_country: None,
            buyer_zip: None,
            buyer_state: None,
            buyer_city: None,
            buyer_address1: None,
            buyer_address2: None,
            buyer_phone: None,
            item_desc: None,
            item_code: None,
            physical: None,
            tax_included: None,
        }
    }
}