@mr-zwets/bchn-api-wrapper 1.0.1 → 1.0.2
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/.claude/settings.local.json +8 -0
- package/.github/workflows/ci.yaml +36 -0
- package/CLAUDE.md +70 -0
- package/README.md +121 -129
- package/dist/interfaces/interfaces.d.ts +13 -0
- package/dist/interfaces/restInterfaces/interfaces.d.ts +124 -18
- package/dist/interfaces/rpcInterfaces/blockchain.d.ts +293 -102
- package/dist/interfaces/rpcInterfaces/control.d.ts +6 -0
- package/dist/interfaces/rpcInterfaces/generating.d.ts +2 -0
- package/dist/interfaces/rpcInterfaces/mining.d.ts +9 -0
- package/dist/interfaces/rpcInterfaces/network.d.ts +18 -0
- package/dist/interfaces/rpcInterfaces/rawtransactions.d.ts +21 -0
- package/dist/interfaces/rpcInterfaces/util.d.ts +5 -0
- package/dist/interfaces/rpcInterfaces/wallet.d.ts +54 -0
- package/dist/interfaces/rpcInterfaces/zmq.d.ts +1 -0
- package/dist/restClient.d.ts +13 -1
- package/dist/restClient.js +19 -6
- package/dist/rpcClient.d.ts +7 -0
- package/dist/rpcClient.js +7 -0
- package/package.json +7 -8
- package/pnpm-lock.yaml +1279 -0
- package/src/index.ts +3 -3
- package/src/interfaces/interfaces.ts +96 -86
- package/src/interfaces/restInterfaces/interfaces.ts +235 -116
- package/src/interfaces/rpcInterfaces/blockchain.ts +932 -758
- package/src/interfaces/rpcInterfaces/control.ts +68 -62
- package/src/interfaces/rpcInterfaces/generating.ts +23 -21
- package/src/interfaces/rpcInterfaces/index.ts +13 -13
- package/src/interfaces/rpcInterfaces/mining.ts +151 -143
- package/src/interfaces/rpcInterfaces/network.ts +213 -195
- package/src/interfaces/rpcInterfaces/rawtransactions.ts +332 -314
- package/src/interfaces/rpcInterfaces/util.ts +56 -52
- package/src/interfaces/rpcInterfaces/wallet.ts +728 -674
- package/src/interfaces/rpcInterfaces/zmq.ts +12 -11
- package/src/restClient.ts +134 -119
- package/src/rpcClient.ts +100 -93
- package/src/utils/errors.ts +6 -6
- package/src/utils/utils.ts +55 -55
- package/test/restClient.test.ts +33 -31
- package/test/rpcClient.test.ts +119 -115
- package/test/setupTests.ts +56 -54
- package/test/tsconfig.json +4 -4
- package/tsconfig.json +13 -13
- package/vitest.config.ts +8 -8
- package/CHANGELOG.md +0 -7
|
@@ -1,674 +1,728 @@
|
|
|
1
|
-
/* --- Wallet Commands --- */
|
|
2
|
-
// progress 52/52
|
|
3
|
-
|
|
4
|
-
import type { TokenData } from "../interfaces.js";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
export interface
|
|
81
|
-
method: '
|
|
82
|
-
params: [
|
|
83
|
-
|
|
84
|
-
];
|
|
85
|
-
response:
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
}
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
}
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
}
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
export interface
|
|
446
|
-
method: '
|
|
447
|
-
params: [
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
}
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
export interface
|
|
493
|
-
method: '
|
|
494
|
-
params: [
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
}
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
},
|
|
629
|
-
|
|
630
|
-
];
|
|
631
|
-
response: {
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
}
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
];
|
|
650
|
-
response: null;
|
|
651
|
-
}
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
1
|
+
/* --- Wallet Commands --- */
|
|
2
|
+
// progress 52/52
|
|
3
|
+
|
|
4
|
+
import type { TokenData } from "../interfaces.js";
|
|
5
|
+
|
|
6
|
+
/** Marks an in-wallet transaction as abandoned (only works on unconfirmed tx). */
|
|
7
|
+
export interface AbandonTransaction {
|
|
8
|
+
method: 'abandontransaction';
|
|
9
|
+
params: [
|
|
10
|
+
txid: string
|
|
11
|
+
];
|
|
12
|
+
response: null;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/** Stops current wallet rescan. */
|
|
16
|
+
export interface AbortRescan {
|
|
17
|
+
method: 'abortrescan';
|
|
18
|
+
params: [];
|
|
19
|
+
response: null;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/** Adds a multisig address to the wallet. */
|
|
23
|
+
export interface AddMultisigAddress {
|
|
24
|
+
method: 'addmultisigaddress';
|
|
25
|
+
params: [
|
|
26
|
+
nrequired: number,
|
|
27
|
+
keys: string[],
|
|
28
|
+
label?: string
|
|
29
|
+
];
|
|
30
|
+
response: {
|
|
31
|
+
address: string;
|
|
32
|
+
redeemScript: string;
|
|
33
|
+
};
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/** Backs up wallet to specified file. */
|
|
37
|
+
export interface BackupWallet {
|
|
38
|
+
method: 'backupwallet';
|
|
39
|
+
params: [
|
|
40
|
+
destination: string
|
|
41
|
+
];
|
|
42
|
+
response: null;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/** Creates a new wallet. */
|
|
46
|
+
export interface CreateWallet {
|
|
47
|
+
method: 'createwallet';
|
|
48
|
+
params: [
|
|
49
|
+
wallet_name: string,
|
|
50
|
+
disable_private_keys?: boolean,
|
|
51
|
+
blank?: boolean
|
|
52
|
+
];
|
|
53
|
+
response: {
|
|
54
|
+
name: string;
|
|
55
|
+
warning?: string;
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/** Dumps all wallet keys to a file. */
|
|
60
|
+
export interface DumpWallet {
|
|
61
|
+
method: 'dumpwallet';
|
|
62
|
+
params: [
|
|
63
|
+
filename: string
|
|
64
|
+
];
|
|
65
|
+
response: {
|
|
66
|
+
filename: string;
|
|
67
|
+
};
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
/** Returns private key for an address. */
|
|
71
|
+
export interface DumpPrivKey {
|
|
72
|
+
method: 'dumpprivkey';
|
|
73
|
+
params: [
|
|
74
|
+
address: string,
|
|
75
|
+
];
|
|
76
|
+
response: string;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
/** Encrypts wallet with passphrase (requires restart). */
|
|
80
|
+
export interface EncryptWallet {
|
|
81
|
+
method: 'encryptwallet';
|
|
82
|
+
params: [
|
|
83
|
+
passphrase: string
|
|
84
|
+
];
|
|
85
|
+
response: string;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
/** Returns addresses assigned to a label. */
|
|
89
|
+
export interface GetAddressesByLabel {
|
|
90
|
+
method: 'getaddressesbylabel';
|
|
91
|
+
params: [
|
|
92
|
+
label: string
|
|
93
|
+
];
|
|
94
|
+
response: {
|
|
95
|
+
[address: string]: {
|
|
96
|
+
purpose: string;
|
|
97
|
+
};
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/** Returns detailed information about an address. */
|
|
102
|
+
export interface GetAddressInfo {
|
|
103
|
+
method: 'getaddressinfo';
|
|
104
|
+
params: [string];
|
|
105
|
+
response: {
|
|
106
|
+
address: string;
|
|
107
|
+
scriptPubKey: string;
|
|
108
|
+
ismine: boolean;
|
|
109
|
+
iswatchonly: boolean;
|
|
110
|
+
isscript: boolean;
|
|
111
|
+
ischange: boolean;
|
|
112
|
+
script?: 'nonstandard' | 'pubkey' | 'pubkeyhash' | 'scripthash' | 'multisig' | 'nulldata';
|
|
113
|
+
hex?: string;
|
|
114
|
+
pubkeys?: string[];
|
|
115
|
+
sigsrequired?: number;
|
|
116
|
+
pubkey?: string;
|
|
117
|
+
embedded?: object;
|
|
118
|
+
iscompressed: boolean;
|
|
119
|
+
label: string;
|
|
120
|
+
timestamp?: number;
|
|
121
|
+
hdkeypath?: string;
|
|
122
|
+
hdseedid?: string;
|
|
123
|
+
hdmasterkeyid?: string;
|
|
124
|
+
labels: {
|
|
125
|
+
name: string;
|
|
126
|
+
purpose: 'send' | 'receive';
|
|
127
|
+
}[];
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
/** Returns wallet balance. */
|
|
132
|
+
export interface GetBalance {
|
|
133
|
+
method: 'getbalance';
|
|
134
|
+
params: [
|
|
135
|
+
dummy?: string,
|
|
136
|
+
minconf?: number,
|
|
137
|
+
include_watchonly?: boolean
|
|
138
|
+
];
|
|
139
|
+
response: number;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
/** Generates a new address for receiving payments. */
|
|
143
|
+
export interface GetNewAddress {
|
|
144
|
+
method: 'getnewaddress';
|
|
145
|
+
params: [
|
|
146
|
+
label?: string,
|
|
147
|
+
];
|
|
148
|
+
response: string;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
/** Returns a new address for receiving change. */
|
|
152
|
+
export interface GetRawChangeAddress {
|
|
153
|
+
method: 'getrawchangeaddress';
|
|
154
|
+
params: [];
|
|
155
|
+
response: string;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
/** Returns total amount received by an address. */
|
|
159
|
+
export interface GetReceivedByAddress {
|
|
160
|
+
method: 'getreceivedbyaddress';
|
|
161
|
+
params: [
|
|
162
|
+
address: string,
|
|
163
|
+
minconf?: number
|
|
164
|
+
];
|
|
165
|
+
response: number;
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
/** Returns total amount received by addresses with a label. */
|
|
169
|
+
export interface GetReceivedByLabel {
|
|
170
|
+
method: 'getreceivedbylabel';
|
|
171
|
+
params: [
|
|
172
|
+
label: string,
|
|
173
|
+
minconf?: number
|
|
174
|
+
];
|
|
175
|
+
response: number;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
/** Returns detailed information about an in-wallet transaction. */
|
|
179
|
+
export interface GetTransaction {
|
|
180
|
+
method: 'gettransaction';
|
|
181
|
+
params: [
|
|
182
|
+
txid: string,
|
|
183
|
+
include_watchonly?: boolean
|
|
184
|
+
];
|
|
185
|
+
response: {
|
|
186
|
+
amount: number;
|
|
187
|
+
fee?: number;
|
|
188
|
+
confirmations: number;
|
|
189
|
+
blockhash?: string;
|
|
190
|
+
blockindex?: number;
|
|
191
|
+
blocktime?: number;
|
|
192
|
+
txid: string;
|
|
193
|
+
time: number;
|
|
194
|
+
timereceived: number;
|
|
195
|
+
'bip125-replaceable': 'yes' | 'no' | 'unknown';
|
|
196
|
+
details: {
|
|
197
|
+
address: string;
|
|
198
|
+
category: 'send' | 'receive';
|
|
199
|
+
amount: number;
|
|
200
|
+
label?: string;
|
|
201
|
+
vout: number;
|
|
202
|
+
fee?: number;
|
|
203
|
+
abandoned?: boolean;
|
|
204
|
+
}[];
|
|
205
|
+
hex: string;
|
|
206
|
+
};
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
/** Returns unconfirmed balance. */
|
|
210
|
+
export interface GetUnconfirmedBalance {
|
|
211
|
+
method: 'getunconfirmedbalance';
|
|
212
|
+
params: [];
|
|
213
|
+
response: number;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
/** Returns wallet state info. */
|
|
217
|
+
export interface GetWalletInfo {
|
|
218
|
+
method: 'getwalletinfo';
|
|
219
|
+
params: [];
|
|
220
|
+
response: {
|
|
221
|
+
walletname: string,
|
|
222
|
+
walletversion: number;
|
|
223
|
+
balance: number;
|
|
224
|
+
unconfirmed_balance: number;
|
|
225
|
+
immature_balance: number;
|
|
226
|
+
txcount: number;
|
|
227
|
+
keypoololdest: number;
|
|
228
|
+
keypoolsize: number;
|
|
229
|
+
keypoolsize_hd_internal: number;
|
|
230
|
+
unlocked_until: number;
|
|
231
|
+
paytxfee: number;
|
|
232
|
+
hdseedid?: string;
|
|
233
|
+
hdmasterkeyid?: string;
|
|
234
|
+
private_keys_enabled: boolean;
|
|
235
|
+
}
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
/** Imports an address or script for watching (without private key). */
|
|
239
|
+
export interface ImportAddress {
|
|
240
|
+
method: 'importaddress';
|
|
241
|
+
params: [
|
|
242
|
+
address: string,
|
|
243
|
+
label?: string,
|
|
244
|
+
rescan?: boolean,
|
|
245
|
+
p2sh?: boolean
|
|
246
|
+
];
|
|
247
|
+
response: number;
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
/** Imports multiple addresses/scripts/keys. */
|
|
251
|
+
export interface ImportMulti {
|
|
252
|
+
method: 'importmulti';
|
|
253
|
+
params: [
|
|
254
|
+
requests: {
|
|
255
|
+
scriptPubKey: string | { address: string };
|
|
256
|
+
timestamp: number | 'now';
|
|
257
|
+
redeemscript?: string;
|
|
258
|
+
pubkeys?: string[];
|
|
259
|
+
keys?: string[];
|
|
260
|
+
internal?: boolean;
|
|
261
|
+
watchonly?: boolean;
|
|
262
|
+
label?: string;
|
|
263
|
+
}[],
|
|
264
|
+
options?: {
|
|
265
|
+
rescan?: boolean;
|
|
266
|
+
}
|
|
267
|
+
];
|
|
268
|
+
response: {
|
|
269
|
+
success: boolean;
|
|
270
|
+
error?: {
|
|
271
|
+
code: number;
|
|
272
|
+
message: string;
|
|
273
|
+
};
|
|
274
|
+
}[];
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
/** Imports a private key. */
|
|
278
|
+
export interface ImportPrivKey {
|
|
279
|
+
method: 'importprivkey';
|
|
280
|
+
params: [
|
|
281
|
+
privkey: string,
|
|
282
|
+
label?: string,
|
|
283
|
+
rescan?: boolean
|
|
284
|
+
];
|
|
285
|
+
response: null;
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
/** Imports funds without rescan (requires merkle proof). */
|
|
289
|
+
export interface ImportPrunedFunds {
|
|
290
|
+
method: 'importprunedfunds';
|
|
291
|
+
params: [
|
|
292
|
+
rawtransaction: string,
|
|
293
|
+
txoutproof: string
|
|
294
|
+
];
|
|
295
|
+
response: null;
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
/** Imports a public key for watching. */
|
|
299
|
+
export interface ImportPubKey {
|
|
300
|
+
method: 'importpubkey';
|
|
301
|
+
params: [
|
|
302
|
+
pubkey: string,
|
|
303
|
+
label?: string,
|
|
304
|
+
rescan?: boolean
|
|
305
|
+
];
|
|
306
|
+
response: null;
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
/** Imports keys from a wallet dump file. */
|
|
310
|
+
export interface ImportWallet {
|
|
311
|
+
method: 'importwallet';
|
|
312
|
+
params: [
|
|
313
|
+
filename: string
|
|
314
|
+
];
|
|
315
|
+
response: null;
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
/** Refills the keypool. */
|
|
319
|
+
export interface KeyPoolRefill {
|
|
320
|
+
method: 'keypoolrefill';
|
|
321
|
+
params: [
|
|
322
|
+
newsize?: number
|
|
323
|
+
];
|
|
324
|
+
response: null;
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
/** Returns addresses grouped by common ownership. */
|
|
328
|
+
export interface ListAddressGroupings {
|
|
329
|
+
method: 'listaddressgroupings';
|
|
330
|
+
params: [];
|
|
331
|
+
response: [
|
|
332
|
+
[
|
|
333
|
+
{
|
|
334
|
+
address: string;
|
|
335
|
+
amount: number;
|
|
336
|
+
label?: string;
|
|
337
|
+
}[]
|
|
338
|
+
][]
|
|
339
|
+
];
|
|
340
|
+
}
|
|
341
|
+
|
|
342
|
+
/** Returns all labels in the wallet. */
|
|
343
|
+
export interface ListLabels {
|
|
344
|
+
method: 'listlabels';
|
|
345
|
+
params: [
|
|
346
|
+
purpose?: string
|
|
347
|
+
];
|
|
348
|
+
response: string[];
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
/** Returns list of locked unspent outputs. */
|
|
352
|
+
export interface ListLockUnspent {
|
|
353
|
+
method: 'listlockunspent';
|
|
354
|
+
params: [];
|
|
355
|
+
response: {
|
|
356
|
+
txid: string;
|
|
357
|
+
vout: number;
|
|
358
|
+
}[];
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
/** Lists transactions received by address. */
|
|
362
|
+
export interface ListReceivedByAddress {
|
|
363
|
+
method: 'listreceivedbyaddress';
|
|
364
|
+
params: [
|
|
365
|
+
minconf?: number,
|
|
366
|
+
include_empty?: boolean,
|
|
367
|
+
include_watchonly?: boolean,
|
|
368
|
+
address_filter?: string
|
|
369
|
+
];
|
|
370
|
+
response: {
|
|
371
|
+
involvesWatchonly?: boolean;
|
|
372
|
+
address: string;
|
|
373
|
+
amount: number;
|
|
374
|
+
confirmations: number;
|
|
375
|
+
label: string;
|
|
376
|
+
txids: string[];
|
|
377
|
+
}[];
|
|
378
|
+
}
|
|
379
|
+
|
|
380
|
+
/** Lists transactions received by label. */
|
|
381
|
+
export interface ListReceivedByLabel {
|
|
382
|
+
method: 'listreceivedbylabel';
|
|
383
|
+
params: [
|
|
384
|
+
minconf?: number,
|
|
385
|
+
include_empty?: boolean,
|
|
386
|
+
include_watchonly?: boolean
|
|
387
|
+
];
|
|
388
|
+
response: {
|
|
389
|
+
involvesWatchonly?: boolean;
|
|
390
|
+
amount: number;
|
|
391
|
+
confirmations: number;
|
|
392
|
+
label: string;
|
|
393
|
+
}[];
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
/** Wallet transaction representation. */
|
|
397
|
+
interface TransactionWallet {
|
|
398
|
+
address?: string;
|
|
399
|
+
category: 'send' | 'receive';
|
|
400
|
+
amount: number;
|
|
401
|
+
vout: number;
|
|
402
|
+
fee?: number;
|
|
403
|
+
confirmations: number;
|
|
404
|
+
blockhash?: string;
|
|
405
|
+
blockindex?: number;
|
|
406
|
+
blocktime?: number;
|
|
407
|
+
txid: string;
|
|
408
|
+
time: number;
|
|
409
|
+
timereceived: number;
|
|
410
|
+
abandoned?: boolean;
|
|
411
|
+
comment?: string;
|
|
412
|
+
label?: string;
|
|
413
|
+
to?: string;
|
|
414
|
+
}
|
|
415
|
+
|
|
416
|
+
/** Returns transactions since a block. */
|
|
417
|
+
export interface ListSinceBlock {
|
|
418
|
+
method: 'listsinceblock';
|
|
419
|
+
params: [
|
|
420
|
+
blockhash?: string,
|
|
421
|
+
target_confirmations?: number,
|
|
422
|
+
include_watchonly?: boolean,
|
|
423
|
+
include_removed?: boolean
|
|
424
|
+
];
|
|
425
|
+
response: {
|
|
426
|
+
transactions: TransactionWallet[];
|
|
427
|
+
removed?: TransactionWallet[];
|
|
428
|
+
lastblock: string;
|
|
429
|
+
};
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
/** Returns recent transactions for the wallet. */
|
|
433
|
+
export interface ListTransactions {
|
|
434
|
+
method: 'listtransactions';
|
|
435
|
+
params: [
|
|
436
|
+
label?: string,
|
|
437
|
+
count?: number,
|
|
438
|
+
skip?: number,
|
|
439
|
+
include_watchonly?: boolean
|
|
440
|
+
];
|
|
441
|
+
response: TransactionWallet[];
|
|
442
|
+
}
|
|
443
|
+
|
|
444
|
+
/** Returns unspent outputs in the wallet. */
|
|
445
|
+
export interface ListUnspent {
|
|
446
|
+
method: 'listunspent';
|
|
447
|
+
params: [
|
|
448
|
+
minconf?: number,
|
|
449
|
+
maxconf?: number,
|
|
450
|
+
addresses?: string[],
|
|
451
|
+
include_unsafe?: boolean,
|
|
452
|
+
query_options?: {
|
|
453
|
+
minimumAmount?: number | string;
|
|
454
|
+
maximumAmount?: number | string;
|
|
455
|
+
maximumCount?: number;
|
|
456
|
+
minimumSumAmount?: number | string;
|
|
457
|
+
includeTokens?: boolean;
|
|
458
|
+
tokensOnly?: boolean;
|
|
459
|
+
}
|
|
460
|
+
];
|
|
461
|
+
response: ListUnspentItem[];
|
|
462
|
+
}
|
|
463
|
+
|
|
464
|
+
/** Single UTXO from listunspent. */
|
|
465
|
+
export interface ListUnspentItem {
|
|
466
|
+
txid: string;
|
|
467
|
+
vout: number;
|
|
468
|
+
address: string;
|
|
469
|
+
label: string;
|
|
470
|
+
scriptPubKey: string;
|
|
471
|
+
amount: number;
|
|
472
|
+
tokenData?: TokenData;
|
|
473
|
+
confirmations: number;
|
|
474
|
+
redeemScript: string;
|
|
475
|
+
spendable: boolean;
|
|
476
|
+
solvable: boolean;
|
|
477
|
+
safe: boolean;
|
|
478
|
+
}
|
|
479
|
+
|
|
480
|
+
/** Returns list of available wallets. */
|
|
481
|
+
export interface ListWalletDir {
|
|
482
|
+
method: 'listwalletdir';
|
|
483
|
+
params: [];
|
|
484
|
+
response: {
|
|
485
|
+
wallets: {
|
|
486
|
+
name: string;
|
|
487
|
+
}[];
|
|
488
|
+
};
|
|
489
|
+
}
|
|
490
|
+
|
|
491
|
+
/** Returns list of loaded wallets. */
|
|
492
|
+
export interface ListWallets {
|
|
493
|
+
method: 'importaddress';
|
|
494
|
+
params: [];
|
|
495
|
+
response: string[];
|
|
496
|
+
}
|
|
497
|
+
|
|
498
|
+
/** Loads a wallet from file. */
|
|
499
|
+
export interface LoadWallet {
|
|
500
|
+
method: 'loadwallet';
|
|
501
|
+
params: [
|
|
502
|
+
filename: string
|
|
503
|
+
];
|
|
504
|
+
response: {
|
|
505
|
+
name: string;
|
|
506
|
+
warning?: string;
|
|
507
|
+
};
|
|
508
|
+
}
|
|
509
|
+
|
|
510
|
+
/** Locks or unlocks unspent outputs. */
|
|
511
|
+
export interface LockUnspent {
|
|
512
|
+
method: 'lockunspent';
|
|
513
|
+
params: [
|
|
514
|
+
unlock: boolean,
|
|
515
|
+
transactions?: {
|
|
516
|
+
txid: string;
|
|
517
|
+
vout: number;
|
|
518
|
+
}[]
|
|
519
|
+
];
|
|
520
|
+
response: boolean;
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
/** Removes imported pruned funds from wallet. */
|
|
524
|
+
export interface RemovePrunedFunds {
|
|
525
|
+
method: 'removeprunedfunds';
|
|
526
|
+
params: [
|
|
527
|
+
txid: string
|
|
528
|
+
];
|
|
529
|
+
response: null;
|
|
530
|
+
}
|
|
531
|
+
|
|
532
|
+
/** Rescans blockchain for wallet transactions. */
|
|
533
|
+
export interface RescanBlockchain {
|
|
534
|
+
method: 'rescanblockchain';
|
|
535
|
+
params: [
|
|
536
|
+
start_height?: number,
|
|
537
|
+
stop_height?: number
|
|
538
|
+
];
|
|
539
|
+
response: {
|
|
540
|
+
start_height: number;
|
|
541
|
+
stop_height: number;
|
|
542
|
+
};
|
|
543
|
+
}
|
|
544
|
+
|
|
545
|
+
/** Sends to multiple recipients. */
|
|
546
|
+
export interface SendMany {
|
|
547
|
+
method: 'sendmany';
|
|
548
|
+
params: [
|
|
549
|
+
dummy: string,
|
|
550
|
+
amounts: {
|
|
551
|
+
[address: string]: number | string
|
|
552
|
+
},
|
|
553
|
+
minconf?: number,
|
|
554
|
+
comment?: string,
|
|
555
|
+
subtractfeefrom?: string[],
|
|
556
|
+
coinsel?: number,
|
|
557
|
+
include_unsafe?: boolean
|
|
558
|
+
];
|
|
559
|
+
response: string;
|
|
560
|
+
}
|
|
561
|
+
|
|
562
|
+
/** Sends to a single address. */
|
|
563
|
+
export interface SendToAddress {
|
|
564
|
+
method: 'sendtoaddress';
|
|
565
|
+
params: [
|
|
566
|
+
address: string,
|
|
567
|
+
amount: number | string,
|
|
568
|
+
comment?: string,
|
|
569
|
+
comment_to?: string,
|
|
570
|
+
subtractfeefromamount?: boolean,
|
|
571
|
+
coinsel?: number,
|
|
572
|
+
include_unsafe?: boolean
|
|
573
|
+
];
|
|
574
|
+
response: string;
|
|
575
|
+
}
|
|
576
|
+
|
|
577
|
+
/** Sets the HD seed for the wallet. */
|
|
578
|
+
export interface SetHdSeed {
|
|
579
|
+
method: 'sethdseed';
|
|
580
|
+
params: [
|
|
581
|
+
newkeypool?: boolean,
|
|
582
|
+
seed?: string
|
|
583
|
+
];
|
|
584
|
+
response: null;
|
|
585
|
+
}
|
|
586
|
+
|
|
587
|
+
/** Sets the label for an address. */
|
|
588
|
+
export interface SetLabel {
|
|
589
|
+
method: 'setlabel';
|
|
590
|
+
params: [
|
|
591
|
+
address: string,
|
|
592
|
+
label: string
|
|
593
|
+
];
|
|
594
|
+
response: null;
|
|
595
|
+
}
|
|
596
|
+
|
|
597
|
+
/** Sets the transaction fee per kB. */
|
|
598
|
+
export interface SetTxFee {
|
|
599
|
+
method: 'settxfee';
|
|
600
|
+
params: [
|
|
601
|
+
amount: number | string
|
|
602
|
+
];
|
|
603
|
+
response: boolean;
|
|
604
|
+
}
|
|
605
|
+
|
|
606
|
+
/** Signs a message with an address's private key. */
|
|
607
|
+
export interface SignMessage {
|
|
608
|
+
method: 'signmessage';
|
|
609
|
+
params: [
|
|
610
|
+
address: string,
|
|
611
|
+
message: string
|
|
612
|
+
];
|
|
613
|
+
response: string;
|
|
614
|
+
}
|
|
615
|
+
|
|
616
|
+
/** Signs a raw transaction with wallet keys. */
|
|
617
|
+
export interface SignRawTransactionWithWallet {
|
|
618
|
+
method: 'signrawtransactionwithwallet';
|
|
619
|
+
params: [
|
|
620
|
+
hexstring: string,
|
|
621
|
+
prevtxs?: {
|
|
622
|
+
txid: string;
|
|
623
|
+
vout: number;
|
|
624
|
+
scriptPubKey: string;
|
|
625
|
+
redeemScript?: string;
|
|
626
|
+
amount: number | string;
|
|
627
|
+
tokenData?: TokenData
|
|
628
|
+
}[],
|
|
629
|
+
sighashtype?: string
|
|
630
|
+
];
|
|
631
|
+
response: {
|
|
632
|
+
hex: string;
|
|
633
|
+
complete: boolean;
|
|
634
|
+
errors?: {
|
|
635
|
+
txid: string;
|
|
636
|
+
vout: number;
|
|
637
|
+
scriptSig: string;
|
|
638
|
+
sequence: number;
|
|
639
|
+
error: string;
|
|
640
|
+
}[];
|
|
641
|
+
};
|
|
642
|
+
}
|
|
643
|
+
|
|
644
|
+
/** Unloads a wallet. */
|
|
645
|
+
export interface UnloadWallet {
|
|
646
|
+
method: 'unloadwallet';
|
|
647
|
+
params: [
|
|
648
|
+
wallet_name?: string
|
|
649
|
+
];
|
|
650
|
+
response: null;
|
|
651
|
+
}
|
|
652
|
+
|
|
653
|
+
/** Creates and funds a PSBT. */
|
|
654
|
+
export interface WalletCreateFundedPsbt {
|
|
655
|
+
method: 'walletcreatefundedpsbt';
|
|
656
|
+
params: [
|
|
657
|
+
inputs: {
|
|
658
|
+
txid: string;
|
|
659
|
+
vout: number;
|
|
660
|
+
sequence: number;
|
|
661
|
+
}[],
|
|
662
|
+
outputs: {
|
|
663
|
+
address?: number | string | {
|
|
664
|
+
amount: number | string;
|
|
665
|
+
tokenData?: TokenData;
|
|
666
|
+
};
|
|
667
|
+
data?: string | string[];
|
|
668
|
+
}[],
|
|
669
|
+
locktime?: number,
|
|
670
|
+
options?: {
|
|
671
|
+
include_unsafe?: boolean;
|
|
672
|
+
changeAddress?: string;
|
|
673
|
+
changePosition?: number;
|
|
674
|
+
includeWatching?: boolean;
|
|
675
|
+
lockUnspents?: boolean;
|
|
676
|
+
feeRate?: number | string;
|
|
677
|
+
subtractFeeFromOutputs?: number[];
|
|
678
|
+
},
|
|
679
|
+
bip32derivs?: boolean
|
|
680
|
+
];
|
|
681
|
+
response: {
|
|
682
|
+
psbt: string;
|
|
683
|
+
fee: number;
|
|
684
|
+
changepos: number;
|
|
685
|
+
};
|
|
686
|
+
}
|
|
687
|
+
|
|
688
|
+
/** Locks the encrypted wallet. */
|
|
689
|
+
export interface WalletLock {
|
|
690
|
+
method: 'walletlock';
|
|
691
|
+
params: [];
|
|
692
|
+
response: null;
|
|
693
|
+
}
|
|
694
|
+
|
|
695
|
+
/** Unlocks the wallet for a specified time. */
|
|
696
|
+
export interface WalletPassphrase {
|
|
697
|
+
method: 'walletpassphrase';
|
|
698
|
+
params: [
|
|
699
|
+
passphrase: string,
|
|
700
|
+
timeout: number
|
|
701
|
+
];
|
|
702
|
+
response: null;
|
|
703
|
+
}
|
|
704
|
+
|
|
705
|
+
/** Changes the wallet passphrase. */
|
|
706
|
+
export interface WalletPassphraseChange {
|
|
707
|
+
method: 'walletpassphrasechange';
|
|
708
|
+
params: [
|
|
709
|
+
oldpassphrase: string,
|
|
710
|
+
newpassphrase: string
|
|
711
|
+
];
|
|
712
|
+
response: null;
|
|
713
|
+
}
|
|
714
|
+
|
|
715
|
+
/** Processes a PSBT with wallet data. */
|
|
716
|
+
export interface WalletProcessPsbt {
|
|
717
|
+
method: 'walletprocesspsbt';
|
|
718
|
+
params: [
|
|
719
|
+
psbt: string,
|
|
720
|
+
sign?: boolean,
|
|
721
|
+
sighashtype?: string,
|
|
722
|
+
bip32derivs?: boolean
|
|
723
|
+
];
|
|
724
|
+
response: {
|
|
725
|
+
psbt: string;
|
|
726
|
+
complete: boolean;
|
|
727
|
+
};
|
|
728
|
+
}
|