-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
cmd
committed
Oct 21, 2023
1 parent
6c81f7e
commit 462b650
Showing
5 changed files
with
134 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,59 @@ | ||
export type TxStatus = TxStatusUnconfimed | TxStatusConfirmed | ||
export type TxStatus = TxConfirmed | TxUnconfirmed | ||
|
||
export interface TxStatusUnconfimed { | ||
export interface ScriptKey { | ||
asm : string | ||
desc : string | ||
hex : string | ||
address : string | ||
type : string | ||
} | ||
|
||
export interface TxInput { | ||
txid : string, | ||
vout : number, | ||
scriptSig : { asm : string, hex : string }, | ||
txinwitness : string[], | ||
sequence : number | ||
} | ||
|
||
export interface TxOutput { | ||
n : number | ||
value : number | ||
scriptPubKey : ScriptKey | ||
} | ||
|
||
export interface TxResult { | ||
txid : string | ||
hash : string | ||
version : number | ||
size : number | ||
vsize : number | ||
weight : number | ||
locktime : number | ||
hex : string | ||
vin : TxInput[] | ||
vout : TxOutput[] | ||
blockhash ?: string | ||
confirmations ?: number | ||
time ?: number | ||
blocktime ?: number | ||
} | ||
|
||
export interface TxUnconfirmed { | ||
confirmed : false | ||
} | ||
|
||
export interface TxStatusConfirmed { | ||
export interface TxConfirmed { | ||
confirmed : true | ||
block_hash : string | ||
block_height : number | ||
block_time : number | ||
} | ||
|
||
export interface TxOutpoint { | ||
bestblock : string | ||
confirmations : number | ||
value : number | ||
scriptPubKey : ScriptKey | ||
coinbase : boolean | ||
} |