esplora_btc_api/models/
spend.rs

1/*
2 * Blockstream Esplora HTTP API
3 *
4 * JSON over RESTful HTTP. Amounts are always represented in satoshis.
5 *
6 * The version of the OpenAPI document: 1.0.1
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11
12
13
14#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
15pub struct Spend {
16    #[serde(rename = "spent")]
17    pub spent: bool,
18    #[serde(rename = "txid", skip_serializing_if = "Option::is_none")]
19    pub txid: Option<String>,
20    #[serde(rename = "vin", skip_serializing_if = "Option::is_none")]
21    pub vin: Option<String>,
22    #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
23    pub status: Option<Box<crate::models::Status>>,
24}
25
26impl Spend {
27    pub fn new(spent: bool) -> Spend {
28        Spend {
29            spent,
30            txid: None,
31            vin: None,
32            status: None,
33        }
34    }
35}
36
37