@@ -845,6 +845,51 @@ pub struct TestMempoolAcceptResult {
845
845
pub fees : Option < TestMempoolAcceptResultFees > ,
846
846
}
847
847
848
+ #[ derive( Clone , PartialEq , Eq , Debug , Deserialize , Serialize ) ]
849
+ pub struct Fees {
850
+ /// Transaction fee.
851
+ #[ serde( with = "bitcoin::amount::serde::as_btc" ) ]
852
+ pub base : Amount ,
853
+
854
+ /// If the transaction was not already in the mempool, the effective feerate
855
+ /// in BTC per KvB. For example, the package feerate and/or feerate with
856
+ /// modified fees from prioritisetransaction.
857
+ #[ serde( default , rename = "effective-feerate" , with = "bitcoin::amount::serde::as_btc::opt" ) ]
858
+ pub effective_feerate : Option < Amount > ,
859
+
860
+ /// If effective-feerate is provided, the wtxids of the transactions whose
861
+ /// fees and vsizes are included in effective-feerate.
862
+ #[ serde( rename = "effective-includes" ) ]
863
+ pub effective_includes : Option < Vec < bitcoin:: Wtxid > > ,
864
+ }
865
+
866
+ #[ derive( Clone , PartialEq , Eq , Debug , Deserialize , Serialize ) ]
867
+ pub struct TxResult {
868
+ pub txid : bitcoin:: Txid ,
869
+
870
+ /// The wtxid of a different transaction with the same txid but different
871
+ /// witness found in the mempool. This means the submitted transaction was
872
+ /// ignored.
873
+ #[ serde( rename = "other-wtxid" ) ]
874
+ pub other_wtxid : Option < bitcoin:: Wtxid > ,
875
+
876
+ /// Virtual transaction size as defined in BIP 141.
877
+ pub vsize : u64 ,
878
+
879
+ pub fees : Fees ,
880
+ }
881
+
882
+ #[ derive( Clone , PartialEq , Eq , Debug , Deserialize , Serialize ) ]
883
+ pub struct SubmitPackageResult {
884
+ /// Transaction results keyed by wtxid.
885
+ #[ serde( rename = "tx-results" ) ]
886
+ pub tx_results : HashMap < bitcoin:: Wtxid , TxResult > ,
887
+
888
+ /// List of txids of replaced transactions.
889
+ #[ serde( rename = "replaced-transactions" ) ]
890
+ pub replaced_transactions : Vec < bitcoin:: Txid > ,
891
+ }
892
+
848
893
#[ derive( Clone , PartialEq , Eq , Debug , Deserialize , Serialize ) ]
849
894
pub struct TestMempoolAcceptResultFees {
850
895
/// Transaction fee in BTC
0 commit comments