diff --git a/types/src/model/wallet.rs b/types/src/model/wallet.rs index 039305a5..0d23e3f5 100644 --- a/types/src/model/wallet.rs +++ b/types/src/model/wallet.rs @@ -27,10 +27,16 @@ pub enum AddressPurpose { /// The category of a transaction. #[derive(Copy, Clone, PartialEq, Eq, Debug, Deserialize, Serialize)] pub enum TransactionCategory { - /// Transaction is a send. + /// Transactions sent. Send, - /// Transactions is a receive. + /// Non-coinbase transactions received. Receive, + /// Coinbase transactions received with more than 100 confirmations. + Generate, + /// Coinbase transactions received with 100 or fewer confirmations. + Immature, + /// Orphaned coinbase transactions received. + Orphan, } /// Whether this transaction can be RBF'ed. diff --git a/types/src/v17/wallet/into.rs b/types/src/v17/wallet/into.rs index 3130ca88..8f364673 100644 --- a/types/src/v17/wallet/into.rs +++ b/types/src/v17/wallet/into.rs @@ -37,6 +37,9 @@ impl TransactionCategory { match self { V::Send => M::Send, V::Receive => M::Receive, + V::Generate => M::Generate, + V::Immature => M::Immature, + V::Orphan => M::Orphan, } } } diff --git a/types/src/v17/wallet/mod.rs b/types/src/v17/wallet/mod.rs index acabd2d4..b3bb2e64 100644 --- a/types/src/v17/wallet/mod.rs +++ b/types/src/v17/wallet/mod.rs @@ -38,10 +38,16 @@ pub enum AddressPurpose { #[derive(Copy, Clone, PartialEq, Eq, Debug, Deserialize, Serialize)] #[serde(rename_all = "lowercase")] pub enum TransactionCategory { - /// Transaction is a send. + /// Transactions sent. Send, - /// Transactions is a receive. + /// Non-coinbase transactions received. Receive, + /// Coinbase transactions received with more than 100 confirmations. + Generate, + /// Coinbase transactions received with 100 or fewer confirmations. + Immature, + /// Orphaned coinbase transactions received. + Orphan, } /// Whether this transaction can be RBF'ed.