@did-btcr2/bitcoin 0.3.3 → 0.4.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/bitcoin.js +82 -83
- package/dist/cjs/bitcoin.js.map +1 -1
- package/dist/cjs/client/http.js +9 -0
- package/dist/cjs/client/http.js.map +1 -0
- package/dist/cjs/client/rest/address.js +20 -28
- package/dist/cjs/client/rest/address.js.map +1 -1
- package/dist/cjs/client/rest/block.js +23 -22
- package/dist/cjs/client/rest/block.js.map +1 -1
- package/dist/cjs/client/rest/index.js +30 -83
- package/dist/cjs/client/rest/index.js.map +1 -1
- package/dist/cjs/client/rest/protocol.js +129 -0
- package/dist/cjs/client/rest/protocol.js.map +1 -0
- package/dist/cjs/client/rest/transaction.js +19 -21
- package/dist/cjs/client/rest/transaction.js.map +1 -1
- package/dist/cjs/client/rpc/index.js +77 -338
- package/dist/cjs/client/rpc/index.js.map +1 -1
- package/dist/cjs/client/rpc/interface.js +1 -6
- package/dist/cjs/client/rpc/interface.js.map +1 -1
- package/dist/cjs/client/rpc/json-rpc.js +40 -63
- package/dist/cjs/client/rpc/json-rpc.js.map +1 -1
- package/dist/cjs/client/rpc/protocol.js +134 -0
- package/dist/cjs/client/rpc/protocol.js.map +1 -0
- package/dist/cjs/constants.js +16 -5
- package/dist/cjs/constants.js.map +1 -1
- package/dist/cjs/errors.js.map +1 -1
- package/dist/cjs/index.js +21 -13
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types.js +5 -55
- package/dist/cjs/types.js.map +1 -1
- package/dist/esm/bitcoin.js +82 -83
- package/dist/esm/bitcoin.js.map +1 -1
- package/dist/esm/client/http.js +9 -0
- package/dist/esm/client/http.js.map +1 -0
- package/dist/esm/client/rest/address.js +20 -28
- package/dist/esm/client/rest/address.js.map +1 -1
- package/dist/esm/client/rest/block.js +23 -22
- package/dist/esm/client/rest/block.js.map +1 -1
- package/dist/esm/client/rest/index.js +30 -83
- package/dist/esm/client/rest/index.js.map +1 -1
- package/dist/esm/client/rest/protocol.js +129 -0
- package/dist/esm/client/rest/protocol.js.map +1 -0
- package/dist/esm/client/rest/transaction.js +19 -21
- package/dist/esm/client/rest/transaction.js.map +1 -1
- package/dist/esm/client/rpc/index.js +77 -338
- package/dist/esm/client/rpc/index.js.map +1 -1
- package/dist/esm/client/rpc/interface.js +1 -6
- package/dist/esm/client/rpc/interface.js.map +1 -1
- package/dist/esm/client/rpc/json-rpc.js +40 -63
- package/dist/esm/client/rpc/json-rpc.js.map +1 -1
- package/dist/esm/client/rpc/protocol.js +134 -0
- package/dist/esm/client/rpc/protocol.js.map +1 -0
- package/dist/esm/constants.js +16 -5
- package/dist/esm/constants.js.map +1 -1
- package/dist/esm/errors.js.map +1 -1
- package/dist/esm/index.js +21 -13
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types.js +5 -55
- package/dist/esm/types.js.map +1 -1
- package/dist/types/bitcoin.d.ts +66 -45
- package/dist/types/bitcoin.d.ts.map +1 -1
- package/dist/types/client/http.d.ts +21 -0
- package/dist/types/client/http.d.ts.map +1 -0
- package/dist/types/client/rest/address.d.ts +16 -19
- package/dist/types/client/rest/address.d.ts.map +1 -1
- package/dist/types/client/rest/block.d.ts +24 -16
- package/dist/types/client/rest/block.d.ts.map +1 -1
- package/dist/types/client/rest/index.d.ts +20 -51
- package/dist/types/client/rest/index.d.ts.map +1 -1
- package/dist/types/client/rest/protocol.d.ts +58 -0
- package/dist/types/client/rest/protocol.d.ts.map +1 -0
- package/dist/types/client/rest/transaction.d.ts +16 -17
- package/dist/types/client/rest/transaction.d.ts.map +1 -1
- package/dist/types/client/rpc/index.d.ts +105 -253
- package/dist/types/client/rpc/index.d.ts.map +1 -1
- package/dist/types/client/rpc/interface.d.ts +1 -4
- package/dist/types/client/rpc/interface.d.ts.map +1 -1
- package/dist/types/client/rpc/json-rpc.d.ts +20 -18
- package/dist/types/client/rpc/json-rpc.d.ts.map +1 -1
- package/dist/types/client/rpc/protocol.d.ts +82 -0
- package/dist/types/client/rpc/protocol.d.ts.map +1 -0
- package/dist/types/constants.d.ts +16 -5
- package/dist/types/constants.d.ts.map +1 -1
- package/dist/types/errors.d.ts +4 -3
- package/dist/types/errors.d.ts.map +1 -1
- package/dist/types/index.d.ts +20 -13
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/types.d.ts +98 -696
- package/dist/types/types.d.ts.map +1 -1
- package/package.json +3 -3
- package/src/bitcoin.ts +104 -117
- package/src/client/http.ts +28 -0
- package/src/client/rest/address.ts +24 -30
- package/src/client/rest/block.ts +29 -26
- package/src/client/rest/index.ts +37 -93
- package/src/client/rest/protocol.ts +153 -0
- package/src/client/rest/transaction.ts +23 -23
- package/src/client/rpc/index.ts +142 -380
- package/src/client/rpc/interface.ts +42 -51
- package/src/client/rpc/json-rpc.ts +53 -60
- package/src/client/rpc/protocol.ts +160 -0
- package/src/constants.ts +17 -5
- package/src/errors.ts +10 -3
- package/src/index.ts +81 -13
- package/src/types.ts +332 -973
package/dist/types/types.d.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { UnixTimestamp } from '@did-btcr2/common';
|
|
2
|
+
/** Bitcoin network names supported by this package. */
|
|
3
|
+
export type NetworkName = 'bitcoin' | 'testnet3' | 'testnet4' | 'signet' | 'mutinynet' | 'regtest';
|
|
2
4
|
export type TransactionStatus = {
|
|
3
5
|
confirmed: boolean;
|
|
4
6
|
block_height: number;
|
|
@@ -58,224 +60,81 @@ export interface AddressUtxo {
|
|
|
58
60
|
status: TransactionStatus;
|
|
59
61
|
value: number;
|
|
60
62
|
}
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
63
|
+
/** Block data as returned by the Esplora REST API. */
|
|
64
|
+
export interface EsploraBlock {
|
|
65
|
+
id: string;
|
|
66
|
+
height: number;
|
|
67
|
+
version: number;
|
|
68
|
+
timestamp: number;
|
|
69
|
+
tx_count: number;
|
|
70
|
+
size: number;
|
|
71
|
+
weight: number;
|
|
72
|
+
merkle_root: string;
|
|
73
|
+
previousblockhash: string;
|
|
74
|
+
mediantime: number;
|
|
75
|
+
nonce: number;
|
|
76
|
+
bits: number;
|
|
77
|
+
difficulty: number;
|
|
66
78
|
}
|
|
67
|
-
export
|
|
79
|
+
export interface RestConfig {
|
|
68
80
|
host: string;
|
|
69
|
-
headers?:
|
|
70
|
-
[key: string]: string;
|
|
71
|
-
};
|
|
72
|
-
constructor({ host, headers }: RestClientConfigParams);
|
|
81
|
+
headers?: Record<string, string>;
|
|
73
82
|
}
|
|
74
83
|
export interface RestApiCallParams {
|
|
75
84
|
path: string;
|
|
76
85
|
url?: string;
|
|
77
|
-
method?:
|
|
78
|
-
body?:
|
|
79
|
-
headers?: any;
|
|
80
|
-
}
|
|
81
|
-
export interface RestResponse extends Response {
|
|
82
|
-
[key: string]: any;
|
|
83
|
-
}
|
|
84
|
-
export type BitcoinClientConfig = {
|
|
85
|
-
rpc: {
|
|
86
|
-
username: string;
|
|
87
|
-
password: string;
|
|
88
|
-
host: string;
|
|
89
|
-
version: string;
|
|
90
|
-
allowDefaultWallet: boolean;
|
|
91
|
-
};
|
|
92
|
-
rest: {
|
|
93
|
-
host: string;
|
|
94
|
-
headers?: Record<string, string>;
|
|
95
|
-
};
|
|
96
|
-
};
|
|
97
|
-
export type AvailableNetworks = {
|
|
98
|
-
bitcoin: true;
|
|
99
|
-
testnet3: true;
|
|
100
|
-
testnet4: true;
|
|
101
|
-
signet: true;
|
|
102
|
-
mutinynet: true;
|
|
103
|
-
regtest: true;
|
|
104
|
-
};
|
|
105
|
-
export interface ReturnFormatOptions {
|
|
106
|
-
extension?: 'json' | 'bin' | 'hex';
|
|
107
|
-
}
|
|
108
|
-
export type TxId = string;
|
|
109
|
-
export interface BlockHashOptions extends ReturnFormatOptions {
|
|
110
|
-
summary?: boolean;
|
|
111
|
-
}
|
|
112
|
-
export interface RpcClientConfig {
|
|
86
|
+
method?: 'GET' | 'POST';
|
|
87
|
+
body?: string | Record<string, unknown>;
|
|
113
88
|
headers?: Record<string, string>;
|
|
114
|
-
host?: string;
|
|
115
|
-
logger?: any;
|
|
116
|
-
password?: string;
|
|
117
|
-
timeout?: number;
|
|
118
|
-
username?: string;
|
|
119
|
-
version?: string;
|
|
120
|
-
wallet?: string;
|
|
121
|
-
allowDefaultWallet?: boolean;
|
|
122
89
|
}
|
|
123
|
-
export
|
|
124
|
-
|
|
90
|
+
export type RestResponse = Response;
|
|
91
|
+
export interface RpcConfig {
|
|
125
92
|
headers?: Record<string, string>;
|
|
126
93
|
host?: string;
|
|
127
|
-
logger?: any;
|
|
128
94
|
password?: string;
|
|
129
|
-
timeout?: number;
|
|
130
95
|
username?: string;
|
|
131
|
-
version?: string;
|
|
132
96
|
wallet?: string;
|
|
133
97
|
allowDefaultWallet?: boolean;
|
|
134
|
-
constructor(options?: RpcClientConfig);
|
|
135
|
-
}
|
|
136
|
-
export interface ClientConstructorOption {
|
|
137
|
-
agentOptions?: any;
|
|
138
|
-
headers?: boolean;
|
|
139
|
-
host?: string;
|
|
140
|
-
logger?: Function;
|
|
141
|
-
network?: 'mainnet' | 'regtest' | 'testnet';
|
|
142
|
-
password?: string;
|
|
143
|
-
port?: string | number;
|
|
144
|
-
ssl?: any;
|
|
145
|
-
timeout?: number;
|
|
146
|
-
username?: string;
|
|
147
|
-
version?: string;
|
|
148
98
|
}
|
|
149
|
-
export type ScriptDecoded = {
|
|
150
|
-
asm: string;
|
|
151
|
-
hex: string;
|
|
152
|
-
type: string;
|
|
153
|
-
reqSigs: number;
|
|
154
|
-
addresses: string[];
|
|
155
|
-
ps2h?: string;
|
|
156
|
-
};
|
|
157
|
-
export type FundRawTxOptions = {
|
|
158
|
-
changeAddress?: string;
|
|
159
|
-
chnagePosition?: number;
|
|
160
|
-
includeWatching?: boolean;
|
|
161
|
-
lockUnspents?: boolean;
|
|
162
|
-
feeRate?: number;
|
|
163
|
-
subtractFeeFromOutputs?: number[];
|
|
164
|
-
replaceable?: boolean;
|
|
165
|
-
conf_target?: number;
|
|
166
|
-
estimate_mode: FeeEstimateMode;
|
|
167
|
-
};
|
|
168
|
-
/**
|
|
169
|
-
* unset
|
|
170
|
-
* - no mode set
|
|
171
|
-
* economical
|
|
172
|
-
* - used if the transaction is replaceable
|
|
173
|
-
* - uses shorter time horizon to estimate
|
|
174
|
-
* - more responsive to short-term drops in the prevailing fee market
|
|
175
|
-
* - potentially returns a lower fee rate estimate
|
|
176
|
-
* conservative
|
|
177
|
-
* - used is the transaction is not replaceable
|
|
178
|
-
* - use a longer time horizon to estimate
|
|
179
|
-
* - less responsive to short-term drops in the prevailing fee market
|
|
180
|
-
* - potentially returns a higher fee rate estimate
|
|
181
|
-
*/
|
|
182
99
|
export type FeeEstimateMode = 'UNSET' | 'ECONOMICAL' | 'CONSERVATIVE';
|
|
183
|
-
export type
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
txrate: number;
|
|
191
|
-
};
|
|
192
|
-
export type AddedNodeInfo = {
|
|
193
|
-
addednode: string;
|
|
194
|
-
connected: boolean;
|
|
195
|
-
addresses: {
|
|
196
|
-
address: string;
|
|
197
|
-
connected: 'inbound' | 'outbound';
|
|
198
|
-
}[];
|
|
199
|
-
};
|
|
200
|
-
export type MemoryStats = {
|
|
201
|
-
locked: {
|
|
202
|
-
used: number;
|
|
203
|
-
free: number;
|
|
204
|
-
total: number;
|
|
205
|
-
locked: number;
|
|
206
|
-
chunks_used: number;
|
|
207
|
-
chunks_free: number;
|
|
100
|
+
export type TxIn = {
|
|
101
|
+
coinbase?: string;
|
|
102
|
+
txid?: string;
|
|
103
|
+
vout?: number;
|
|
104
|
+
scriptSig?: {
|
|
105
|
+
asm: string;
|
|
106
|
+
hex: string;
|
|
208
107
|
};
|
|
108
|
+
txinwitness?: string[];
|
|
109
|
+
sequence: number;
|
|
209
110
|
};
|
|
210
|
-
export type
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
name: string;
|
|
221
|
-
limited: boolean;
|
|
222
|
-
reachable: boolean;
|
|
223
|
-
proxy: string;
|
|
224
|
-
proxy_randomize_credentials: boolean;
|
|
225
|
-
}[];
|
|
226
|
-
relayfee: number;
|
|
227
|
-
incrementalfee: number;
|
|
228
|
-
localaddresses: {
|
|
229
|
-
address: string;
|
|
230
|
-
port: number;
|
|
231
|
-
score: number;
|
|
232
|
-
}[];
|
|
233
|
-
warnings?: string;
|
|
234
|
-
};
|
|
235
|
-
export type PeerInfo = {
|
|
236
|
-
id: number;
|
|
237
|
-
addr: string;
|
|
238
|
-
addrbind: string;
|
|
239
|
-
addrlocal: string;
|
|
240
|
-
services: string;
|
|
241
|
-
relaytxs: boolean;
|
|
242
|
-
lastsend: number;
|
|
243
|
-
lastrecv: number;
|
|
244
|
-
bytessent: number;
|
|
245
|
-
bytesrecv: number;
|
|
246
|
-
conntime: number;
|
|
247
|
-
timeoffset: number;
|
|
248
|
-
pingtime: number;
|
|
249
|
-
minping: number;
|
|
250
|
-
version: number;
|
|
251
|
-
subver: string;
|
|
252
|
-
inbound: boolean;
|
|
253
|
-
addnode: boolean;
|
|
254
|
-
startinheight: number;
|
|
255
|
-
banscore: number;
|
|
256
|
-
synced_headers: number;
|
|
257
|
-
synced_blocks: number;
|
|
258
|
-
inflight: number[];
|
|
259
|
-
whitelisted: boolean;
|
|
260
|
-
bytessent_per_msg: {
|
|
261
|
-
[key: string]: number;
|
|
262
|
-
};
|
|
263
|
-
byterecv_per_msg: {
|
|
264
|
-
[key: string]: number;
|
|
111
|
+
export type TxInPrevout = {
|
|
112
|
+
generated: boolean;
|
|
113
|
+
height: number;
|
|
114
|
+
value: number;
|
|
115
|
+
scriptPubKey?: {
|
|
116
|
+
asm: string;
|
|
117
|
+
desc: string;
|
|
118
|
+
hex: string;
|
|
119
|
+
address?: string;
|
|
120
|
+
type: string;
|
|
265
121
|
};
|
|
266
122
|
};
|
|
267
|
-
export
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
123
|
+
export interface TxInExt extends TxIn {
|
|
124
|
+
prevout: TxInPrevout;
|
|
125
|
+
}
|
|
126
|
+
export type ScriptPubKey = {
|
|
127
|
+
asm: string;
|
|
128
|
+
hex: string;
|
|
129
|
+
reqSigs: number;
|
|
130
|
+
type: string;
|
|
131
|
+
address?: string;
|
|
132
|
+
desc: string;
|
|
133
|
+
};
|
|
134
|
+
export type TxOut = {
|
|
135
|
+
value: number;
|
|
136
|
+
n: number;
|
|
137
|
+
scriptPubKey: ScriptPubKey;
|
|
279
138
|
};
|
|
280
139
|
export type ChainInfo = {
|
|
281
140
|
chain: string;
|
|
@@ -306,125 +165,6 @@ export type ChainInfo = {
|
|
|
306
165
|
}[];
|
|
307
166
|
warnings?: string;
|
|
308
167
|
};
|
|
309
|
-
export type ChainTip = {
|
|
310
|
-
height: number;
|
|
311
|
-
hash: string;
|
|
312
|
-
branchlen: number;
|
|
313
|
-
status: 'active' | 'valid-fork' | 'valid-headers' | 'headers-only' | 'invalid';
|
|
314
|
-
};
|
|
315
|
-
export type Outpoint = {
|
|
316
|
-
id: string;
|
|
317
|
-
index: number;
|
|
318
|
-
};
|
|
319
|
-
export type UTXO = {
|
|
320
|
-
height: number;
|
|
321
|
-
value: number;
|
|
322
|
-
scriptPubkey: {
|
|
323
|
-
asm: string;
|
|
324
|
-
hex: string;
|
|
325
|
-
reqSigs: number;
|
|
326
|
-
type: string;
|
|
327
|
-
addresses: string[];
|
|
328
|
-
};
|
|
329
|
-
};
|
|
330
|
-
export type UnspentTxInfo = {
|
|
331
|
-
txid: string;
|
|
332
|
-
vout: number;
|
|
333
|
-
address: string;
|
|
334
|
-
acount: string;
|
|
335
|
-
scriptPubKey: string;
|
|
336
|
-
amount: number;
|
|
337
|
-
confirmations: number;
|
|
338
|
-
redeemScript: string;
|
|
339
|
-
spendable: boolean;
|
|
340
|
-
solvable: boolean;
|
|
341
|
-
safe: boolean;
|
|
342
|
-
};
|
|
343
|
-
export type PrevOut = {
|
|
344
|
-
txid: string;
|
|
345
|
-
vout: number;
|
|
346
|
-
scriptPubKey: string;
|
|
347
|
-
redeemScript?: string;
|
|
348
|
-
amount: number;
|
|
349
|
-
};
|
|
350
|
-
export type UTXOStats = {
|
|
351
|
-
height: number;
|
|
352
|
-
bestblock: string;
|
|
353
|
-
transactions: number;
|
|
354
|
-
txouts: number;
|
|
355
|
-
bogosize: number;
|
|
356
|
-
hash_serialized_2: string;
|
|
357
|
-
disk_size: number;
|
|
358
|
-
total_amount: number;
|
|
359
|
-
};
|
|
360
|
-
export type MempoolContent = {
|
|
361
|
-
[key: string]: {
|
|
362
|
-
size: number;
|
|
363
|
-
fee: number;
|
|
364
|
-
modifiedfee: number;
|
|
365
|
-
time: number;
|
|
366
|
-
height: number;
|
|
367
|
-
descendantcount: number;
|
|
368
|
-
descendantsize: number;
|
|
369
|
-
descendantfees: number;
|
|
370
|
-
ancestorcount: number;
|
|
371
|
-
ancestorsize: number;
|
|
372
|
-
ancestorfees: number;
|
|
373
|
-
wtxid: string;
|
|
374
|
-
depends: string[];
|
|
375
|
-
};
|
|
376
|
-
};
|
|
377
|
-
export type DecodedRawTransaction = {
|
|
378
|
-
txid: string;
|
|
379
|
-
hash: string;
|
|
380
|
-
size: number;
|
|
381
|
-
vsize: number;
|
|
382
|
-
version: number;
|
|
383
|
-
locktime: number;
|
|
384
|
-
vin: TxIn[];
|
|
385
|
-
vout: TxOut[];
|
|
386
|
-
};
|
|
387
|
-
export interface FetchedRawTransaction extends DecodedRawTransaction {
|
|
388
|
-
hex: string;
|
|
389
|
-
blockhash: string;
|
|
390
|
-
confirmations: number;
|
|
391
|
-
time: number;
|
|
392
|
-
blocktime: number;
|
|
393
|
-
}
|
|
394
|
-
export type MiningInfo = {
|
|
395
|
-
blocks: number;
|
|
396
|
-
currentblockweight: number;
|
|
397
|
-
currentblocktx: number;
|
|
398
|
-
difficulty: number;
|
|
399
|
-
networkhashps: number;
|
|
400
|
-
pooledtx: number;
|
|
401
|
-
chain: 'main' | 'test' | 'regtest';
|
|
402
|
-
warnings?: string;
|
|
403
|
-
};
|
|
404
|
-
export type MempoolInfo = {
|
|
405
|
-
size: number;
|
|
406
|
-
bytes: number;
|
|
407
|
-
usage: number;
|
|
408
|
-
maxmempol: number;
|
|
409
|
-
mempoolminfee: number;
|
|
410
|
-
minrelaytxfee: number;
|
|
411
|
-
};
|
|
412
|
-
export type BlockHeader = {
|
|
413
|
-
hash: string;
|
|
414
|
-
confirmations: number;
|
|
415
|
-
height: number;
|
|
416
|
-
version: number;
|
|
417
|
-
versionHex: string;
|
|
418
|
-
merkleroot: string;
|
|
419
|
-
time: number;
|
|
420
|
-
mediantime: number;
|
|
421
|
-
nonce: number;
|
|
422
|
-
bits: string;
|
|
423
|
-
difficulty: number;
|
|
424
|
-
chainwork: string;
|
|
425
|
-
previoutsblockchash: string;
|
|
426
|
-
};
|
|
427
|
-
/** Block and GetBlock */
|
|
428
168
|
export type Block = {
|
|
429
169
|
hash: string;
|
|
430
170
|
confirmations: number;
|
|
@@ -456,7 +196,6 @@ export interface BlockV3 extends Block {
|
|
|
456
196
|
tx: Array<RawTransactionV2>;
|
|
457
197
|
}
|
|
458
198
|
export type BlockResponse = BlockV0 | BlockV1 | BlockV2 | BlockV3;
|
|
459
|
-
/** Transaction and RawTransaction */
|
|
460
199
|
export type Transaction = {
|
|
461
200
|
hex: string;
|
|
462
201
|
txid: string;
|
|
@@ -467,44 +206,6 @@ export type Transaction = {
|
|
|
467
206
|
version: number;
|
|
468
207
|
locktime: number;
|
|
469
208
|
};
|
|
470
|
-
export type TxIn = {
|
|
471
|
-
coinbase?: string;
|
|
472
|
-
txid?: string;
|
|
473
|
-
vout?: number;
|
|
474
|
-
scriptSig?: {
|
|
475
|
-
asm: string;
|
|
476
|
-
hex: string;
|
|
477
|
-
};
|
|
478
|
-
txinwitness?: string[];
|
|
479
|
-
sequence: number;
|
|
480
|
-
};
|
|
481
|
-
export type TxInPrevout = {
|
|
482
|
-
generated: boolean;
|
|
483
|
-
height: number;
|
|
484
|
-
value: number;
|
|
485
|
-
scriptPubKey?: {
|
|
486
|
-
asm: string;
|
|
487
|
-
desc: string;
|
|
488
|
-
hex: string;
|
|
489
|
-
address?: string;
|
|
490
|
-
type: string;
|
|
491
|
-
};
|
|
492
|
-
};
|
|
493
|
-
export interface TxInExt extends TxIn {
|
|
494
|
-
prevout: TxInPrevout;
|
|
495
|
-
}
|
|
496
|
-
export type TxOut = {
|
|
497
|
-
value: number;
|
|
498
|
-
n: number;
|
|
499
|
-
scriptPubKey: {
|
|
500
|
-
asm: string;
|
|
501
|
-
hex: string;
|
|
502
|
-
reqSigs: number;
|
|
503
|
-
type: scriptPubkeyType;
|
|
504
|
-
address?: string;
|
|
505
|
-
desc: string;
|
|
506
|
-
};
|
|
507
|
-
};
|
|
508
209
|
export type RawTransactionV0 = string;
|
|
509
210
|
export interface RawTransactionV1 extends Transaction {
|
|
510
211
|
vin: TxIn[];
|
|
@@ -521,30 +222,34 @@ export type CreateRawTxInputs = {
|
|
|
521
222
|
vout: number;
|
|
522
223
|
sequence?: number;
|
|
523
224
|
};
|
|
524
|
-
export type
|
|
525
|
-
address: string;
|
|
225
|
+
export type CreateRawTxOutputs = {
|
|
226
|
+
[address: string]: number;
|
|
227
|
+
} | {
|
|
526
228
|
data: string;
|
|
527
229
|
};
|
|
528
|
-
export type
|
|
529
|
-
bestblock: string;
|
|
530
|
-
confirmations: number;
|
|
531
|
-
value: number;
|
|
532
|
-
scriptPubKey: {
|
|
533
|
-
asm: string;
|
|
534
|
-
hex: string;
|
|
535
|
-
reqSigs: number;
|
|
536
|
-
type: scriptPubkeyType;
|
|
537
|
-
addresses: string[];
|
|
538
|
-
};
|
|
539
|
-
coinbase: boolean;
|
|
540
|
-
};
|
|
541
|
-
export type DecodedScript = {
|
|
542
|
-
asm: string;
|
|
230
|
+
export type SignedRawTx = {
|
|
543
231
|
hex: string;
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
232
|
+
complete: boolean;
|
|
233
|
+
errors?: {
|
|
234
|
+
txid: string;
|
|
235
|
+
vout: number;
|
|
236
|
+
scriptSig: string;
|
|
237
|
+
sequence: number;
|
|
238
|
+
error: string;
|
|
239
|
+
}[];
|
|
240
|
+
};
|
|
241
|
+
export type UnspentTxInfo = {
|
|
242
|
+
txid: string;
|
|
243
|
+
vout: number;
|
|
244
|
+
address: string;
|
|
245
|
+
account: string;
|
|
246
|
+
scriptPubKey: string;
|
|
247
|
+
amount: number;
|
|
248
|
+
confirmations: number;
|
|
249
|
+
redeemScript: string;
|
|
250
|
+
spendable: boolean;
|
|
251
|
+
solvable: boolean;
|
|
252
|
+
safe: boolean;
|
|
548
253
|
};
|
|
549
254
|
export type WalletTransaction = {
|
|
550
255
|
amount: number;
|
|
@@ -569,134 +274,17 @@ export type WalletTransaction = {
|
|
|
569
274
|
}[];
|
|
570
275
|
hex: string;
|
|
571
276
|
};
|
|
572
|
-
export type
|
|
573
|
-
|
|
574
|
-
walletversion: number;
|
|
575
|
-
balance: number;
|
|
576
|
-
unconfirmed_balance: number;
|
|
577
|
-
immature_balance: number;
|
|
578
|
-
txcount: number;
|
|
579
|
-
keypoololdest: number;
|
|
580
|
-
keypoolsize: number;
|
|
581
|
-
paytxfee: number;
|
|
582
|
-
hdmasterkeyid: string;
|
|
583
|
-
};
|
|
584
|
-
export type scriptPubkeyType = string;
|
|
585
|
-
export type SigHashType = 'ALL' | 'NONE' | 'SINGLE' | 'ALL|ANYONECANPAY' | 'NONE|ANYONECANPAY' | 'SINGLE|ANYONECANPAY';
|
|
586
|
-
export type SignedRawTx = {
|
|
587
|
-
hex: string;
|
|
588
|
-
complete: boolean;
|
|
589
|
-
errors?: {
|
|
590
|
-
txid: string;
|
|
591
|
-
vout: number;
|
|
592
|
-
scriptSig: string;
|
|
593
|
-
sequence: number;
|
|
594
|
-
error: string;
|
|
595
|
-
}[];
|
|
596
|
-
};
|
|
597
|
-
export type ValidateAddressResult = {
|
|
598
|
-
isvalid: boolean;
|
|
599
|
-
address?: string;
|
|
600
|
-
scriptPubKey?: string;
|
|
601
|
-
ismine?: boolean;
|
|
602
|
-
iswatchonly?: boolean;
|
|
603
|
-
isscript?: boolean;
|
|
604
|
-
script?: string;
|
|
605
|
-
hex?: string;
|
|
606
|
-
addresses?: string[];
|
|
607
|
-
sigsrequired?: number;
|
|
608
|
-
pubkey?: string;
|
|
609
|
-
iscompressed?: boolean;
|
|
277
|
+
export type DerivedAddresses = Array<string>;
|
|
278
|
+
export type ListTransactionsParams = {
|
|
610
279
|
account?: string;
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
};
|
|
615
|
-
export type ImportMultiRequest = {
|
|
616
|
-
scriptPubKey: string | {
|
|
617
|
-
address: string;
|
|
618
|
-
};
|
|
619
|
-
timestamp: number | 'now';
|
|
620
|
-
redeemScript?: string;
|
|
621
|
-
pubkeys?: string[];
|
|
622
|
-
keys?: string[];
|
|
623
|
-
internal?: boolean;
|
|
624
|
-
watchonly?: boolean;
|
|
625
|
-
label?: string;
|
|
626
|
-
};
|
|
627
|
-
export type ImportMultiResult = {
|
|
628
|
-
success: boolean;
|
|
629
|
-
error?: {
|
|
630
|
-
code: string;
|
|
631
|
-
message: string;
|
|
632
|
-
};
|
|
633
|
-
};
|
|
634
|
-
export type ImportMultiOptions = {
|
|
635
|
-
rescan?: boolean;
|
|
636
|
-
};
|
|
637
|
-
export type ImportDescriptorRequest = {
|
|
638
|
-
/** (string, required) Descriptor to import. */
|
|
639
|
-
desc: string;
|
|
640
|
-
/**
|
|
641
|
-
* (integer / string, required) Time from which to start rescanning the blockchain for this descriptor, in UNIX epoch time
|
|
642
|
-
* Use the string "now" to substitute the current synced blockchain time.
|
|
643
|
-
* "now" can be specified to bypass scanning, for outputs which are known to never have been used, and
|
|
644
|
-
* 0 can be specified to scan the entire blockchain. Blocks up to 2 hours before the earliest timestamp
|
|
645
|
-
* of all descriptors being imported will be scanned as well as the mempool.
|
|
646
|
-
*/
|
|
647
|
-
timestamp: number | string;
|
|
648
|
-
/** (boolean, optional, default=false) Make descriptor "active" for corresponding output type/externality */
|
|
649
|
-
active?: boolean;
|
|
650
|
-
/** (numeric or array, optional) If a ranged descriptor is used, this specifies the end or the range (in the form [begin,end]) to import */
|
|
651
|
-
range?: number | Array<number>;
|
|
652
|
-
/** (numeric, optional) If a ranged descriptor is set to active, this specifies the next index to generate addresses from */
|
|
653
|
-
next_index?: number;
|
|
654
|
-
/** (boolean, optional, default=false) Whether matching outputs should be treated as not incoming payments (e.g. change) */
|
|
655
|
-
internal?: boolean;
|
|
656
|
-
/** (string, optional, default="") Label to assign to the address, only allowed with internal=false. Disabled for ranged descriptors */
|
|
657
|
-
label?: string;
|
|
658
|
-
};
|
|
659
|
-
export type JsonRPCError = {
|
|
660
|
-
code: number;
|
|
661
|
-
message: string;
|
|
662
|
-
};
|
|
663
|
-
export type ImportDescriptorResult = {
|
|
664
|
-
success: boolean;
|
|
665
|
-
warnings?: string;
|
|
666
|
-
error: JsonRPCError;
|
|
667
|
-
};
|
|
668
|
-
export type Received = {
|
|
669
|
-
involvesWatchonly?: boolean;
|
|
670
|
-
account: string;
|
|
671
|
-
amount: number;
|
|
672
|
-
confirmations: number;
|
|
673
|
-
label: string;
|
|
674
|
-
};
|
|
675
|
-
export type ListUnspentOptions = {
|
|
676
|
-
minimumAmount: number | string;
|
|
677
|
-
maximumAmount: number | string;
|
|
678
|
-
maximumCount: number | string;
|
|
679
|
-
minimumSumAmount: number | string;
|
|
680
|
-
};
|
|
681
|
-
export type ReceivedByAccount = Received;
|
|
682
|
-
export type ReceivedByAddress = {
|
|
683
|
-
address: string;
|
|
684
|
-
txids: string[];
|
|
685
|
-
} & Received;
|
|
686
|
-
export type RestExtension = 'json' | 'bin' | 'hex';
|
|
687
|
-
export type MethodNameInLowerCase = 'getbestblockhash' | 'getblock' | 'getblockchaininfo' | 'getblockcount' | 'getblockhash' | 'getblockheader' | 'getchaintips' | 'getchaintxstats' | 'getdifficulty' | 'getmempoolancestors' | 'getmempooldescendants' | 'getmempoolentry' | 'getmempoolinfo' | 'getrawmempool' | 'gettxout' | 'gettxoutproof' | 'gettxoutsetinfo' | 'preciousblock' | 'pruneblockchain' | 'verifychain' | 'verifytxoutproof' | 'getinfo' | 'getmemoryinfo' | 'help' | 'stop' | 'uptime' | 'generate' | 'generatetoaddress' | 'getblocktemplate' | 'getmininginfo' | 'getnetworkhashps' | 'prioritisetransaction' | 'submitblock' | 'addnode' | 'clearbanned' | 'disconnectnode' | 'getaddednodeinfo' | 'getconnectioncount' | 'getnettotals' | 'getnetworkinfo' | 'getpeerinfo' | 'istbanned' | 'ping' | 'setban' | 'setnetworkactive' | 'combinerawtransaction' | 'createrawtransaction' | 'createwallet' | 'decoderawtransaction' | 'decodescript' | 'fundrawtransaction' | 'getrawtransaction' | 'sendrawtransaction' | 'signrawtransaction' | 'createmultisig' | 'estimatefee' | 'estimatesmartfee' | 'signmessagewithprivkey' | 'validateaddress' | 'verifymessage' | 'abandontransaction' | 'abortrescan' | 'addmultisigaddress' | 'addwitnessaddress' | 'backupwallet' | 'bumpfee' | 'dumpprivkey' | 'dumpwallet' | 'encryptwallet' | 'getaccount' | 'getaccountaddress' | 'getaddressesbyaccount' | 'getbalance' | 'getnewaddress' | 'getrawchangeaddress' | 'getreceivedbyaccount' | 'getreceivedbyaddress' | 'gettransaction' | 'getunconfirmedbalance' | 'getwalletinfo' | 'importaddress' | 'importmulti' | 'importprivkey' | 'importprunedfunds' | 'importpubkey' | 'importwallet' | 'keypoolrefill' | 'listaccounts' | 'listaddressgroupings' | 'listlockunspent' | 'listreceivedbyaccount' | 'listreceivedbyaddress' | 'listsinceblock' | 'listtransactions' | 'listunspent' | 'listwallets' | 'lockunspent' | 'move' | 'removeprunedfunds' | 'sendfrom' | 'sendmany' | 'sendtoaddress' | 'setaccount' | 'settxfee' | 'signmessage' | 'scanblocks' | 'getdescriptorinfo' | 'deriveaddresses' | 'importdescriptors' | 'createwalletdescriptor' | 'signrawtransactionwithwallet' | 'send' | 'sendmany' | 'sendall';
|
|
688
|
-
export type BatchOption = {
|
|
689
|
-
method: MethodNameInLowerCase;
|
|
690
|
-
parameters?: Array<any>;
|
|
691
|
-
};
|
|
692
|
-
export type ReturnType<T> = T extends (...args: any[]) => infer R ? R : any;
|
|
693
|
-
export type BumpFeeOption = {
|
|
694
|
-
confTarget?: number;
|
|
695
|
-
totalFee?: number;
|
|
696
|
-
replaceable?: boolean;
|
|
697
|
-
estimate_mode?: FeeEstimateMode;
|
|
280
|
+
count?: number;
|
|
281
|
+
skip?: number;
|
|
282
|
+
include_watchonly?: boolean;
|
|
698
283
|
};
|
|
699
|
-
export type
|
|
284
|
+
export type ListTransactionsResult = {
|
|
285
|
+
trusted: boolean;
|
|
286
|
+
otheraccount?: string;
|
|
287
|
+
abandoned?: boolean;
|
|
700
288
|
account: string;
|
|
701
289
|
address: string;
|
|
702
290
|
category: 'send' | 'receive';
|
|
@@ -712,211 +300,25 @@ export type WalletTxBase = {
|
|
|
712
300
|
timereceived: number;
|
|
713
301
|
walletconflicts: string[];
|
|
714
302
|
'bip125-replaceable': 'yes' | 'no' | 'unknown';
|
|
715
|
-
abandoned?: boolean;
|
|
716
|
-
comment?: string;
|
|
717
303
|
label: string;
|
|
718
|
-
to?: string;
|
|
719
|
-
};
|
|
720
|
-
export type TransactionInListSinceBlock = WalletTxBase;
|
|
721
|
-
export type ListSinceBlockResult = {
|
|
722
|
-
transactions: TransactionInListSinceBlock[];
|
|
723
|
-
removed?: TransactionInListSinceBlock[];
|
|
724
|
-
lastblock: string;
|
|
725
|
-
};
|
|
726
|
-
export type ListTransactionsResult = {
|
|
727
|
-
trusted: boolean;
|
|
728
|
-
otheraccount?: string;
|
|
729
|
-
abandoned?: boolean;
|
|
730
|
-
} & WalletTxBase;
|
|
731
|
-
export type AddressGrouping = [string, number] | [string, number, string];
|
|
732
|
-
export type RawOutputAddr = {
|
|
733
|
-
[address: string]: number;
|
|
734
|
-
};
|
|
735
|
-
export type RawOutputData = {
|
|
736
|
-
data: string;
|
|
737
|
-
};
|
|
738
|
-
export type CreateRawTxOutputs = RawOutputAddr | RawOutputData;
|
|
739
|
-
export type GetUTXOsResult = {
|
|
740
|
-
chainHeight: number;
|
|
741
|
-
chaintipHash: string;
|
|
742
|
-
bipmap: string;
|
|
743
|
-
utxos: UTXO[];
|
|
744
|
-
};
|
|
745
|
-
export type BumpFeeOptions = {
|
|
746
|
-
confTarget?: number;
|
|
747
|
-
totalFee?: number;
|
|
748
|
-
replaceable?: boolean;
|
|
749
|
-
estimate_mode?: FeeEstimateMode;
|
|
750
|
-
};
|
|
751
|
-
export type BumpFeeResult = {
|
|
752
|
-
txid: string;
|
|
753
|
-
origfee: number;
|
|
754
|
-
fee: number;
|
|
755
|
-
error?: string[];
|
|
756
|
-
};
|
|
757
|
-
export type AddMultiSigAddressParams = {
|
|
758
|
-
nrequired: number;
|
|
759
|
-
keys: string[];
|
|
760
|
-
account?: string;
|
|
761
|
-
};
|
|
762
|
-
export type SignRawTxParams = {
|
|
763
|
-
hexstring: string;
|
|
764
|
-
prevtxs?: PrevOut[];
|
|
765
|
-
privkeys?: string[];
|
|
766
|
-
sighashtype?: SigHashType;
|
|
767
|
-
};
|
|
768
|
-
export type BitcoinSignature = {
|
|
769
|
-
signature: string;
|
|
770
|
-
};
|
|
771
|
-
export type CreateMultiSigResult = {
|
|
772
|
-
address: string;
|
|
773
|
-
redeemScript: string;
|
|
774
|
-
};
|
|
775
|
-
export type CreateRawTxParams = {
|
|
776
|
-
inputs: CreateRawTxInputs[];
|
|
777
|
-
outputs: CreateRawTxOutputs[];
|
|
778
|
-
locktime?: number;
|
|
779
|
-
replacable?: boolean;
|
|
780
|
-
};
|
|
781
|
-
export type CreateWalletParams = {
|
|
782
|
-
wallet_name: string;
|
|
783
|
-
disable_private_keys?: boolean;
|
|
784
|
-
blank?: boolean;
|
|
785
|
-
passphrase?: string;
|
|
786
|
-
avoid_reuse?: boolean;
|
|
787
|
-
descriptors?: boolean;
|
|
788
|
-
load_on_startup?: boolean;
|
|
789
|
-
};
|
|
790
|
-
export type CreateWalletResult = {
|
|
791
|
-
name: string;
|
|
792
|
-
warning: string;
|
|
793
|
-
};
|
|
794
|
-
export type ScanBlocksParams = {
|
|
795
|
-
action: 'start' | 'abort' | 'status';
|
|
796
|
-
start_height?: number;
|
|
797
|
-
stop_height?: number;
|
|
798
|
-
filtertype?: string;
|
|
799
|
-
options?: {
|
|
800
|
-
filter_false_positives: boolean;
|
|
801
|
-
};
|
|
802
|
-
};
|
|
803
|
-
export type ListTransactionsParams = {
|
|
804
|
-
account?: string;
|
|
805
|
-
count?: number;
|
|
806
|
-
skip?: number;
|
|
807
|
-
include_watchonly?: boolean;
|
|
808
|
-
};
|
|
809
|
-
export type FundRawTxResult = {
|
|
810
|
-
hex: string;
|
|
811
|
-
fee: number;
|
|
812
|
-
changepos: number;
|
|
813
|
-
};
|
|
814
|
-
export type DerivedAddresses = Array<string>;
|
|
815
|
-
export type CreateWalletDescriptorOptions = {
|
|
816
|
-
internal: boolean;
|
|
817
|
-
hdkey: string;
|
|
818
|
-
};
|
|
819
|
-
export type WalletDescriptor = string;
|
|
820
|
-
export type CreateWalletDescriptorsResult = {
|
|
821
|
-
descs: Array<WalletDescriptor>;
|
|
822
|
-
};
|
|
823
|
-
export type SendManyParams = {
|
|
824
|
-
fromaccount: string;
|
|
825
|
-
amounts: {
|
|
826
|
-
address: string;
|
|
827
|
-
};
|
|
828
|
-
minconf?: number;
|
|
829
|
-
comment?: string;
|
|
830
|
-
subtractfeefrom?: string[];
|
|
831
|
-
replaeable?: boolean;
|
|
832
|
-
conf_target?: number;
|
|
833
|
-
estimate_mode?: FeeEstimateMode;
|
|
834
|
-
};
|
|
835
|
-
export type ListUnspentParams = {
|
|
836
|
-
minconf?: number;
|
|
837
|
-
maxconf?: number;
|
|
838
|
-
address?: string[];
|
|
839
|
-
include_unsafe?: boolean;
|
|
840
|
-
query_options?: ListUnspentOptions;
|
|
841
|
-
};
|
|
842
|
-
export type BitcoinRecipient = string | Record<string, number | string>;
|
|
843
|
-
export type Input = {
|
|
844
|
-
txid: string;
|
|
845
|
-
vout: number;
|
|
846
|
-
sequence?: number;
|
|
847
|
-
};
|
|
848
|
-
export type SolvingData = {
|
|
849
|
-
pubkeys: string[];
|
|
850
|
-
scripts: string[];
|
|
851
|
-
descriptors: string[];
|
|
852
|
-
};
|
|
853
|
-
export type Recipients = Array<BitcoinRecipient>;
|
|
854
|
-
export type SendAllOptions = {
|
|
855
|
-
add_to_wallet?: boolean;
|
|
856
|
-
fee_rate?: number | string;
|
|
857
|
-
include_watching?: boolean;
|
|
858
|
-
inputs?: Input[];
|
|
859
|
-
locktime?: number;
|
|
860
|
-
lock_unspents?: boolean;
|
|
861
|
-
psbt?: boolean;
|
|
862
|
-
send_max?: boolean;
|
|
863
|
-
minconf?: number;
|
|
864
|
-
maxconf?: number;
|
|
865
|
-
conf_target?: number;
|
|
866
|
-
estimate_mode?: FeeEstimateMode;
|
|
867
|
-
replaceable?: boolean;
|
|
868
|
-
solving_data?: SolvingData;
|
|
869
|
-
};
|
|
870
|
-
export type SendAllParams = {
|
|
871
|
-
recipients: Recipients;
|
|
872
|
-
options?: SendAllOptions;
|
|
873
|
-
};
|
|
874
|
-
export type SendAllResult = {
|
|
875
|
-
txid: Hex;
|
|
876
|
-
hex: Hex;
|
|
877
|
-
psbt: string;
|
|
878
|
-
complete: boolean;
|
|
879
|
-
};
|
|
880
|
-
export type SendToAddressResult = {
|
|
881
|
-
txid: string;
|
|
882
|
-
fee_reason?: string;
|
|
883
|
-
};
|
|
884
|
-
export type CreateMultisigParams = {
|
|
885
|
-
nrequired: number;
|
|
886
|
-
keys: string[];
|
|
887
|
-
address_type?: string;
|
|
888
|
-
};
|
|
889
|
-
export type CreateMultisigResult = {
|
|
890
|
-
address: string;
|
|
891
|
-
redeemScript: Hex;
|
|
892
|
-
descriptor: string;
|
|
893
|
-
warnings?: string[];
|
|
894
304
|
};
|
|
895
305
|
/**
|
|
896
306
|
* Defines verbosity levels for block and transaction outputs.
|
|
897
|
-
*
|
|
898
|
-
* @enum {number} VerbosityLevel for block and transaction outputs.
|
|
307
|
+
* @enum {number}
|
|
899
308
|
*/
|
|
900
309
|
export declare enum VerbosityLevel {
|
|
901
|
-
/** Return
|
|
310
|
+
/** Return data in raw hex-encoded format */
|
|
902
311
|
hex = 0,
|
|
903
|
-
/** Return
|
|
312
|
+
/** Return data in JSON object format */
|
|
904
313
|
json = 1,
|
|
905
|
-
/**
|
|
906
|
-
* Return block or transaction data in JSON object format with additional information.
|
|
907
|
-
* Returns block data with information about each transaction.
|
|
908
|
-
* Returns transaction data with information about the transaction including fee and prevout information.
|
|
909
|
-
*/
|
|
314
|
+
/** Return data in JSON format with additional information */
|
|
910
315
|
jsonext = 2,
|
|
911
|
-
/**
|
|
912
|
-
* Return block data in JSON object format with additional information.
|
|
913
|
-
* Returns block data with information about each transaction, including prevout information for inputs.
|
|
914
|
-
*/
|
|
316
|
+
/** Return block data in JSON format with prevout information for inputs */
|
|
915
317
|
jsonextprev = 3
|
|
916
318
|
}
|
|
917
|
-
export type BlockHeight = number;
|
|
918
319
|
export interface GetBlockParams {
|
|
919
320
|
blockhash?: string;
|
|
920
321
|
height?: number;
|
|
921
322
|
verbosity?: VerbosityLevel;
|
|
922
323
|
}
|
|
324
|
+
export type MethodNameInLowerCase = 'getbestblockhash' | 'getblock' | 'getblockchaininfo' | 'getblockcount' | 'getblockhash' | 'getblockheader' | 'getchaintips' | 'getchaintxstats' | 'getdifficulty' | 'getmempoolancestors' | 'getmempooldescendants' | 'getmempoolentry' | 'getmempoolinfo' | 'getrawmempool' | 'gettxout' | 'gettxoutproof' | 'gettxoutsetinfo' | 'preciousblock' | 'pruneblockchain' | 'verifychain' | 'verifytxoutproof' | 'getinfo' | 'getmemoryinfo' | 'help' | 'stop' | 'uptime' | 'generate' | 'generatetoaddress' | 'getblocktemplate' | 'getmininginfo' | 'getnetworkhashps' | 'prioritisetransaction' | 'submitblock' | 'addnode' | 'clearbanned' | 'disconnectnode' | 'getaddednodeinfo' | 'getconnectioncount' | 'getnettotals' | 'getnetworkinfo' | 'getpeerinfo' | 'istbanned' | 'ping' | 'setban' | 'setnetworkactive' | 'combinerawtransaction' | 'createrawtransaction' | 'createwallet' | 'decoderawtransaction' | 'decodescript' | 'fundrawtransaction' | 'getrawtransaction' | 'sendrawtransaction' | 'signrawtransaction' | 'createmultisig' | 'estimatefee' | 'estimatesmartfee' | 'signmessagewithprivkey' | 'validateaddress' | 'verifymessage' | 'abandontransaction' | 'abortrescan' | 'addmultisigaddress' | 'addwitnessaddress' | 'backupwallet' | 'bumpfee' | 'dumpprivkey' | 'dumpwallet' | 'encryptwallet' | 'getaccount' | 'getaccountaddress' | 'getaddressesbyaccount' | 'getbalance' | 'getnewaddress' | 'getrawchangeaddress' | 'getreceivedbyaccount' | 'getreceivedbyaddress' | 'gettransaction' | 'getunconfirmedbalance' | 'getwalletinfo' | 'importaddress' | 'importmulti' | 'importprivkey' | 'importprunedfunds' | 'importpubkey' | 'importwallet' | 'keypoolrefill' | 'listaccounts' | 'listaddressgroupings' | 'listlockunspent' | 'listreceivedbyaccount' | 'listreceivedbyaddress' | 'listsinceblock' | 'listtransactions' | 'listunspent' | 'listwallets' | 'lockunspent' | 'move' | 'removeprunedfunds' | 'sendfrom' | 'sendmany' | 'sendtoaddress' | 'setaccount' | 'settxfee' | 'signmessage' | 'scanblocks' | 'getdescriptorinfo' | 'deriveaddresses' | 'importdescriptors' | 'createwalletdescriptor' | 'signrawtransactionwithwallet' | 'send' | 'sendall';
|