1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
use std::collections::BTreeMap;
use serde::{Deserialize, Serialize};
use serde_with::serde_as;
use themelio_stf::melvm::Covenant;
use themelio_structs::{
Address, BlockHeight, CoinData, CoinDataHeight, CoinID, CoinValue, NetID, StakeDoc,
Transaction, TxHash,
};
use tmelcrypt::HashVal;
#[derive(Clone, Debug, Serialize, Deserialize)]
pub struct WalletSummary {
pub total_micromel: CoinValue,
pub detailed_balance: BTreeMap<String, CoinValue>,
pub staked_microsym: CoinValue,
pub network: NetID,
#[serde(with = "stdcode::asstr")]
pub address: Address,
pub locked: bool,
}
#[derive(Serialize, Deserialize, Clone, Debug)]
pub struct TransactionStatus {
pub raw: Transaction,
pub confirmed_height: Option<u64>,
pub outputs: Vec<AnnCoinID>,
}
#[derive(Serialize, Deserialize, Clone, Debug)]
pub struct AnnCoinID {
pub coin_data: CoinData,
pub is_change: bool,
pub coin_id: String,
}