@bitgo/wasm-utxo 1.40.0 → 1.42.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/js/fixedScriptWallet/BitGoPsbt.d.ts +64 -8
- package/dist/cjs/js/fixedScriptWallet/BitGoPsbt.js +67 -9
- package/dist/cjs/js/fixedScriptWallet/index.d.ts +2 -1
- package/dist/cjs/js/index.d.ts +1 -1
- package/dist/cjs/js/psbt.d.ts +12 -0
- package/dist/cjs/js/wasm/wasm_utxo.d.ts +29 -0
- package/dist/cjs/js/wasm/wasm_utxo.js +82 -0
- package/dist/cjs/js/wasm/wasm_utxo_bg.wasm +0 -0
- package/dist/cjs/js/wasm/wasm_utxo_bg.wasm.d.ts +125 -120
- package/dist/esm/js/fixedScriptWallet/BitGoPsbt.d.ts +64 -8
- package/dist/esm/js/fixedScriptWallet/BitGoPsbt.js +68 -10
- package/dist/esm/js/fixedScriptWallet/index.d.ts +2 -1
- package/dist/esm/js/index.d.ts +1 -1
- package/dist/esm/js/index.js +1 -1
- package/dist/esm/js/psbt.d.ts +12 -0
- package/dist/esm/js/wasm/wasm_utxo.d.ts +29 -0
- package/dist/esm/js/wasm/wasm_utxo_bg.js +82 -0
- package/dist/esm/js/wasm/wasm_utxo_bg.wasm +0 -0
- package/dist/esm/js/wasm/wasm_utxo_bg.wasm.d.ts +125 -120
- package/package.json +1 -1
|
@@ -1,91 +1,27 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
export const memory: WebAssembly.Memory;
|
|
4
|
-
export const
|
|
5
|
-
export const
|
|
6
|
-
export const __wbg_wasmecpair_free: (a: number, b: number) => void;
|
|
7
|
-
export const __wbg_wrappsbt_free: (a: number, b: number) => void;
|
|
8
|
-
export const addressnamespace_from_output_script_with_coin: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => void;
|
|
9
|
-
export const addressnamespace_to_output_script_with_coin: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
10
|
-
export const messagenamespace_sign_message: (a: number, b: number, c: number, d: number) => void;
|
|
11
|
-
export const messagenamespace_verify_message: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
12
|
-
export const wasmecpair_from_private_key: (a: number, b: number, c: number) => void;
|
|
13
|
-
export const wasmecpair_from_public_key: (a: number, b: number, c: number) => void;
|
|
14
|
-
export const wasmecpair_from_wif: (a: number, b: number, c: number) => void;
|
|
15
|
-
export const wasmecpair_from_wif_mainnet: (a: number, b: number, c: number) => void;
|
|
16
|
-
export const wasmecpair_from_wif_testnet: (a: number, b: number, c: number) => void;
|
|
17
|
-
export const wasmecpair_private_key: (a: number) => number;
|
|
18
|
-
export const wasmecpair_public_key: (a: number) => number;
|
|
19
|
-
export const wasmecpair_to_wif: (a: number, b: number) => void;
|
|
20
|
-
export const wasmecpair_to_wif_mainnet: (a: number, b: number) => void;
|
|
21
|
-
export const wasmecpair_to_wif_testnet: (a: number, b: number) => void;
|
|
22
|
-
export const wrappsbt_addInput: (a: number, b: number, c: number, d: number, e: number, f: bigint, g: number, h: number, i: number) => void;
|
|
23
|
-
export const wrappsbt_addOutput: (a: number, b: number, c: number, d: bigint) => number;
|
|
24
|
-
export const wrappsbt_clone: (a: number) => number;
|
|
25
|
-
export const wrappsbt_deserialize: (a: number, b: number, c: number) => void;
|
|
26
|
-
export const wrappsbt_extractTransaction: (a: number, b: number) => void;
|
|
27
|
-
export const wrappsbt_finalize: (a: number, b: number) => void;
|
|
28
|
-
export const wrappsbt_getInputs: (a: number, b: number) => void;
|
|
29
|
-
export const wrappsbt_getOutputs: (a: number, b: number) => void;
|
|
30
|
-
export const wrappsbt_getOutputsWithAddress: (a: number, b: number, c: number, d: number) => void;
|
|
31
|
-
export const wrappsbt_getPartialSignatures: (a: number, b: number, c: number) => void;
|
|
32
|
-
export const wrappsbt_getUnsignedTx: (a: number, b: number) => void;
|
|
33
|
-
export const wrappsbt_hasPartialSignatures: (a: number, b: number, c: number) => void;
|
|
34
|
-
export const wrappsbt_inputCount: (a: number) => number;
|
|
35
|
-
export const wrappsbt_lockTime: (a: number) => number;
|
|
36
|
-
export const wrappsbt_new: (a: number, b: number) => number;
|
|
37
|
-
export const wrappsbt_outputCount: (a: number) => number;
|
|
38
|
-
export const wrappsbt_serialize: (a: number, b: number) => void;
|
|
39
|
-
export const wrappsbt_signAll: (a: number, b: number, c: number) => void;
|
|
40
|
-
export const wrappsbt_signAllWithEcpair: (a: number, b: number, c: number) => void;
|
|
41
|
-
export const wrappsbt_signWithPrv: (a: number, b: number, c: number, d: number) => void;
|
|
42
|
-
export const wrappsbt_signWithXprv: (a: number, b: number, c: number, d: number) => void;
|
|
43
|
-
export const wrappsbt_unsignedTxId: (a: number, b: number) => void;
|
|
44
|
-
export const wrappsbt_updateInputWithDescriptor: (a: number, b: number, c: number, d: number) => void;
|
|
45
|
-
export const wrappsbt_updateOutputWithDescriptor: (a: number, b: number, c: number, d: number) => void;
|
|
46
|
-
export const wrappsbt_validateSignatureAtInput: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
47
|
-
export const wrappsbt_verifySignatureWithKey: (a: number, b: number, c: number, d: number) => void;
|
|
48
|
-
export const wrappsbt_version: (a: number) => number;
|
|
49
|
-
export const __wbg_wasmreplayprotection_free: (a: number, b: number) => void;
|
|
50
|
-
export const __wbg_wasmrootwalletkeys_free: (a: number, b: number) => void;
|
|
51
|
-
export const wasmreplayprotection_from_addresses: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
52
|
-
export const wasmreplayprotection_from_output_scripts: (a: number, b: number) => number;
|
|
53
|
-
export const wasmreplayprotection_from_public_keys: (a: number, b: number, c: number) => void;
|
|
54
|
-
export const wasmrootwalletkeys_backup_key: (a: number) => number;
|
|
55
|
-
export const wasmrootwalletkeys_bitgo_key: (a: number) => number;
|
|
56
|
-
export const wasmrootwalletkeys_new: (a: number, b: number, c: number, d: number) => void;
|
|
57
|
-
export const wasmrootwalletkeys_user_key: (a: number) => number;
|
|
58
|
-
export const wasmrootwalletkeys_with_derivation_prefixes: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => void;
|
|
59
|
-
export const __wbg_inscriptionsnamespace_free: (a: number, b: number) => void;
|
|
60
|
-
export const __wbg_wasmbip32_free: (a: number, b: number) => void;
|
|
4
|
+
export const __wbg_utxolibcompatnamespace_free: (a: number, b: number) => void;
|
|
5
|
+
export const __wbg_wasmdimensions_free: (a: number, b: number) => void;
|
|
61
6
|
export const __wbg_wasmtransaction_free: (a: number, b: number) => void;
|
|
62
7
|
export const __wbg_wasmzcashtransaction_free: (a: number, b: number) => void;
|
|
63
|
-
export const
|
|
64
|
-
export const
|
|
65
|
-
export const
|
|
66
|
-
export const
|
|
67
|
-
export const
|
|
68
|
-
export const
|
|
69
|
-
export const
|
|
70
|
-
export const
|
|
71
|
-
export const
|
|
72
|
-
export const
|
|
73
|
-
export const
|
|
74
|
-
export const
|
|
75
|
-
export const
|
|
76
|
-
export const
|
|
77
|
-
export const
|
|
78
|
-
export const
|
|
79
|
-
export const
|
|
80
|
-
export const wasmbip32_identifier: (a: number) => number;
|
|
81
|
-
export const wasmbip32_index: (a: number) => number;
|
|
82
|
-
export const wasmbip32_is_neutered: (a: number) => number;
|
|
83
|
-
export const wasmbip32_neutered: (a: number) => number;
|
|
84
|
-
export const wasmbip32_parent_fingerprint: (a: number) => number;
|
|
85
|
-
export const wasmbip32_private_key: (a: number) => number;
|
|
86
|
-
export const wasmbip32_public_key: (a: number) => number;
|
|
87
|
-
export const wasmbip32_to_base58: (a: number, b: number) => void;
|
|
88
|
-
export const wasmbip32_to_wif: (a: number, b: number) => void;
|
|
8
|
+
export const utxolibcompatnamespace_from_output_script: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
9
|
+
export const utxolibcompatnamespace_to_output_script: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
10
|
+
export const wasmdimensions_empty: () => number;
|
|
11
|
+
export const wasmdimensions_from_input: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => void;
|
|
12
|
+
export const wasmdimensions_from_input_script_type: (a: number, b: number, c: number, d: number) => void;
|
|
13
|
+
export const wasmdimensions_from_output_script_length: (a: number) => number;
|
|
14
|
+
export const wasmdimensions_from_output_script_type: (a: number, b: number, c: number) => void;
|
|
15
|
+
export const wasmdimensions_from_psbt: (a: number, b: number) => void;
|
|
16
|
+
export const wasmdimensions_get_input_vsize: (a: number, b: number, c: number) => number;
|
|
17
|
+
export const wasmdimensions_get_input_weight: (a: number, b: number, c: number) => number;
|
|
18
|
+
export const wasmdimensions_get_output_vsize: (a: number) => number;
|
|
19
|
+
export const wasmdimensions_get_output_weight: (a: number) => number;
|
|
20
|
+
export const wasmdimensions_get_vsize: (a: number, b: number, c: number) => number;
|
|
21
|
+
export const wasmdimensions_get_weight: (a: number, b: number, c: number) => number;
|
|
22
|
+
export const wasmdimensions_has_segwit: (a: number) => number;
|
|
23
|
+
export const wasmdimensions_plus: (a: number, b: number) => number;
|
|
24
|
+
export const wasmdimensions_times: (a: number, b: number) => number;
|
|
89
25
|
export const wasmtransaction_from_bytes: (a: number, b: number, c: number) => void;
|
|
90
26
|
export const wasmtransaction_get_txid: (a: number, b: number) => void;
|
|
91
27
|
export const wasmtransaction_get_vsize: (a: number) => number;
|
|
@@ -93,30 +29,13 @@ export const wasmtransaction_to_bytes: (a: number, b: number) => void;
|
|
|
93
29
|
export const wasmzcashtransaction_from_bytes: (a: number, b: number, c: number) => void;
|
|
94
30
|
export const wasmzcashtransaction_get_txid: (a: number, b: number) => void;
|
|
95
31
|
export const wasmzcashtransaction_to_bytes: (a: number, b: number) => void;
|
|
96
|
-
export const wrapdescriptor_atDerivationIndex: (a: number, b: number, c: number) => void;
|
|
97
|
-
export const wrapdescriptor_descType: (a: number, b: number) => void;
|
|
98
|
-
export const wrapdescriptor_encode: (a: number, b: number) => void;
|
|
99
|
-
export const wrapdescriptor_fromString: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
100
|
-
export const wrapdescriptor_fromStringDetectType: (a: number, b: number, c: number) => void;
|
|
101
|
-
export const wrapdescriptor_hasWildcard: (a: number) => number;
|
|
102
|
-
export const wrapdescriptor_maxWeightToSatisfy: (a: number, b: number) => void;
|
|
103
|
-
export const wrapdescriptor_node: (a: number, b: number) => void;
|
|
104
|
-
export const wrapdescriptor_scriptPubkey: (a: number, b: number) => void;
|
|
105
|
-
export const wrapdescriptor_toAsmString: (a: number, b: number) => void;
|
|
106
|
-
export const wrapdescriptor_toString: (a: number, b: number) => void;
|
|
107
|
-
export const wrapminiscript_encode: (a: number, b: number) => void;
|
|
108
|
-
export const wrapminiscript_fromBitcoinScript: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
109
|
-
export const wrapminiscript_fromString: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
110
|
-
export const wrapminiscript_node: (a: number, b: number) => void;
|
|
111
|
-
export const wrapminiscript_toAsmString: (a: number, b: number) => void;
|
|
112
|
-
export const wrapminiscript_toString: (a: number, b: number) => void;
|
|
113
|
-
export const wasmbip32_from_bip32_properties: (a: number, b: number) => void;
|
|
114
32
|
export const __wbg_bip322namespace_free: (a: number, b: number) => void;
|
|
115
33
|
export const __wbg_bitgopsbt_free: (a: number, b: number) => void;
|
|
116
34
|
export const __wbg_fixedscriptwalletnamespace_free: (a: number, b: number) => void;
|
|
117
|
-
export const
|
|
35
|
+
export const __wbg_inscriptionsnamespace_free: (a: number, b: number) => void;
|
|
36
|
+
export const __wbg_wasmbip32_free: (a: number, b: number) => void;
|
|
118
37
|
export const __wbg_wasmdashtransaction_free: (a: number, b: number) => void;
|
|
119
|
-
export const
|
|
38
|
+
export const __wbg_wasmreplayprotection_free: (a: number, b: number) => void;
|
|
120
39
|
export const bip322namespace_add_bip322_input: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number, k: number, l: number, m: number) => void;
|
|
121
40
|
export const bip322namespace_verify_bip322_psbt_input: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => void;
|
|
122
41
|
export const bip322namespace_verify_bip322_psbt_input_with_pubkeys: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number, k: number, l: number) => void;
|
|
@@ -142,10 +61,15 @@ export const bitgopsbt_extract_zcash_transaction: (a: number, b: number) => void
|
|
|
142
61
|
export const bitgopsbt_finalize_all_inputs: (a: number, b: number) => void;
|
|
143
62
|
export const bitgopsbt_from_bytes: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
144
63
|
export const bitgopsbt_generate_musig2_nonces: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
64
|
+
export const bitgopsbt_get_inputs: (a: number, b: number) => void;
|
|
145
65
|
export const bitgopsbt_get_network_type: (a: number, b: number) => void;
|
|
66
|
+
export const bitgopsbt_get_outputs: (a: number, b: number) => void;
|
|
67
|
+
export const bitgopsbt_get_outputs_with_address: (a: number, b: number) => void;
|
|
68
|
+
export const bitgopsbt_input_count: (a: number) => number;
|
|
146
69
|
export const bitgopsbt_is_musig2_input: (a: number, b: number) => number;
|
|
147
70
|
export const bitgopsbt_lock_time: (a: number) => number;
|
|
148
71
|
export const bitgopsbt_network: (a: number, b: number) => void;
|
|
72
|
+
export const bitgopsbt_output_count: (a: number) => number;
|
|
149
73
|
export const bitgopsbt_parse_outputs_with_wallet_keys: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
150
74
|
export const bitgopsbt_parse_transaction_with_wallet_keys: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
151
75
|
export const bitgopsbt_serialize: (a: number, b: number) => void;
|
|
@@ -170,29 +94,110 @@ export const fixedscriptwalletnamespace_create_op_return_script: (a: number, b:
|
|
|
170
94
|
export const fixedscriptwalletnamespace_output_script: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
171
95
|
export const fixedscriptwalletnamespace_output_script_with_network_str: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
172
96
|
export const fixedscriptwalletnamespace_supports_script_type: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
173
|
-
export const
|
|
174
|
-
export const
|
|
97
|
+
export const inscriptionsnamespace_create_inscription_reveal_data: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => void;
|
|
98
|
+
export const inscriptionsnamespace_sign_reveal_transaction: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: bigint) => void;
|
|
99
|
+
export const wasmbip32_chain_code: (a: number) => number;
|
|
100
|
+
export const wasmbip32_depth: (a: number) => number;
|
|
101
|
+
export const wasmbip32_derive: (a: number, b: number, c: number) => void;
|
|
102
|
+
export const wasmbip32_derive_hardened: (a: number, b: number, c: number) => void;
|
|
103
|
+
export const wasmbip32_derive_path: (a: number, b: number, c: number, d: number) => void;
|
|
104
|
+
export const wasmbip32_equals: (a: number, b: number) => number;
|
|
105
|
+
export const wasmbip32_fingerprint: (a: number) => number;
|
|
106
|
+
export const wasmbip32_from_base58: (a: number, b: number, c: number) => void;
|
|
107
|
+
export const wasmbip32_from_bip32_interface: (a: number, b: number) => void;
|
|
108
|
+
export const wasmbip32_from_seed: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
109
|
+
export const wasmbip32_from_seed_sha256: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
110
|
+
export const wasmbip32_from_xprv: (a: number, b: number, c: number) => void;
|
|
111
|
+
export const wasmbip32_from_xpub: (a: number, b: number, c: number) => void;
|
|
112
|
+
export const wasmbip32_identifier: (a: number) => number;
|
|
113
|
+
export const wasmbip32_index: (a: number) => number;
|
|
114
|
+
export const wasmbip32_is_neutered: (a: number) => number;
|
|
115
|
+
export const wasmbip32_neutered: (a: number) => number;
|
|
116
|
+
export const wasmbip32_parent_fingerprint: (a: number) => number;
|
|
117
|
+
export const wasmbip32_private_key: (a: number) => number;
|
|
118
|
+
export const wasmbip32_public_key: (a: number) => number;
|
|
119
|
+
export const wasmbip32_to_base58: (a: number, b: number) => void;
|
|
120
|
+
export const wasmbip32_to_wif: (a: number, b: number) => void;
|
|
175
121
|
export const wasmdashtransaction_from_bytes: (a: number, b: number, c: number) => void;
|
|
176
122
|
export const wasmdashtransaction_get_txid: (a: number, b: number) => void;
|
|
177
123
|
export const wasmdashtransaction_to_bytes: (a: number, b: number) => void;
|
|
178
|
-
export const
|
|
179
|
-
export const
|
|
180
|
-
export const
|
|
181
|
-
export const
|
|
182
|
-
export const wasmdimensions_from_output_script_type: (a: number, b: number, c: number) => void;
|
|
183
|
-
export const wasmdimensions_from_psbt: (a: number, b: number) => void;
|
|
184
|
-
export const wasmdimensions_get_input_vsize: (a: number, b: number, c: number) => number;
|
|
185
|
-
export const wasmdimensions_get_input_weight: (a: number, b: number, c: number) => number;
|
|
186
|
-
export const wasmdimensions_get_output_vsize: (a: number) => number;
|
|
187
|
-
export const wasmdimensions_get_output_weight: (a: number) => number;
|
|
188
|
-
export const wasmdimensions_get_vsize: (a: number, b: number, c: number) => number;
|
|
189
|
-
export const wasmdimensions_get_weight: (a: number, b: number, c: number) => number;
|
|
190
|
-
export const wasmdimensions_has_segwit: (a: number) => number;
|
|
191
|
-
export const wasmdimensions_plus: (a: number, b: number) => number;
|
|
192
|
-
export const wasmdimensions_times: (a: number, b: number) => number;
|
|
124
|
+
export const wasmreplayprotection_from_addresses: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
125
|
+
export const wasmreplayprotection_from_output_scripts: (a: number, b: number) => number;
|
|
126
|
+
export const wasmreplayprotection_from_public_keys: (a: number, b: number, c: number) => void;
|
|
127
|
+
export const wasmbip32_from_bip32_properties: (a: number, b: number) => void;
|
|
193
128
|
export const bitgopsbt_sign_wallet_input: (a: number, b: number, c: number, d: number) => void;
|
|
194
129
|
export const bitgopsbt_sign_all_with_xpriv: (a: number, b: number, c: number) => void;
|
|
195
130
|
export const bitgopsbt_sign_replay_protection_inputs: (a: number, b: number, c: number) => void;
|
|
131
|
+
export const __wbg_messagenamespace_free: (a: number, b: number) => void;
|
|
132
|
+
export const __wbg_wasmrootwalletkeys_free: (a: number, b: number) => void;
|
|
133
|
+
export const messagenamespace_sign_message: (a: number, b: number, c: number, d: number) => void;
|
|
134
|
+
export const messagenamespace_verify_message: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
|
|
135
|
+
export const wasmrootwalletkeys_backup_key: (a: number) => number;
|
|
136
|
+
export const wasmrootwalletkeys_bitgo_key: (a: number) => number;
|
|
137
|
+
export const wasmrootwalletkeys_new: (a: number, b: number, c: number, d: number) => void;
|
|
138
|
+
export const wasmrootwalletkeys_user_key: (a: number) => number;
|
|
139
|
+
export const wasmrootwalletkeys_with_derivation_prefixes: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => void;
|
|
140
|
+
export const __wbg_addressnamespace_free: (a: number, b: number) => void;
|
|
141
|
+
export const __wbg_wasmecpair_free: (a: number, b: number) => void;
|
|
142
|
+
export const __wbg_wrappsbt_free: (a: number, b: number) => void;
|
|
143
|
+
export const addressnamespace_from_output_script_with_coin: (a: number, b: number, c: number, d: number, e: number, f: number, g: number) => void;
|
|
144
|
+
export const addressnamespace_to_output_script_with_coin: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
145
|
+
export const wasmecpair_from_private_key: (a: number, b: number, c: number) => void;
|
|
146
|
+
export const wasmecpair_from_public_key: (a: number, b: number, c: number) => void;
|
|
147
|
+
export const wasmecpair_from_wif: (a: number, b: number, c: number) => void;
|
|
148
|
+
export const wasmecpair_from_wif_mainnet: (a: number, b: number, c: number) => void;
|
|
149
|
+
export const wasmecpair_from_wif_testnet: (a: number, b: number, c: number) => void;
|
|
150
|
+
export const wasmecpair_private_key: (a: number) => number;
|
|
151
|
+
export const wasmecpair_public_key: (a: number) => number;
|
|
152
|
+
export const wasmecpair_to_wif: (a: number, b: number) => void;
|
|
153
|
+
export const wasmecpair_to_wif_mainnet: (a: number, b: number) => void;
|
|
154
|
+
export const wasmecpair_to_wif_testnet: (a: number, b: number) => void;
|
|
155
|
+
export const wrappsbt_addInput: (a: number, b: number, c: number, d: number, e: number, f: bigint, g: number, h: number, i: number) => void;
|
|
156
|
+
export const wrappsbt_addOutput: (a: number, b: number, c: number, d: bigint) => number;
|
|
157
|
+
export const wrappsbt_clone: (a: number) => number;
|
|
158
|
+
export const wrappsbt_deserialize: (a: number, b: number, c: number) => void;
|
|
159
|
+
export const wrappsbt_extractTransaction: (a: number, b: number) => void;
|
|
160
|
+
export const wrappsbt_finalize: (a: number, b: number) => void;
|
|
161
|
+
export const wrappsbt_getInputs: (a: number, b: number) => void;
|
|
162
|
+
export const wrappsbt_getOutputs: (a: number, b: number) => void;
|
|
163
|
+
export const wrappsbt_getOutputsWithAddress: (a: number, b: number, c: number, d: number) => void;
|
|
164
|
+
export const wrappsbt_getPartialSignatures: (a: number, b: number, c: number) => void;
|
|
165
|
+
export const wrappsbt_getUnsignedTx: (a: number, b: number) => void;
|
|
166
|
+
export const wrappsbt_hasPartialSignatures: (a: number, b: number, c: number) => void;
|
|
167
|
+
export const wrappsbt_inputCount: (a: number) => number;
|
|
168
|
+
export const wrappsbt_lockTime: (a: number) => number;
|
|
169
|
+
export const wrappsbt_new: (a: number, b: number) => number;
|
|
170
|
+
export const wrappsbt_outputCount: (a: number) => number;
|
|
171
|
+
export const wrappsbt_serialize: (a: number, b: number) => void;
|
|
172
|
+
export const wrappsbt_signAll: (a: number, b: number, c: number) => void;
|
|
173
|
+
export const wrappsbt_signAllWithEcpair: (a: number, b: number, c: number) => void;
|
|
174
|
+
export const wrappsbt_signWithPrv: (a: number, b: number, c: number, d: number) => void;
|
|
175
|
+
export const wrappsbt_signWithXprv: (a: number, b: number, c: number, d: number) => void;
|
|
176
|
+
export const wrappsbt_unsignedTxId: (a: number, b: number) => void;
|
|
177
|
+
export const wrappsbt_updateInputWithDescriptor: (a: number, b: number, c: number, d: number) => void;
|
|
178
|
+
export const wrappsbt_updateOutputWithDescriptor: (a: number, b: number, c: number, d: number) => void;
|
|
179
|
+
export const wrappsbt_validateSignatureAtInput: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
180
|
+
export const wrappsbt_verifySignatureWithKey: (a: number, b: number, c: number, d: number) => void;
|
|
181
|
+
export const wrappsbt_version: (a: number) => number;
|
|
182
|
+
export const __wbg_wrapdescriptor_free: (a: number, b: number) => void;
|
|
183
|
+
export const __wbg_wrapminiscript_free: (a: number, b: number) => void;
|
|
184
|
+
export const wrapdescriptor_atDerivationIndex: (a: number, b: number, c: number) => void;
|
|
185
|
+
export const wrapdescriptor_descType: (a: number, b: number) => void;
|
|
186
|
+
export const wrapdescriptor_encode: (a: number, b: number) => void;
|
|
187
|
+
export const wrapdescriptor_fromString: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
188
|
+
export const wrapdescriptor_fromStringDetectType: (a: number, b: number, c: number) => void;
|
|
189
|
+
export const wrapdescriptor_hasWildcard: (a: number) => number;
|
|
190
|
+
export const wrapdescriptor_maxWeightToSatisfy: (a: number, b: number) => void;
|
|
191
|
+
export const wrapdescriptor_node: (a: number, b: number) => void;
|
|
192
|
+
export const wrapdescriptor_scriptPubkey: (a: number, b: number) => void;
|
|
193
|
+
export const wrapdescriptor_toAsmString: (a: number, b: number) => void;
|
|
194
|
+
export const wrapdescriptor_toString: (a: number, b: number) => void;
|
|
195
|
+
export const wrapminiscript_encode: (a: number, b: number) => void;
|
|
196
|
+
export const wrapminiscript_fromBitcoinScript: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
197
|
+
export const wrapminiscript_fromString: (a: number, b: number, c: number, d: number, e: number) => void;
|
|
198
|
+
export const wrapminiscript_node: (a: number, b: number) => void;
|
|
199
|
+
export const wrapminiscript_toAsmString: (a: number, b: number) => void;
|
|
200
|
+
export const wrapminiscript_toString: (a: number, b: number) => void;
|
|
196
201
|
export const rustsecp256k1_v0_10_0_context_create: (a: number) => number;
|
|
197
202
|
export const rustsecp256k1_v0_10_0_context_destroy: (a: number) => void;
|
|
198
203
|
export const rustsecp256k1_v0_10_0_default_error_callback_fn: (a: number, b: number) => void;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { BitGoPsbt as WasmBitGoPsbt } from "../wasm/wasm_utxo.js";
|
|
1
|
+
import { BitGoPsbt as WasmBitGoPsbt, type PsbtInputData, type PsbtOutputData, type PsbtOutputDataWithAddress } from "../wasm/wasm_utxo.js";
|
|
2
|
+
import type { IPsbtIntrospectionWithAddress } from "../psbt.js";
|
|
2
3
|
import { type WalletKeysArg } from "./RootWalletKeys.js";
|
|
3
4
|
import { type ReplayProtectionArg } from "./ReplayProtection.js";
|
|
4
5
|
import { type BIP32Arg } from "../bip32.js";
|
|
@@ -90,7 +91,14 @@ export type AddWalletOutputOptions = {
|
|
|
90
91
|
/** Value in satoshis */
|
|
91
92
|
value: bigint;
|
|
92
93
|
};
|
|
93
|
-
export
|
|
94
|
+
export type ParseTransactionOptions = {
|
|
95
|
+
replayProtection: ReplayProtectionArg;
|
|
96
|
+
payGoPubkeys?: ECPairArg[];
|
|
97
|
+
};
|
|
98
|
+
export type ParseOutputsOptions = {
|
|
99
|
+
payGoPubkeys?: ECPairArg[];
|
|
100
|
+
};
|
|
101
|
+
export declare class BitGoPsbt implements IPsbtIntrospectionWithAddress {
|
|
94
102
|
protected _wasm: WasmBitGoPsbt;
|
|
95
103
|
protected constructor(_wasm: WasmBitGoPsbt);
|
|
96
104
|
/**
|
|
@@ -305,11 +313,12 @@ export declare class BitGoPsbt {
|
|
|
305
313
|
/**
|
|
306
314
|
* Parse transaction with wallet keys to identify wallet inputs/outputs
|
|
307
315
|
* @param walletKeys - The wallet keys to use for identification
|
|
308
|
-
* @param
|
|
309
|
-
* @param
|
|
316
|
+
* @param options - Options for parsing
|
|
317
|
+
* @param options.replayProtection - Scripts that are allowed as inputs without wallet validation
|
|
318
|
+
* @param options.payGoPubkeys - Optional public keys for PayGo attestation verification
|
|
310
319
|
* @returns Parsed transaction information
|
|
311
320
|
*/
|
|
312
|
-
parseTransactionWithWalletKeys(walletKeys: WalletKeysArg,
|
|
321
|
+
parseTransactionWithWalletKeys(walletKeys: WalletKeysArg, options: ParseTransactionOptions): ParsedTransaction;
|
|
313
322
|
/**
|
|
314
323
|
* Parse outputs with wallet keys to identify which outputs belong to a wallet
|
|
315
324
|
* with the given wallet keys.
|
|
@@ -318,11 +327,12 @@ export declare class BitGoPsbt {
|
|
|
318
327
|
* wallet than the inputs.
|
|
319
328
|
*
|
|
320
329
|
* @param walletKeys - The wallet keys to use for identification
|
|
321
|
-
* @param
|
|
330
|
+
* @param options - Optional options for parsing
|
|
331
|
+
* @param options.payGoPubkeys - Optional public keys for PayGo attestation verification
|
|
322
332
|
* @returns Array of parsed outputs
|
|
323
333
|
* @note This method does NOT validate wallet inputs. It only parses outputs.
|
|
324
334
|
*/
|
|
325
|
-
parseOutputsWithWalletKeys(walletKeys: WalletKeysArg,
|
|
335
|
+
parseOutputsWithWalletKeys(walletKeys: WalletKeysArg, options?: ParseOutputsOptions): ParsedOutput[];
|
|
326
336
|
/**
|
|
327
337
|
* Add a PayGo attestation to a PSBT output
|
|
328
338
|
*
|
|
@@ -502,7 +512,7 @@ export declare class BitGoPsbt {
|
|
|
502
512
|
* const counterpartyPsbt = BitGoPsbt.fromBytes(counterpartyPsbtBytes, network);
|
|
503
513
|
* psbt.combineMusig2Nonces(counterpartyPsbt);
|
|
504
514
|
* // Sign MuSig2 key path inputs
|
|
505
|
-
* const parsed = psbt.parseTransactionWithWalletKeys(walletKeys, replayProtection);
|
|
515
|
+
* const parsed = psbt.parseTransactionWithWalletKeys(walletKeys, { replayProtection });
|
|
506
516
|
* for (let i = 0; i < parsed.inputs.length; i++) {
|
|
507
517
|
* if (parsed.inputs[i].scriptType === "p2trMusig2KeyPath") {
|
|
508
518
|
* psbt.sign(i, userXpriv);
|
|
@@ -570,4 +580,50 @@ export declare class BitGoPsbt {
|
|
|
570
580
|
* ```
|
|
571
581
|
*/
|
|
572
582
|
getHalfSignedLegacyFormat(): Uint8Array;
|
|
583
|
+
/**
|
|
584
|
+
* Get the number of inputs in the PSBT
|
|
585
|
+
* @returns The number of inputs
|
|
586
|
+
*/
|
|
587
|
+
get inputCount(): number;
|
|
588
|
+
/**
|
|
589
|
+
* Get the number of outputs in the PSBT
|
|
590
|
+
* @returns The number of outputs
|
|
591
|
+
*/
|
|
592
|
+
get outputCount(): number;
|
|
593
|
+
/**
|
|
594
|
+
* Get all PSBT inputs as an array
|
|
595
|
+
*
|
|
596
|
+
* Returns raw PSBT input data including witness_utxo and derivation info.
|
|
597
|
+
* For parsed transaction data with address identification, use
|
|
598
|
+
* parseTransactionWithWalletKeys() instead.
|
|
599
|
+
*
|
|
600
|
+
* @returns Array of PsbtInputData objects
|
|
601
|
+
*/
|
|
602
|
+
getInputs(): PsbtInputData[];
|
|
603
|
+
/**
|
|
604
|
+
* Get all PSBT outputs as an array
|
|
605
|
+
*
|
|
606
|
+
* Returns raw PSBT output data without address resolution.
|
|
607
|
+
* For output data with addresses, use getOutputsWithAddress().
|
|
608
|
+
*
|
|
609
|
+
* @returns Array of PsbtOutputData objects
|
|
610
|
+
*/
|
|
611
|
+
getOutputs(): PsbtOutputData[];
|
|
612
|
+
/**
|
|
613
|
+
* Get all PSBT outputs with resolved address strings
|
|
614
|
+
*
|
|
615
|
+
* Unlike the generic Psbt class which requires a coin parameter,
|
|
616
|
+
* BitGoPsbt automatically uses the network it was created with to resolve addresses.
|
|
617
|
+
*
|
|
618
|
+
* @returns Array of PsbtOutputDataWithAddress objects
|
|
619
|
+
*
|
|
620
|
+
* @example
|
|
621
|
+
* ```typescript
|
|
622
|
+
* const outputs = psbt.getOutputsWithAddress();
|
|
623
|
+
* for (const output of outputs) {
|
|
624
|
+
* console.log(`${output.address}: ${output.value} satoshis`);
|
|
625
|
+
* }
|
|
626
|
+
* ```
|
|
627
|
+
*/
|
|
628
|
+
getOutputsWithAddress(): PsbtOutputDataWithAddress[];
|
|
573
629
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BitGoPsbt as WasmBitGoPsbt } from "../wasm/wasm_utxo.js";
|
|
1
|
+
import { BitGoPsbt as WasmBitGoPsbt, } from "../wasm/wasm_utxo.js";
|
|
2
2
|
import { RootWalletKeys } from "./RootWalletKeys.js";
|
|
3
3
|
import { ReplayProtection } from "./ReplayProtection.js";
|
|
4
4
|
import { BIP32, isBIP32Arg } from "../bip32.js";
|
|
@@ -218,14 +218,15 @@ export class BitGoPsbt {
|
|
|
218
218
|
/**
|
|
219
219
|
* Parse transaction with wallet keys to identify wallet inputs/outputs
|
|
220
220
|
* @param walletKeys - The wallet keys to use for identification
|
|
221
|
-
* @param
|
|
222
|
-
* @param
|
|
221
|
+
* @param options - Options for parsing
|
|
222
|
+
* @param options.replayProtection - Scripts that are allowed as inputs without wallet validation
|
|
223
|
+
* @param options.payGoPubkeys - Optional public keys for PayGo attestation verification
|
|
223
224
|
* @returns Parsed transaction information
|
|
224
225
|
*/
|
|
225
|
-
parseTransactionWithWalletKeys(walletKeys,
|
|
226
|
+
parseTransactionWithWalletKeys(walletKeys, options) {
|
|
226
227
|
const keys = RootWalletKeys.from(walletKeys);
|
|
227
|
-
const rp = ReplayProtection.from(replayProtection, this._wasm.network());
|
|
228
|
-
const pubkeys = payGoPubkeys?.map((arg) => ECPair.from(arg).wasm);
|
|
228
|
+
const rp = ReplayProtection.from(options.replayProtection, this._wasm.network());
|
|
229
|
+
const pubkeys = options.payGoPubkeys?.map((arg) => ECPair.from(arg).wasm);
|
|
229
230
|
return this._wasm.parse_transaction_with_wallet_keys(keys.wasm, rp.wasm, pubkeys);
|
|
230
231
|
}
|
|
231
232
|
/**
|
|
@@ -236,13 +237,14 @@ export class BitGoPsbt {
|
|
|
236
237
|
* wallet than the inputs.
|
|
237
238
|
*
|
|
238
239
|
* @param walletKeys - The wallet keys to use for identification
|
|
239
|
-
* @param
|
|
240
|
+
* @param options - Optional options for parsing
|
|
241
|
+
* @param options.payGoPubkeys - Optional public keys for PayGo attestation verification
|
|
240
242
|
* @returns Array of parsed outputs
|
|
241
243
|
* @note This method does NOT validate wallet inputs. It only parses outputs.
|
|
242
244
|
*/
|
|
243
|
-
parseOutputsWithWalletKeys(walletKeys,
|
|
245
|
+
parseOutputsWithWalletKeys(walletKeys, options) {
|
|
244
246
|
const keys = RootWalletKeys.from(walletKeys);
|
|
245
|
-
const pubkeys = payGoPubkeys?.map((arg) => ECPair.from(arg).wasm);
|
|
247
|
+
const pubkeys = options?.payGoPubkeys?.map((arg) => ECPair.from(arg).wasm);
|
|
246
248
|
return this._wasm.parse_outputs_with_wallet_keys(keys.wasm, pubkeys);
|
|
247
249
|
}
|
|
248
250
|
/**
|
|
@@ -444,7 +446,7 @@ export class BitGoPsbt {
|
|
|
444
446
|
* const counterpartyPsbt = BitGoPsbt.fromBytes(counterpartyPsbtBytes, network);
|
|
445
447
|
* psbt.combineMusig2Nonces(counterpartyPsbt);
|
|
446
448
|
* // Sign MuSig2 key path inputs
|
|
447
|
-
* const parsed = psbt.parseTransactionWithWalletKeys(walletKeys, replayProtection);
|
|
449
|
+
* const parsed = psbt.parseTransactionWithWalletKeys(walletKeys, { replayProtection });
|
|
448
450
|
* for (let i = 0; i < parsed.inputs.length; i++) {
|
|
449
451
|
* if (parsed.inputs[i].scriptType === "p2trMusig2KeyPath") {
|
|
450
452
|
* psbt.sign(i, userXpriv);
|
|
@@ -532,4 +534,60 @@ export class BitGoPsbt {
|
|
|
532
534
|
getHalfSignedLegacyFormat() {
|
|
533
535
|
return this._wasm.extract_half_signed_legacy_tx();
|
|
534
536
|
}
|
|
537
|
+
/**
|
|
538
|
+
* Get the number of inputs in the PSBT
|
|
539
|
+
* @returns The number of inputs
|
|
540
|
+
*/
|
|
541
|
+
get inputCount() {
|
|
542
|
+
return this._wasm.input_count();
|
|
543
|
+
}
|
|
544
|
+
/**
|
|
545
|
+
* Get the number of outputs in the PSBT
|
|
546
|
+
* @returns The number of outputs
|
|
547
|
+
*/
|
|
548
|
+
get outputCount() {
|
|
549
|
+
return this._wasm.output_count();
|
|
550
|
+
}
|
|
551
|
+
/**
|
|
552
|
+
* Get all PSBT inputs as an array
|
|
553
|
+
*
|
|
554
|
+
* Returns raw PSBT input data including witness_utxo and derivation info.
|
|
555
|
+
* For parsed transaction data with address identification, use
|
|
556
|
+
* parseTransactionWithWalletKeys() instead.
|
|
557
|
+
*
|
|
558
|
+
* @returns Array of PsbtInputData objects
|
|
559
|
+
*/
|
|
560
|
+
getInputs() {
|
|
561
|
+
return this._wasm.get_inputs();
|
|
562
|
+
}
|
|
563
|
+
/**
|
|
564
|
+
* Get all PSBT outputs as an array
|
|
565
|
+
*
|
|
566
|
+
* Returns raw PSBT output data without address resolution.
|
|
567
|
+
* For output data with addresses, use getOutputsWithAddress().
|
|
568
|
+
*
|
|
569
|
+
* @returns Array of PsbtOutputData objects
|
|
570
|
+
*/
|
|
571
|
+
getOutputs() {
|
|
572
|
+
return this._wasm.get_outputs();
|
|
573
|
+
}
|
|
574
|
+
/**
|
|
575
|
+
* Get all PSBT outputs with resolved address strings
|
|
576
|
+
*
|
|
577
|
+
* Unlike the generic Psbt class which requires a coin parameter,
|
|
578
|
+
* BitGoPsbt automatically uses the network it was created with to resolve addresses.
|
|
579
|
+
*
|
|
580
|
+
* @returns Array of PsbtOutputDataWithAddress objects
|
|
581
|
+
*
|
|
582
|
+
* @example
|
|
583
|
+
* ```typescript
|
|
584
|
+
* const outputs = psbt.getOutputsWithAddress();
|
|
585
|
+
* for (const output of outputs) {
|
|
586
|
+
* console.log(`${output.address}: ${output.value} satoshis`);
|
|
587
|
+
* }
|
|
588
|
+
* ```
|
|
589
|
+
*/
|
|
590
|
+
getOutputsWithAddress() {
|
|
591
|
+
return this._wasm.get_outputs_with_address();
|
|
592
|
+
}
|
|
535
593
|
}
|
|
@@ -5,8 +5,9 @@ export { outputScript, address } from "./address.js";
|
|
|
5
5
|
export { Dimensions } from "./Dimensions.js";
|
|
6
6
|
export { outputScriptTypes, inputScriptTypes, type OutputScriptType, type InputScriptType, type ScriptType, } from "./scriptType.js";
|
|
7
7
|
export { ChainCode, chainCodes, assertChainCode, type Scope } from "./chains.js";
|
|
8
|
-
export { BitGoPsbt, type NetworkName, type ScriptId, type ParsedInput, type ParsedOutput, type ParsedTransaction, type SignPath, type CreateEmptyOptions, type AddInputOptions, type AddOutputOptions, type AddWalletInputOptions, type AddWalletOutputOptions, } from "./BitGoPsbt.js";
|
|
8
|
+
export { BitGoPsbt, type NetworkName, type ScriptId, type ParsedInput, type ParsedOutput, type ParsedTransaction, type SignPath, type CreateEmptyOptions, type AddInputOptions, type AddOutputOptions, type AddWalletInputOptions, type AddWalletOutputOptions, type ParseTransactionOptions, type ParseOutputsOptions, } from "./BitGoPsbt.js";
|
|
9
9
|
export { ZcashBitGoPsbt, type ZcashNetworkName, type CreateEmptyZcashOptions, } from "./ZcashBitGoPsbt.js";
|
|
10
|
+
export type { PsbtBip32Derivation, PsbtInputData, PsbtOutputData, PsbtOutputDataWithAddress, PsbtWitnessUtxo, } from "../wasm/wasm_utxo.js";
|
|
10
11
|
import type { ScriptType } from "./scriptType.js";
|
|
11
12
|
/**
|
|
12
13
|
* Check if a network supports a given fixed-script wallet script type
|
package/dist/esm/js/index.d.ts
CHANGED
|
@@ -91,4 +91,4 @@ export { WrapDescriptor as Descriptor } from "./wasm/wasm_utxo.js";
|
|
|
91
91
|
export { WrapMiniscript as Miniscript } from "./wasm/wasm_utxo.js";
|
|
92
92
|
export { WrapPsbt as Psbt } from "./wasm/wasm_utxo.js";
|
|
93
93
|
export { DashTransaction, Transaction, ZcashTransaction } from "./transaction.js";
|
|
94
|
-
export { hasPsbtMagic } from "./psbt.js";
|
|
94
|
+
export { hasPsbtMagic, type IPsbtIntrospection, type IPsbtIntrospectionWithAddress, } from "./psbt.js";
|
package/dist/esm/js/index.js
CHANGED
|
@@ -23,4 +23,4 @@ export { WrapDescriptor as Descriptor } from "./wasm/wasm_utxo.js";
|
|
|
23
23
|
export { WrapMiniscript as Miniscript } from "./wasm/wasm_utxo.js";
|
|
24
24
|
export { WrapPsbt as Psbt } from "./wasm/wasm_utxo.js";
|
|
25
25
|
export { DashTransaction, Transaction, ZcashTransaction } from "./transaction.js";
|
|
26
|
-
export { hasPsbtMagic } from "./psbt.js";
|
|
26
|
+
export { hasPsbtMagic, } from "./psbt.js";
|
package/dist/esm/js/psbt.d.ts
CHANGED
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
import type { PsbtInputData, PsbtOutputData, PsbtOutputDataWithAddress } from "./wasm/wasm_utxo.js";
|
|
2
|
+
/** Common interface for PSBT introspection methods */
|
|
3
|
+
export interface IPsbtIntrospection {
|
|
4
|
+
readonly inputCount: number;
|
|
5
|
+
readonly outputCount: number;
|
|
6
|
+
getInputs(): PsbtInputData[];
|
|
7
|
+
getOutputs(): PsbtOutputData[];
|
|
8
|
+
}
|
|
9
|
+
/** Extended introspection with address resolution (no coin parameter needed) */
|
|
10
|
+
export interface IPsbtIntrospectionWithAddress extends IPsbtIntrospection {
|
|
11
|
+
getOutputsWithAddress(): PsbtOutputDataWithAddress[];
|
|
12
|
+
}
|
|
1
13
|
/**
|
|
2
14
|
* Check if a byte array has the PSBT magic bytes
|
|
3
15
|
*
|
|
@@ -384,6 +384,13 @@ export class BitGoPsbt {
|
|
|
384
384
|
* generated for security. Custom session_id is only allowed on testnets for testing purposes.
|
|
385
385
|
*/
|
|
386
386
|
generate_musig2_nonces(xpriv: WasmBIP32, session_id_bytes?: Uint8Array | null): void;
|
|
387
|
+
/**
|
|
388
|
+
* Get all PSBT inputs as an array of PsbtInputData
|
|
389
|
+
*
|
|
390
|
+
* Returns an array with witness_utxo, bip32_derivation, and tap_bip32_derivation
|
|
391
|
+
* for each input.
|
|
392
|
+
*/
|
|
393
|
+
get_inputs(): any;
|
|
387
394
|
/**
|
|
388
395
|
* Get the network type for transaction extraction
|
|
389
396
|
*
|
|
@@ -391,6 +398,24 @@ export class BitGoPsbt {
|
|
|
391
398
|
* wrapper class should be used in TypeScript.
|
|
392
399
|
*/
|
|
393
400
|
get_network_type(): string;
|
|
401
|
+
/**
|
|
402
|
+
* Get all PSBT outputs as an array of PsbtOutputData
|
|
403
|
+
*
|
|
404
|
+
* Returns an array with script, value, bip32_derivation, and tap_bip32_derivation
|
|
405
|
+
* for each output.
|
|
406
|
+
*/
|
|
407
|
+
get_outputs(): any;
|
|
408
|
+
/**
|
|
409
|
+
* Get all PSBT outputs with resolved address strings.
|
|
410
|
+
*
|
|
411
|
+
* Unlike the generic WrapPsbt which requires a coin parameter, BitGoPsbt
|
|
412
|
+
* uses the network it was created/deserialized with to resolve addresses.
|
|
413
|
+
*/
|
|
414
|
+
get_outputs_with_address(): any;
|
|
415
|
+
/**
|
|
416
|
+
* Get the number of inputs in the PSBT
|
|
417
|
+
*/
|
|
418
|
+
input_count(): number;
|
|
394
419
|
/**
|
|
395
420
|
* Check if an input is a MuSig2 keypath input.
|
|
396
421
|
*
|
|
@@ -413,6 +438,10 @@ export class BitGoPsbt {
|
|
|
413
438
|
* Get the network of the PSBT
|
|
414
439
|
*/
|
|
415
440
|
network(): string;
|
|
441
|
+
/**
|
|
442
|
+
* Get the number of outputs in the PSBT
|
|
443
|
+
*/
|
|
444
|
+
output_count(): number;
|
|
416
445
|
/**
|
|
417
446
|
* Parse outputs with wallet keys to identify which outputs belong to a wallet
|
|
418
447
|
*
|