@secondts/bark-react-native 0.9.0 → 0.11.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.
@@ -1,5 +1,5 @@
1
1
  /// <reference types="node" />
2
- import { type UniffiGcObject, type UniffiHandle, FfiConverterObject, FfiConverterObjectWithCallbacks, RustBuffer, UniffiAbstractObject, destructorGuardSymbol, pointerLiteralSymbol, uniffiTypeNameSymbol } from "uniffi-bindgen-react-native";
2
+ import { type UniffiGcObject, type UniffiHandle, FfiConverterObject, FfiConverterObjectWithCallbacks, RustBuffer, UniffiAbstractObject, destructorGuardSymbol, pointerLiteralSymbol, uniffiTypeNameSymbol, variantOrdinalSymbol } from "uniffi-bindgen-react-native";
3
3
  /**
4
4
  * Extract a signed transaction from a PSBT
5
5
  *
@@ -38,6 +38,14 @@ export declare function validateMnemonic(mnemonic: string): boolean;
38
38
  * will return an error.
39
39
  */
40
40
  export declare function setLogger(logger: BarkLogger, maxLevel: LogLevel): void;
41
+ /**
42
+ * Low-level function to initialize a wallet
43
+ *
44
+ * You probably want to use [`Wallet::open`] instead.
45
+ */
46
+ export declare function initWallet(network: Network, mnemonicOrSeed: string, config: Config, datadir: string, allowUnreachableServer: boolean, asyncOpts_?: {
47
+ signal: AbortSignal;
48
+ }): Promise<void>;
41
49
  export type AddressWithIndex = {
42
50
  address: string;
43
51
  index: number;
@@ -121,7 +129,6 @@ export type Config = {
121
129
  bitcoindCookiefile?: string;
122
130
  bitcoindUser?: string;
123
131
  bitcoindPass?: string;
124
- network: Network;
125
132
  vtxoRefreshExpiryThreshold?: number;
126
133
  vtxoExitMargin?: number;
127
134
  htlcRecvClaimDelta?: number;
@@ -131,13 +138,14 @@ export type Config = {
131
138
  offboardRequiredConfirmations?: number;
132
139
  daemonManualSync?: boolean;
133
140
  lightningReceiveClaimRetries?: number;
141
+ userAgent?: string;
134
142
  };
135
143
  /**
136
144
  * Generated factory for {@link Config} record objects.
137
145
  */
138
146
  export declare const Config: Readonly<{
139
- create: (partial: Partial<Config> & Required<Omit<Config, "serverAccessToken" | "esploraAddress" | "bitcoindAddress" | "bitcoindCookiefile" | "bitcoindUser" | "bitcoindPass" | "vtxoRefreshExpiryThreshold" | "vtxoExitMargin" | "htlcRecvClaimDelta" | "fallbackFeeRate" | "roundTxRequiredConfirmations" | "daemonSyncIntervalSecs" | "offboardRequiredConfirmations" | "daemonManualSync" | "lightningReceiveClaimRetries">>) => Config;
140
- new: (partial: Partial<Config> & Required<Omit<Config, "serverAccessToken" | "esploraAddress" | "bitcoindAddress" | "bitcoindCookiefile" | "bitcoindUser" | "bitcoindPass" | "vtxoRefreshExpiryThreshold" | "vtxoExitMargin" | "htlcRecvClaimDelta" | "fallbackFeeRate" | "roundTxRequiredConfirmations" | "daemonSyncIntervalSecs" | "offboardRequiredConfirmations" | "daemonManualSync" | "lightningReceiveClaimRetries">>) => Config;
147
+ create: (partial: Partial<Config> & Required<Omit<Config, "serverAccessToken" | "esploraAddress" | "bitcoindAddress" | "bitcoindCookiefile" | "bitcoindUser" | "bitcoindPass" | "vtxoRefreshExpiryThreshold" | "vtxoExitMargin" | "htlcRecvClaimDelta" | "fallbackFeeRate" | "roundTxRequiredConfirmations" | "daemonSyncIntervalSecs" | "offboardRequiredConfirmations" | "daemonManualSync" | "lightningReceiveClaimRetries" | "userAgent">>) => Config;
148
+ new: (partial: Partial<Config> & Required<Omit<Config, "serverAccessToken" | "esploraAddress" | "bitcoindAddress" | "bitcoindCookiefile" | "bitcoindUser" | "bitcoindPass" | "vtxoRefreshExpiryThreshold" | "vtxoExitMargin" | "htlcRecvClaimDelta" | "fallbackFeeRate" | "roundTxRequiredConfirmations" | "daemonSyncIntervalSecs" | "offboardRequiredConfirmations" | "daemonManualSync" | "lightningReceiveClaimRetries" | "userAgent">>) => Config;
141
149
  defaults: () => Partial<Config>;
142
150
  }>;
143
151
  /**
@@ -325,13 +333,16 @@ export type Movement = {
325
333
  createdAt: string;
326
334
  updatedAt: string;
327
335
  completedAt?: string;
336
+ paymentHash?: string;
337
+ lightningInvoice?: string;
338
+ lightningOffer?: string;
328
339
  };
329
340
  /**
330
341
  * Generated factory for {@link Movement} record objects.
331
342
  */
332
343
  export declare const Movement: Readonly<{
333
- create: (partial: Partial<Movement> & Required<Omit<Movement, "completedAt">>) => Movement;
334
- new: (partial: Partial<Movement> & Required<Omit<Movement, "completedAt">>) => Movement;
344
+ create: (partial: Partial<Movement> & Required<Omit<Movement, "paymentHash" | "completedAt" | "lightningInvoice" | "lightningOffer">>) => Movement;
345
+ new: (partial: Partial<Movement> & Required<Omit<Movement, "paymentHash" | "completedAt" | "lightningInvoice" | "lightningOffer">>) => Movement;
335
346
  defaults: () => Partial<Movement>;
336
347
  }>;
337
348
  export type OffboardResult = {
@@ -361,1316 +372,211 @@ export declare const OnchainBalance: Readonly<{
361
372
  /**
362
373
  * A Bitcoin transaction outpoint (reference to a previous output)
363
374
  */
364
- export type OutPoint = {
365
- txid: string;
366
- vout: number;
367
- };
368
- /**
369
- * Generated factory for {@link OutPoint} record objects.
370
- */
371
- export declare const OutPoint: Readonly<{
372
- create: (partial: Partial<OutPoint> & Required<Omit<OutPoint, never>>) => OutPoint;
373
- new: (partial: Partial<OutPoint> & Required<Omit<OutPoint, never>>) => OutPoint;
374
- defaults: () => Partial<OutPoint>;
375
- }>;
376
- export type PendingBoard = {
377
- vtxoId: string;
378
- amountSats: bigint;
379
- txid: string;
380
- };
381
- /**
382
- * Generated factory for {@link PendingBoard} record objects.
383
- */
384
- export declare const PendingBoard: Readonly<{
385
- create: (partial: Partial<PendingBoard> & Required<Omit<PendingBoard, never>>) => PendingBoard;
386
- new: (partial: Partial<PendingBoard> & Required<Omit<PendingBoard, never>>) => PendingBoard;
387
- defaults: () => Partial<PendingBoard>;
388
- }>;
389
- /**
390
- * A pending round state
391
- */
392
- export type RoundState = {
393
- id: number;
394
- /**
395
- * Whether the round is ongoing
396
- */
397
- ongoing: boolean;
398
- };
399
- /**
400
- * Generated factory for {@link RoundState} record objects.
401
- */
402
- export declare const RoundState: Readonly<{
403
- create: (partial: Partial<RoundState> & Required<Omit<RoundState, never>>) => RoundState;
404
- new: (partial: Partial<RoundState> & Required<Omit<RoundState, never>>) => RoundState;
405
- defaults: () => Partial<RoundState>;
406
- }>;
407
- export type Vtxo = {
408
- id: string;
409
- amountSats: bigint;
410
- expiryHeight: number;
411
- kind: string;
412
- state: string;
413
- /**
414
- * Genesis chain length. Compare against `ArkInfo.max_vtxo_exit_depth` to
415
- * detect VTXOs nearing the server's OOR-cosign refusal threshold.
416
- */
417
- exitDepth: number;
418
- /**
419
- * Weight units of the unilateral exit transaction chain. Lets clients
420
- * estimate exit cost without loading the full genesis.
421
- */
422
- exitTxWeightWu: bigint;
423
- };
424
- /**
425
- * Generated factory for {@link Vtxo} record objects.
426
- */
427
- export declare const Vtxo: Readonly<{
428
- create: (partial: Partial<Vtxo> & Required<Omit<Vtxo, never>>) => Vtxo;
429
- new: (partial: Partial<Vtxo> & Required<Omit<Vtxo, never>>) => Vtxo;
430
- defaults: () => Partial<Vtxo>;
431
- }>;
432
- export type WalletProperties = {
433
- network: Network;
434
- fingerprint: string;
435
- };
436
- /**
437
- * Generated factory for {@link WalletProperties} record objects.
438
- */
439
- export declare const WalletProperties: Readonly<{
440
- create: (partial: Partial<WalletProperties> & Required<Omit<WalletProperties, never>>) => WalletProperties;
441
- new: (partial: Partial<WalletProperties> & Required<Omit<WalletProperties, never>>) => WalletProperties;
442
- defaults: () => Partial<WalletProperties>;
443
- }>;
444
- export declare enum BarkError_Tags {
445
- Network = "Network",
446
- Database = "Database",
447
- InvalidMnemonic = "InvalidMnemonic",
448
- InvalidAddress = "InvalidAddress",
449
- InvalidInvoice = "InvalidInvoice",
450
- InvalidPsbt = "InvalidPsbt",
451
- InvalidTransaction = "InvalidTransaction",
452
- InsufficientFunds = "InsufficientFunds",
453
- NotFound = "NotFound",
454
- ServerConnection = "ServerConnection",
455
- Internal = "Internal",
456
- OnchainWalletRequired = "OnchainWalletRequired",
457
- InvalidVtxoId = "InvalidVtxoId",
458
- ServerPubkeyChanged = "ServerPubkeyChanged"
459
- }
460
- /**
461
- * Error types that can occur when using the Bark wallet FFI
462
- */
463
- export declare const BarkError: Readonly<{
464
- instanceOf: (obj: any) => obj is BarkError;
465
- Network: {
466
- new (inner: {
467
- errorMessage: string;
468
- }): {
469
- readonly tag: BarkError_Tags.Network;
470
- readonly inner: Readonly<{
471
- errorMessage: string;
472
- }>;
473
- /**
474
- * @private
475
- * This field is private and should not be used, use `tag` instead.
476
- */
477
- readonly [uniffiTypeNameSymbol]: "BarkError";
478
- name: string;
479
- message: string;
480
- stack?: string | undefined;
481
- cause?: unknown;
482
- };
483
- new(inner: {
484
- errorMessage: string;
485
- }): {
486
- readonly tag: BarkError_Tags.Network;
487
- readonly inner: Readonly<{
488
- errorMessage: string;
489
- }>;
490
- /**
491
- * @private
492
- * This field is private and should not be used, use `tag` instead.
493
- */
494
- readonly [uniffiTypeNameSymbol]: "BarkError";
495
- name: string;
496
- message: string;
497
- stack?: string | undefined;
498
- cause?: unknown;
499
- };
500
- instanceOf(obj: any): obj is {
501
- readonly tag: BarkError_Tags.Network;
502
- readonly inner: Readonly<{
503
- errorMessage: string;
504
- }>;
505
- /**
506
- * @private
507
- * This field is private and should not be used, use `tag` instead.
508
- */
509
- readonly [uniffiTypeNameSymbol]: "BarkError";
510
- name: string;
511
- message: string;
512
- stack?: string | undefined;
513
- cause?: unknown;
514
- };
515
- hasInner(obj: any): obj is {
516
- readonly tag: BarkError_Tags.Network;
517
- readonly inner: Readonly<{
518
- errorMessage: string;
519
- }>;
520
- /**
521
- * @private
522
- * This field is private and should not be used, use `tag` instead.
523
- */
524
- readonly [uniffiTypeNameSymbol]: "BarkError";
525
- name: string;
526
- message: string;
527
- stack?: string | undefined;
528
- cause?: unknown;
529
- };
530
- getInner(obj: {
531
- readonly tag: BarkError_Tags.Network;
532
- readonly inner: Readonly<{
533
- errorMessage: string;
534
- }>;
535
- /**
536
- * @private
537
- * This field is private and should not be used, use `tag` instead.
538
- */
539
- readonly [uniffiTypeNameSymbol]: "BarkError";
540
- name: string;
541
- message: string;
542
- stack?: string | undefined;
543
- cause?: unknown;
544
- }): Readonly<{
545
- errorMessage: string;
546
- }>;
547
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
548
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
549
- stackTraceLimit: number;
550
- };
551
- Database: {
552
- new (inner: {
553
- errorMessage: string;
554
- }): {
555
- readonly tag: BarkError_Tags.Database;
556
- readonly inner: Readonly<{
557
- errorMessage: string;
558
- }>;
559
- /**
560
- * @private
561
- * This field is private and should not be used, use `tag` instead.
562
- */
563
- readonly [uniffiTypeNameSymbol]: "BarkError";
564
- name: string;
565
- message: string;
566
- stack?: string | undefined;
567
- cause?: unknown;
568
- };
569
- new(inner: {
570
- errorMessage: string;
571
- }): {
572
- readonly tag: BarkError_Tags.Database;
573
- readonly inner: Readonly<{
574
- errorMessage: string;
575
- }>;
576
- /**
577
- * @private
578
- * This field is private and should not be used, use `tag` instead.
579
- */
580
- readonly [uniffiTypeNameSymbol]: "BarkError";
581
- name: string;
582
- message: string;
583
- stack?: string | undefined;
584
- cause?: unknown;
585
- };
586
- instanceOf(obj: any): obj is {
587
- readonly tag: BarkError_Tags.Database;
588
- readonly inner: Readonly<{
589
- errorMessage: string;
590
- }>;
591
- /**
592
- * @private
593
- * This field is private and should not be used, use `tag` instead.
594
- */
595
- readonly [uniffiTypeNameSymbol]: "BarkError";
596
- name: string;
597
- message: string;
598
- stack?: string | undefined;
599
- cause?: unknown;
600
- };
601
- hasInner(obj: any): obj is {
602
- readonly tag: BarkError_Tags.Database;
603
- readonly inner: Readonly<{
604
- errorMessage: string;
605
- }>;
606
- /**
607
- * @private
608
- * This field is private and should not be used, use `tag` instead.
609
- */
610
- readonly [uniffiTypeNameSymbol]: "BarkError";
611
- name: string;
612
- message: string;
613
- stack?: string | undefined;
614
- cause?: unknown;
615
- };
616
- getInner(obj: {
617
- readonly tag: BarkError_Tags.Database;
618
- readonly inner: Readonly<{
619
- errorMessage: string;
620
- }>;
621
- /**
622
- * @private
623
- * This field is private and should not be used, use `tag` instead.
624
- */
625
- readonly [uniffiTypeNameSymbol]: "BarkError";
626
- name: string;
627
- message: string;
628
- stack?: string | undefined;
629
- cause?: unknown;
630
- }): Readonly<{
631
- errorMessage: string;
632
- }>;
633
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
634
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
635
- stackTraceLimit: number;
636
- };
637
- InvalidMnemonic: {
638
- new (inner: {
639
- errorMessage: string;
640
- }): {
641
- readonly tag: BarkError_Tags.InvalidMnemonic;
642
- readonly inner: Readonly<{
643
- errorMessage: string;
644
- }>;
645
- /**
646
- * @private
647
- * This field is private and should not be used, use `tag` instead.
648
- */
649
- readonly [uniffiTypeNameSymbol]: "BarkError";
650
- name: string;
651
- message: string;
652
- stack?: string | undefined;
653
- cause?: unknown;
654
- };
655
- new(inner: {
656
- errorMessage: string;
657
- }): {
658
- readonly tag: BarkError_Tags.InvalidMnemonic;
659
- readonly inner: Readonly<{
660
- errorMessage: string;
661
- }>;
662
- /**
663
- * @private
664
- * This field is private and should not be used, use `tag` instead.
665
- */
666
- readonly [uniffiTypeNameSymbol]: "BarkError";
667
- name: string;
668
- message: string;
669
- stack?: string | undefined;
670
- cause?: unknown;
671
- };
672
- instanceOf(obj: any): obj is {
673
- readonly tag: BarkError_Tags.InvalidMnemonic;
674
- readonly inner: Readonly<{
675
- errorMessage: string;
676
- }>;
677
- /**
678
- * @private
679
- * This field is private and should not be used, use `tag` instead.
680
- */
681
- readonly [uniffiTypeNameSymbol]: "BarkError";
682
- name: string;
683
- message: string;
684
- stack?: string | undefined;
685
- cause?: unknown;
686
- };
687
- hasInner(obj: any): obj is {
688
- readonly tag: BarkError_Tags.InvalidMnemonic;
689
- readonly inner: Readonly<{
690
- errorMessage: string;
691
- }>;
692
- /**
693
- * @private
694
- * This field is private and should not be used, use `tag` instead.
695
- */
696
- readonly [uniffiTypeNameSymbol]: "BarkError";
697
- name: string;
698
- message: string;
699
- stack?: string | undefined;
700
- cause?: unknown;
701
- };
702
- getInner(obj: {
703
- readonly tag: BarkError_Tags.InvalidMnemonic;
704
- readonly inner: Readonly<{
705
- errorMessage: string;
706
- }>;
707
- /**
708
- * @private
709
- * This field is private and should not be used, use `tag` instead.
710
- */
711
- readonly [uniffiTypeNameSymbol]: "BarkError";
712
- name: string;
713
- message: string;
714
- stack?: string | undefined;
715
- cause?: unknown;
716
- }): Readonly<{
717
- errorMessage: string;
718
- }>;
719
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
720
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
721
- stackTraceLimit: number;
722
- };
723
- InvalidAddress: {
724
- new (inner: {
725
- errorMessage: string;
726
- }): {
727
- readonly tag: BarkError_Tags.InvalidAddress;
728
- readonly inner: Readonly<{
729
- errorMessage: string;
730
- }>;
731
- /**
732
- * @private
733
- * This field is private and should not be used, use `tag` instead.
734
- */
735
- readonly [uniffiTypeNameSymbol]: "BarkError";
736
- name: string;
737
- message: string;
738
- stack?: string | undefined;
739
- cause?: unknown;
740
- };
741
- new(inner: {
742
- errorMessage: string;
743
- }): {
744
- readonly tag: BarkError_Tags.InvalidAddress;
745
- readonly inner: Readonly<{
746
- errorMessage: string;
747
- }>;
748
- /**
749
- * @private
750
- * This field is private and should not be used, use `tag` instead.
751
- */
752
- readonly [uniffiTypeNameSymbol]: "BarkError";
753
- name: string;
754
- message: string;
755
- stack?: string | undefined;
756
- cause?: unknown;
757
- };
758
- instanceOf(obj: any): obj is {
759
- readonly tag: BarkError_Tags.InvalidAddress;
760
- readonly inner: Readonly<{
761
- errorMessage: string;
762
- }>;
763
- /**
764
- * @private
765
- * This field is private and should not be used, use `tag` instead.
766
- */
767
- readonly [uniffiTypeNameSymbol]: "BarkError";
768
- name: string;
769
- message: string;
770
- stack?: string | undefined;
771
- cause?: unknown;
772
- };
773
- hasInner(obj: any): obj is {
774
- readonly tag: BarkError_Tags.InvalidAddress;
775
- readonly inner: Readonly<{
776
- errorMessage: string;
777
- }>;
778
- /**
779
- * @private
780
- * This field is private and should not be used, use `tag` instead.
781
- */
782
- readonly [uniffiTypeNameSymbol]: "BarkError";
783
- name: string;
784
- message: string;
785
- stack?: string | undefined;
786
- cause?: unknown;
787
- };
788
- getInner(obj: {
789
- readonly tag: BarkError_Tags.InvalidAddress;
790
- readonly inner: Readonly<{
791
- errorMessage: string;
792
- }>;
793
- /**
794
- * @private
795
- * This field is private and should not be used, use `tag` instead.
796
- */
797
- readonly [uniffiTypeNameSymbol]: "BarkError";
798
- name: string;
799
- message: string;
800
- stack?: string | undefined;
801
- cause?: unknown;
802
- }): Readonly<{
803
- errorMessage: string;
804
- }>;
805
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
806
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
807
- stackTraceLimit: number;
808
- };
809
- InvalidInvoice: {
810
- new (inner: {
811
- errorMessage: string;
812
- }): {
813
- readonly tag: BarkError_Tags.InvalidInvoice;
814
- readonly inner: Readonly<{
815
- errorMessage: string;
816
- }>;
817
- /**
818
- * @private
819
- * This field is private and should not be used, use `tag` instead.
820
- */
821
- readonly [uniffiTypeNameSymbol]: "BarkError";
822
- name: string;
823
- message: string;
824
- stack?: string | undefined;
825
- cause?: unknown;
826
- };
827
- new(inner: {
828
- errorMessage: string;
829
- }): {
830
- readonly tag: BarkError_Tags.InvalidInvoice;
831
- readonly inner: Readonly<{
832
- errorMessage: string;
833
- }>;
834
- /**
835
- * @private
836
- * This field is private and should not be used, use `tag` instead.
837
- */
838
- readonly [uniffiTypeNameSymbol]: "BarkError";
839
- name: string;
840
- message: string;
841
- stack?: string | undefined;
842
- cause?: unknown;
843
- };
844
- instanceOf(obj: any): obj is {
845
- readonly tag: BarkError_Tags.InvalidInvoice;
846
- readonly inner: Readonly<{
847
- errorMessage: string;
848
- }>;
849
- /**
850
- * @private
851
- * This field is private and should not be used, use `tag` instead.
852
- */
853
- readonly [uniffiTypeNameSymbol]: "BarkError";
854
- name: string;
855
- message: string;
856
- stack?: string | undefined;
857
- cause?: unknown;
858
- };
859
- hasInner(obj: any): obj is {
860
- readonly tag: BarkError_Tags.InvalidInvoice;
861
- readonly inner: Readonly<{
862
- errorMessage: string;
863
- }>;
864
- /**
865
- * @private
866
- * This field is private and should not be used, use `tag` instead.
867
- */
868
- readonly [uniffiTypeNameSymbol]: "BarkError";
869
- name: string;
870
- message: string;
871
- stack?: string | undefined;
872
- cause?: unknown;
873
- };
874
- getInner(obj: {
875
- readonly tag: BarkError_Tags.InvalidInvoice;
876
- readonly inner: Readonly<{
877
- errorMessage: string;
878
- }>;
879
- /**
880
- * @private
881
- * This field is private and should not be used, use `tag` instead.
882
- */
883
- readonly [uniffiTypeNameSymbol]: "BarkError";
884
- name: string;
885
- message: string;
886
- stack?: string | undefined;
887
- cause?: unknown;
888
- }): Readonly<{
889
- errorMessage: string;
890
- }>;
891
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
892
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
893
- stackTraceLimit: number;
894
- };
895
- InvalidPsbt: {
896
- new (inner: {
897
- errorMessage: string;
898
- }): {
899
- readonly tag: BarkError_Tags.InvalidPsbt;
900
- readonly inner: Readonly<{
901
- errorMessage: string;
902
- }>;
903
- /**
904
- * @private
905
- * This field is private and should not be used, use `tag` instead.
906
- */
907
- readonly [uniffiTypeNameSymbol]: "BarkError";
908
- name: string;
909
- message: string;
910
- stack?: string | undefined;
911
- cause?: unknown;
912
- };
913
- new(inner: {
914
- errorMessage: string;
915
- }): {
916
- readonly tag: BarkError_Tags.InvalidPsbt;
917
- readonly inner: Readonly<{
918
- errorMessage: string;
919
- }>;
920
- /**
921
- * @private
922
- * This field is private and should not be used, use `tag` instead.
923
- */
924
- readonly [uniffiTypeNameSymbol]: "BarkError";
925
- name: string;
926
- message: string;
927
- stack?: string | undefined;
928
- cause?: unknown;
929
- };
930
- instanceOf(obj: any): obj is {
931
- readonly tag: BarkError_Tags.InvalidPsbt;
932
- readonly inner: Readonly<{
933
- errorMessage: string;
934
- }>;
935
- /**
936
- * @private
937
- * This field is private and should not be used, use `tag` instead.
938
- */
939
- readonly [uniffiTypeNameSymbol]: "BarkError";
940
- name: string;
941
- message: string;
942
- stack?: string | undefined;
943
- cause?: unknown;
944
- };
945
- hasInner(obj: any): obj is {
946
- readonly tag: BarkError_Tags.InvalidPsbt;
947
- readonly inner: Readonly<{
948
- errorMessage: string;
949
- }>;
950
- /**
951
- * @private
952
- * This field is private and should not be used, use `tag` instead.
953
- */
954
- readonly [uniffiTypeNameSymbol]: "BarkError";
955
- name: string;
956
- message: string;
957
- stack?: string | undefined;
958
- cause?: unknown;
959
- };
960
- getInner(obj: {
961
- readonly tag: BarkError_Tags.InvalidPsbt;
962
- readonly inner: Readonly<{
963
- errorMessage: string;
964
- }>;
965
- /**
966
- * @private
967
- * This field is private and should not be used, use `tag` instead.
968
- */
969
- readonly [uniffiTypeNameSymbol]: "BarkError";
970
- name: string;
971
- message: string;
972
- stack?: string | undefined;
973
- cause?: unknown;
974
- }): Readonly<{
975
- errorMessage: string;
976
- }>;
977
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
978
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
979
- stackTraceLimit: number;
980
- };
981
- InvalidTransaction: {
982
- new (inner: {
983
- errorMessage: string;
984
- }): {
985
- readonly tag: BarkError_Tags.InvalidTransaction;
986
- readonly inner: Readonly<{
987
- errorMessage: string;
988
- }>;
989
- /**
990
- * @private
991
- * This field is private and should not be used, use `tag` instead.
992
- */
993
- readonly [uniffiTypeNameSymbol]: "BarkError";
994
- name: string;
995
- message: string;
996
- stack?: string | undefined;
997
- cause?: unknown;
998
- };
999
- new(inner: {
1000
- errorMessage: string;
1001
- }): {
1002
- readonly tag: BarkError_Tags.InvalidTransaction;
1003
- readonly inner: Readonly<{
1004
- errorMessage: string;
1005
- }>;
1006
- /**
1007
- * @private
1008
- * This field is private and should not be used, use `tag` instead.
1009
- */
1010
- readonly [uniffiTypeNameSymbol]: "BarkError";
1011
- name: string;
1012
- message: string;
1013
- stack?: string | undefined;
1014
- cause?: unknown;
1015
- };
1016
- instanceOf(obj: any): obj is {
1017
- readonly tag: BarkError_Tags.InvalidTransaction;
1018
- readonly inner: Readonly<{
1019
- errorMessage: string;
1020
- }>;
1021
- /**
1022
- * @private
1023
- * This field is private and should not be used, use `tag` instead.
1024
- */
1025
- readonly [uniffiTypeNameSymbol]: "BarkError";
1026
- name: string;
1027
- message: string;
1028
- stack?: string | undefined;
1029
- cause?: unknown;
1030
- };
1031
- hasInner(obj: any): obj is {
1032
- readonly tag: BarkError_Tags.InvalidTransaction;
1033
- readonly inner: Readonly<{
1034
- errorMessage: string;
1035
- }>;
1036
- /**
1037
- * @private
1038
- * This field is private and should not be used, use `tag` instead.
1039
- */
1040
- readonly [uniffiTypeNameSymbol]: "BarkError";
1041
- name: string;
1042
- message: string;
1043
- stack?: string | undefined;
1044
- cause?: unknown;
1045
- };
1046
- getInner(obj: {
1047
- readonly tag: BarkError_Tags.InvalidTransaction;
1048
- readonly inner: Readonly<{
1049
- errorMessage: string;
1050
- }>;
1051
- /**
1052
- * @private
1053
- * This field is private and should not be used, use `tag` instead.
1054
- */
1055
- readonly [uniffiTypeNameSymbol]: "BarkError";
1056
- name: string;
1057
- message: string;
1058
- stack?: string | undefined;
1059
- cause?: unknown;
1060
- }): Readonly<{
1061
- errorMessage: string;
1062
- }>;
1063
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
1064
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
1065
- stackTraceLimit: number;
1066
- };
1067
- InsufficientFunds: {
1068
- new (inner: {
1069
- errorMessage: string;
1070
- }): {
1071
- readonly tag: BarkError_Tags.InsufficientFunds;
1072
- readonly inner: Readonly<{
1073
- errorMessage: string;
1074
- }>;
1075
- /**
1076
- * @private
1077
- * This field is private and should not be used, use `tag` instead.
1078
- */
1079
- readonly [uniffiTypeNameSymbol]: "BarkError";
1080
- name: string;
1081
- message: string;
1082
- stack?: string | undefined;
1083
- cause?: unknown;
1084
- };
1085
- new(inner: {
1086
- errorMessage: string;
1087
- }): {
1088
- readonly tag: BarkError_Tags.InsufficientFunds;
1089
- readonly inner: Readonly<{
1090
- errorMessage: string;
1091
- }>;
1092
- /**
1093
- * @private
1094
- * This field is private and should not be used, use `tag` instead.
1095
- */
1096
- readonly [uniffiTypeNameSymbol]: "BarkError";
1097
- name: string;
1098
- message: string;
1099
- stack?: string | undefined;
1100
- cause?: unknown;
1101
- };
1102
- instanceOf(obj: any): obj is {
1103
- readonly tag: BarkError_Tags.InsufficientFunds;
1104
- readonly inner: Readonly<{
1105
- errorMessage: string;
1106
- }>;
1107
- /**
1108
- * @private
1109
- * This field is private and should not be used, use `tag` instead.
1110
- */
1111
- readonly [uniffiTypeNameSymbol]: "BarkError";
1112
- name: string;
1113
- message: string;
1114
- stack?: string | undefined;
1115
- cause?: unknown;
1116
- };
1117
- hasInner(obj: any): obj is {
1118
- readonly tag: BarkError_Tags.InsufficientFunds;
1119
- readonly inner: Readonly<{
1120
- errorMessage: string;
1121
- }>;
1122
- /**
1123
- * @private
1124
- * This field is private and should not be used, use `tag` instead.
1125
- */
1126
- readonly [uniffiTypeNameSymbol]: "BarkError";
1127
- name: string;
1128
- message: string;
1129
- stack?: string | undefined;
1130
- cause?: unknown;
1131
- };
1132
- getInner(obj: {
1133
- readonly tag: BarkError_Tags.InsufficientFunds;
1134
- readonly inner: Readonly<{
1135
- errorMessage: string;
1136
- }>;
1137
- /**
1138
- * @private
1139
- * This field is private and should not be used, use `tag` instead.
1140
- */
1141
- readonly [uniffiTypeNameSymbol]: "BarkError";
1142
- name: string;
1143
- message: string;
1144
- stack?: string | undefined;
1145
- cause?: unknown;
1146
- }): Readonly<{
1147
- errorMessage: string;
1148
- }>;
1149
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
1150
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
1151
- stackTraceLimit: number;
1152
- };
1153
- NotFound: {
1154
- new (inner: {
1155
- errorMessage: string;
1156
- }): {
1157
- readonly tag: BarkError_Tags.NotFound;
1158
- readonly inner: Readonly<{
1159
- errorMessage: string;
1160
- }>;
1161
- /**
1162
- * @private
1163
- * This field is private and should not be used, use `tag` instead.
1164
- */
1165
- readonly [uniffiTypeNameSymbol]: "BarkError";
1166
- name: string;
1167
- message: string;
1168
- stack?: string | undefined;
1169
- cause?: unknown;
1170
- };
1171
- new(inner: {
1172
- errorMessage: string;
1173
- }): {
1174
- readonly tag: BarkError_Tags.NotFound;
1175
- readonly inner: Readonly<{
1176
- errorMessage: string;
1177
- }>;
1178
- /**
1179
- * @private
1180
- * This field is private and should not be used, use `tag` instead.
1181
- */
1182
- readonly [uniffiTypeNameSymbol]: "BarkError";
1183
- name: string;
1184
- message: string;
1185
- stack?: string | undefined;
1186
- cause?: unknown;
1187
- };
1188
- instanceOf(obj: any): obj is {
1189
- readonly tag: BarkError_Tags.NotFound;
1190
- readonly inner: Readonly<{
1191
- errorMessage: string;
1192
- }>;
1193
- /**
1194
- * @private
1195
- * This field is private and should not be used, use `tag` instead.
1196
- */
1197
- readonly [uniffiTypeNameSymbol]: "BarkError";
1198
- name: string;
1199
- message: string;
1200
- stack?: string | undefined;
1201
- cause?: unknown;
1202
- };
1203
- hasInner(obj: any): obj is {
1204
- readonly tag: BarkError_Tags.NotFound;
1205
- readonly inner: Readonly<{
1206
- errorMessage: string;
1207
- }>;
1208
- /**
1209
- * @private
1210
- * This field is private and should not be used, use `tag` instead.
1211
- */
1212
- readonly [uniffiTypeNameSymbol]: "BarkError";
1213
- name: string;
1214
- message: string;
1215
- stack?: string | undefined;
1216
- cause?: unknown;
1217
- };
1218
- getInner(obj: {
1219
- readonly tag: BarkError_Tags.NotFound;
1220
- readonly inner: Readonly<{
1221
- errorMessage: string;
1222
- }>;
1223
- /**
1224
- * @private
1225
- * This field is private and should not be used, use `tag` instead.
1226
- */
1227
- readonly [uniffiTypeNameSymbol]: "BarkError";
1228
- name: string;
1229
- message: string;
1230
- stack?: string | undefined;
1231
- cause?: unknown;
1232
- }): Readonly<{
1233
- errorMessage: string;
1234
- }>;
1235
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
1236
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
1237
- stackTraceLimit: number;
1238
- };
1239
- ServerConnection: {
1240
- new (inner: {
1241
- errorMessage: string;
1242
- }): {
1243
- readonly tag: BarkError_Tags.ServerConnection;
1244
- readonly inner: Readonly<{
1245
- errorMessage: string;
1246
- }>;
1247
- /**
1248
- * @private
1249
- * This field is private and should not be used, use `tag` instead.
1250
- */
1251
- readonly [uniffiTypeNameSymbol]: "BarkError";
1252
- name: string;
1253
- message: string;
1254
- stack?: string | undefined;
1255
- cause?: unknown;
1256
- };
1257
- new(inner: {
1258
- errorMessage: string;
1259
- }): {
1260
- readonly tag: BarkError_Tags.ServerConnection;
1261
- readonly inner: Readonly<{
1262
- errorMessage: string;
1263
- }>;
1264
- /**
1265
- * @private
1266
- * This field is private and should not be used, use `tag` instead.
1267
- */
1268
- readonly [uniffiTypeNameSymbol]: "BarkError";
1269
- name: string;
1270
- message: string;
1271
- stack?: string | undefined;
1272
- cause?: unknown;
1273
- };
1274
- instanceOf(obj: any): obj is {
1275
- readonly tag: BarkError_Tags.ServerConnection;
1276
- readonly inner: Readonly<{
1277
- errorMessage: string;
1278
- }>;
1279
- /**
1280
- * @private
1281
- * This field is private and should not be used, use `tag` instead.
1282
- */
1283
- readonly [uniffiTypeNameSymbol]: "BarkError";
1284
- name: string;
1285
- message: string;
1286
- stack?: string | undefined;
1287
- cause?: unknown;
1288
- };
1289
- hasInner(obj: any): obj is {
1290
- readonly tag: BarkError_Tags.ServerConnection;
1291
- readonly inner: Readonly<{
1292
- errorMessage: string;
1293
- }>;
1294
- /**
1295
- * @private
1296
- * This field is private and should not be used, use `tag` instead.
1297
- */
1298
- readonly [uniffiTypeNameSymbol]: "BarkError";
1299
- name: string;
1300
- message: string;
1301
- stack?: string | undefined;
1302
- cause?: unknown;
1303
- };
1304
- getInner(obj: {
1305
- readonly tag: BarkError_Tags.ServerConnection;
1306
- readonly inner: Readonly<{
1307
- errorMessage: string;
1308
- }>;
1309
- /**
1310
- * @private
1311
- * This field is private and should not be used, use `tag` instead.
1312
- */
1313
- readonly [uniffiTypeNameSymbol]: "BarkError";
1314
- name: string;
1315
- message: string;
1316
- stack?: string | undefined;
1317
- cause?: unknown;
1318
- }): Readonly<{
1319
- errorMessage: string;
1320
- }>;
1321
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
1322
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
1323
- stackTraceLimit: number;
1324
- };
1325
- Internal: {
1326
- new (inner: {
1327
- errorMessage: string;
1328
- }): {
1329
- readonly tag: BarkError_Tags.Internal;
1330
- readonly inner: Readonly<{
1331
- errorMessage: string;
1332
- }>;
1333
- /**
1334
- * @private
1335
- * This field is private and should not be used, use `tag` instead.
1336
- */
1337
- readonly [uniffiTypeNameSymbol]: "BarkError";
1338
- name: string;
1339
- message: string;
1340
- stack?: string | undefined;
1341
- cause?: unknown;
1342
- };
1343
- new(inner: {
1344
- errorMessage: string;
1345
- }): {
1346
- readonly tag: BarkError_Tags.Internal;
1347
- readonly inner: Readonly<{
1348
- errorMessage: string;
1349
- }>;
1350
- /**
1351
- * @private
1352
- * This field is private and should not be used, use `tag` instead.
1353
- */
1354
- readonly [uniffiTypeNameSymbol]: "BarkError";
1355
- name: string;
1356
- message: string;
1357
- stack?: string | undefined;
1358
- cause?: unknown;
1359
- };
1360
- instanceOf(obj: any): obj is {
1361
- readonly tag: BarkError_Tags.Internal;
1362
- readonly inner: Readonly<{
1363
- errorMessage: string;
1364
- }>;
1365
- /**
1366
- * @private
1367
- * This field is private and should not be used, use `tag` instead.
1368
- */
1369
- readonly [uniffiTypeNameSymbol]: "BarkError";
1370
- name: string;
1371
- message: string;
1372
- stack?: string | undefined;
1373
- cause?: unknown;
1374
- };
1375
- hasInner(obj: any): obj is {
1376
- readonly tag: BarkError_Tags.Internal;
1377
- readonly inner: Readonly<{
1378
- errorMessage: string;
1379
- }>;
1380
- /**
1381
- * @private
1382
- * This field is private and should not be used, use `tag` instead.
1383
- */
1384
- readonly [uniffiTypeNameSymbol]: "BarkError";
1385
- name: string;
1386
- message: string;
1387
- stack?: string | undefined;
1388
- cause?: unknown;
1389
- };
1390
- getInner(obj: {
1391
- readonly tag: BarkError_Tags.Internal;
1392
- readonly inner: Readonly<{
1393
- errorMessage: string;
1394
- }>;
1395
- /**
1396
- * @private
1397
- * This field is private and should not be used, use `tag` instead.
1398
- */
1399
- readonly [uniffiTypeNameSymbol]: "BarkError";
1400
- name: string;
1401
- message: string;
1402
- stack?: string | undefined;
1403
- cause?: unknown;
1404
- }): Readonly<{
1405
- errorMessage: string;
1406
- }>;
1407
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
1408
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
1409
- stackTraceLimit: number;
1410
- };
1411
- OnchainWalletRequired: {
1412
- new (inner: {
1413
- errorMessage: string;
1414
- }): {
1415
- readonly tag: BarkError_Tags.OnchainWalletRequired;
1416
- readonly inner: Readonly<{
1417
- errorMessage: string;
1418
- }>;
1419
- /**
1420
- * @private
1421
- * This field is private and should not be used, use `tag` instead.
1422
- */
1423
- readonly [uniffiTypeNameSymbol]: "BarkError";
1424
- name: string;
1425
- message: string;
1426
- stack?: string | undefined;
1427
- cause?: unknown;
1428
- };
1429
- new(inner: {
1430
- errorMessage: string;
1431
- }): {
1432
- readonly tag: BarkError_Tags.OnchainWalletRequired;
1433
- readonly inner: Readonly<{
1434
- errorMessage: string;
1435
- }>;
1436
- /**
1437
- * @private
1438
- * This field is private and should not be used, use `tag` instead.
1439
- */
1440
- readonly [uniffiTypeNameSymbol]: "BarkError";
1441
- name: string;
1442
- message: string;
1443
- stack?: string | undefined;
1444
- cause?: unknown;
1445
- };
1446
- instanceOf(obj: any): obj is {
1447
- readonly tag: BarkError_Tags.OnchainWalletRequired;
1448
- readonly inner: Readonly<{
1449
- errorMessage: string;
1450
- }>;
1451
- /**
1452
- * @private
1453
- * This field is private and should not be used, use `tag` instead.
1454
- */
1455
- readonly [uniffiTypeNameSymbol]: "BarkError";
1456
- name: string;
1457
- message: string;
1458
- stack?: string | undefined;
1459
- cause?: unknown;
1460
- };
1461
- hasInner(obj: any): obj is {
1462
- readonly tag: BarkError_Tags.OnchainWalletRequired;
1463
- readonly inner: Readonly<{
1464
- errorMessage: string;
1465
- }>;
1466
- /**
1467
- * @private
1468
- * This field is private and should not be used, use `tag` instead.
1469
- */
1470
- readonly [uniffiTypeNameSymbol]: "BarkError";
1471
- name: string;
1472
- message: string;
1473
- stack?: string | undefined;
1474
- cause?: unknown;
1475
- };
1476
- getInner(obj: {
1477
- readonly tag: BarkError_Tags.OnchainWalletRequired;
1478
- readonly inner: Readonly<{
1479
- errorMessage: string;
1480
- }>;
1481
- /**
1482
- * @private
1483
- * This field is private and should not be used, use `tag` instead.
1484
- */
1485
- readonly [uniffiTypeNameSymbol]: "BarkError";
1486
- name: string;
1487
- message: string;
1488
- stack?: string | undefined;
1489
- cause?: unknown;
1490
- }): Readonly<{
1491
- errorMessage: string;
1492
- }>;
1493
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
1494
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
1495
- stackTraceLimit: number;
1496
- };
1497
- InvalidVtxoId: {
1498
- new (inner: {
1499
- errorMessage: string;
1500
- }): {
1501
- readonly tag: BarkError_Tags.InvalidVtxoId;
1502
- readonly inner: Readonly<{
1503
- errorMessage: string;
1504
- }>;
375
+ export type OutPoint = {
376
+ txid: string;
377
+ vout: number;
378
+ };
379
+ /**
380
+ * Generated factory for {@link OutPoint} record objects.
381
+ */
382
+ export declare const OutPoint: Readonly<{
383
+ create: (partial: Partial<OutPoint> & Required<Omit<OutPoint, never>>) => OutPoint;
384
+ new: (partial: Partial<OutPoint> & Required<Omit<OutPoint, never>>) => OutPoint;
385
+ defaults: () => Partial<OutPoint>;
386
+ }>;
387
+ export type PendingBoard = {
388
+ vtxoId: string;
389
+ amountSats: bigint;
390
+ txid: string;
391
+ };
392
+ /**
393
+ * Generated factory for {@link PendingBoard} record objects.
394
+ */
395
+ export declare const PendingBoard: Readonly<{
396
+ create: (partial: Partial<PendingBoard> & Required<Omit<PendingBoard, never>>) => PendingBoard;
397
+ new: (partial: Partial<PendingBoard> & Required<Omit<PendingBoard, never>>) => PendingBoard;
398
+ defaults: () => Partial<PendingBoard>;
399
+ }>;
400
+ /**
401
+ * A pending round state
402
+ */
403
+ export type RoundState = {
404
+ id: number;
405
+ /**
406
+ * Whether the round is ongoing
407
+ */
408
+ ongoing: boolean;
409
+ };
410
+ /**
411
+ * Generated factory for {@link RoundState} record objects.
412
+ */
413
+ export declare const RoundState: Readonly<{
414
+ create: (partial: Partial<RoundState> & Required<Omit<RoundState, never>>) => RoundState;
415
+ new: (partial: Partial<RoundState> & Required<Omit<RoundState, never>>) => RoundState;
416
+ defaults: () => Partial<RoundState>;
417
+ }>;
418
+ export type Vtxo = {
419
+ id: string;
420
+ amountSats: bigint;
421
+ expiryHeight: number;
422
+ kind: string;
423
+ state: string;
424
+ /**
425
+ * Genesis chain length. Compare against `ArkInfo.max_vtxo_exit_depth` to
426
+ * detect VTXOs nearing the server's OOR-cosign refusal threshold.
427
+ */
428
+ exitDepth: number;
429
+ /**
430
+ * Weight units of the unilateral exit transaction chain. Lets clients
431
+ * estimate exit cost without loading the full genesis.
432
+ */
433
+ exitTxWeightWu: bigint;
434
+ };
435
+ /**
436
+ * Generated factory for {@link Vtxo} record objects.
437
+ */
438
+ export declare const Vtxo: Readonly<{
439
+ create: (partial: Partial<Vtxo> & Required<Omit<Vtxo, never>>) => Vtxo;
440
+ new: (partial: Partial<Vtxo> & Required<Omit<Vtxo, never>>) => Vtxo;
441
+ defaults: () => Partial<Vtxo>;
442
+ }>;
443
+ /**
444
+ * Optional arguments for [`Wallet::open`], mirroring [`bark::OpenWalletArgs`].
445
+ *
446
+ * Every field has a default, so callers only set what they need.
447
+ */
448
+ export type WalletOpenArgs = {
449
+ /**
450
+ * Whether to run the background daemon
451
+ *
452
+ * When disabled, you must manually call `Wallet::sync` to sync the wallet.
453
+ *
454
+ * Default: true
455
+ */
456
+ runDaemon: boolean;
457
+ /**
458
+ * The data directory to use for this wallet
459
+ */
460
+ datadir: string;
461
+ /**
462
+ * The onchain wallet to use, if any
463
+ *
464
+ * Default: none
465
+ */
466
+ onchain?: OnchainWalletLike;
467
+ /**
468
+ * Whether to create a new wallet if no wallet exists
469
+ *
470
+ * Default: true
471
+ */
472
+ createIfNotExists: boolean;
473
+ /**
474
+ * Whether to create a new wallet even if the Ark server cannot be reached
475
+ *
476
+ * Default: false
477
+ */
478
+ createWithoutServer: boolean;
479
+ };
480
+ /**
481
+ * Generated factory for {@link WalletOpenArgs} record objects.
482
+ */
483
+ export declare const WalletOpenArgs: Readonly<{
484
+ create: (partial: Partial<WalletOpenArgs> & Required<Omit<WalletOpenArgs, "runDaemon" | "onchain" | "createIfNotExists" | "createWithoutServer">>) => WalletOpenArgs;
485
+ new: (partial: Partial<WalletOpenArgs> & Required<Omit<WalletOpenArgs, "runDaemon" | "onchain" | "createIfNotExists" | "createWithoutServer">>) => WalletOpenArgs;
486
+ defaults: () => Partial<WalletOpenArgs>;
487
+ }>;
488
+ export type WalletProperties = {
489
+ network: Network;
490
+ fingerprint: string;
491
+ };
492
+ /**
493
+ * Generated factory for {@link WalletProperties} record objects.
494
+ */
495
+ export declare const WalletProperties: Readonly<{
496
+ create: (partial: Partial<WalletProperties> & Required<Omit<WalletProperties, never>>) => WalletProperties;
497
+ new: (partial: Partial<WalletProperties> & Required<Omit<WalletProperties, never>>) => WalletProperties;
498
+ defaults: () => Partial<WalletProperties>;
499
+ }>;
500
+ export declare enum Exception_Tags {
501
+ Inner = "Inner"
502
+ }
503
+ /**
504
+ * The single error type surfaced across the Bark FFI.
505
+ *
506
+ * It is a thin, single-variant wrapper around [`anyhow::Error`]. uniffi error
507
+ * types must be enums (callback interfaces require `ConvertError`, which
508
+ * objects cannot provide), and `flat_error` tells uniffi to carry only the
509
+ * `Display` string across the boundary — so the rich anyhow context collapses
510
+ * to a single message on the foreign side.
511
+ */
512
+ export declare const Exception: {
513
+ Inner: {
514
+ new (message: string): {
515
+ readonly tag: Exception_Tags.Inner;
1505
516
  /**
1506
517
  * @private
1507
- * This field is private and should not be used, use `tag` instead.
518
+ * This field is private and should not be used.
1508
519
  */
1509
- readonly [uniffiTypeNameSymbol]: "BarkError";
1510
- name: string;
1511
- message: string;
1512
- stack?: string | undefined;
1513
- cause?: unknown;
1514
- };
1515
- new(inner: {
1516
- errorMessage: string;
1517
- }): {
1518
- readonly tag: BarkError_Tags.InvalidVtxoId;
1519
- readonly inner: Readonly<{
1520
- errorMessage: string;
1521
- }>;
520
+ readonly [uniffiTypeNameSymbol]: string;
1522
521
  /**
1523
522
  * @private
1524
- * This field is private and should not be used, use `tag` instead.
523
+ * This field is private and should not be used.
1525
524
  */
1526
- readonly [uniffiTypeNameSymbol]: "BarkError";
525
+ readonly [variantOrdinalSymbol]: 1;
1527
526
  name: string;
1528
527
  message: string;
1529
528
  stack?: string | undefined;
1530
529
  cause?: unknown;
1531
530
  };
1532
- instanceOf(obj: any): obj is {
1533
- readonly tag: BarkError_Tags.InvalidVtxoId;
1534
- readonly inner: Readonly<{
1535
- errorMessage: string;
1536
- }>;
531
+ instanceOf(e: any): e is {
532
+ readonly tag: Exception_Tags.Inner;
1537
533
  /**
1538
534
  * @private
1539
- * This field is private and should not be used, use `tag` instead.
535
+ * This field is private and should not be used.
1540
536
  */
1541
- readonly [uniffiTypeNameSymbol]: "BarkError";
1542
- name: string;
1543
- message: string;
1544
- stack?: string | undefined;
1545
- cause?: unknown;
1546
- };
1547
- hasInner(obj: any): obj is {
1548
- readonly tag: BarkError_Tags.InvalidVtxoId;
1549
- readonly inner: Readonly<{
1550
- errorMessage: string;
1551
- }>;
537
+ readonly [uniffiTypeNameSymbol]: string;
1552
538
  /**
1553
539
  * @private
1554
- * This field is private and should not be used, use `tag` instead.
540
+ * This field is private and should not be used.
1555
541
  */
1556
- readonly [uniffiTypeNameSymbol]: "BarkError";
542
+ readonly [variantOrdinalSymbol]: 1;
1557
543
  name: string;
1558
544
  message: string;
1559
545
  stack?: string | undefined;
1560
546
  cause?: unknown;
1561
547
  };
1562
- getInner(obj: {
1563
- readonly tag: BarkError_Tags.InvalidVtxoId;
1564
- readonly inner: Readonly<{
1565
- errorMessage: string;
1566
- }>;
1567
- /**
1568
- * @private
1569
- * This field is private and should not be used, use `tag` instead.
1570
- */
1571
- readonly [uniffiTypeNameSymbol]: "BarkError";
1572
- name: string;
1573
- message: string;
1574
- stack?: string | undefined;
1575
- cause?: unknown;
1576
- }): Readonly<{
1577
- errorMessage: string;
1578
- }>;
1579
548
  captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
1580
549
  prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
1581
550
  stackTraceLimit: number;
1582
551
  };
1583
- ServerPubkeyChanged: {
1584
- new (inner: {
1585
- errorMessage: string;
1586
- }): {
1587
- readonly tag: BarkError_Tags.ServerPubkeyChanged;
1588
- readonly inner: Readonly<{
1589
- errorMessage: string;
1590
- }>;
1591
- /**
1592
- * @private
1593
- * This field is private and should not be used, use `tag` instead.
1594
- */
1595
- readonly [uniffiTypeNameSymbol]: "BarkError";
1596
- name: string;
1597
- message: string;
1598
- stack?: string | undefined;
1599
- cause?: unknown;
1600
- };
1601
- new(inner: {
1602
- errorMessage: string;
1603
- }): {
1604
- readonly tag: BarkError_Tags.ServerPubkeyChanged;
1605
- readonly inner: Readonly<{
1606
- errorMessage: string;
1607
- }>;
1608
- /**
1609
- * @private
1610
- * This field is private and should not be used, use `tag` instead.
1611
- */
1612
- readonly [uniffiTypeNameSymbol]: "BarkError";
1613
- name: string;
1614
- message: string;
1615
- stack?: string | undefined;
1616
- cause?: unknown;
1617
- };
1618
- instanceOf(obj: any): obj is {
1619
- readonly tag: BarkError_Tags.ServerPubkeyChanged;
1620
- readonly inner: Readonly<{
1621
- errorMessage: string;
1622
- }>;
1623
- /**
1624
- * @private
1625
- * This field is private and should not be used, use `tag` instead.
1626
- */
1627
- readonly [uniffiTypeNameSymbol]: "BarkError";
1628
- name: string;
1629
- message: string;
1630
- stack?: string | undefined;
1631
- cause?: unknown;
1632
- };
1633
- hasInner(obj: any): obj is {
1634
- readonly tag: BarkError_Tags.ServerPubkeyChanged;
1635
- readonly inner: Readonly<{
1636
- errorMessage: string;
1637
- }>;
1638
- /**
1639
- * @private
1640
- * This field is private and should not be used, use `tag` instead.
1641
- */
1642
- readonly [uniffiTypeNameSymbol]: "BarkError";
1643
- name: string;
1644
- message: string;
1645
- stack?: string | undefined;
1646
- cause?: unknown;
1647
- };
1648
- getInner(obj: {
1649
- readonly tag: BarkError_Tags.ServerPubkeyChanged;
1650
- readonly inner: Readonly<{
1651
- errorMessage: string;
1652
- }>;
1653
- /**
1654
- * @private
1655
- * This field is private and should not be used, use `tag` instead.
1656
- */
1657
- readonly [uniffiTypeNameSymbol]: "BarkError";
1658
- name: string;
1659
- message: string;
1660
- stack?: string | undefined;
1661
- cause?: unknown;
1662
- }): Readonly<{
1663
- errorMessage: string;
1664
- }>;
1665
- captureStackTrace(targetObject: object, constructorOpt?: Function | undefined): void;
1666
- prepareStackTrace(err: Error, stackTraces: NodeJS.CallSite[]): any;
1667
- stackTraceLimit: number;
552
+ instanceOf: (e: any) => e is {
553
+ readonly tag: Exception_Tags.Inner;
554
+ /**
555
+ * @private
556
+ * This field is private and should not be used.
557
+ */
558
+ readonly [uniffiTypeNameSymbol]: string;
559
+ /**
560
+ * @private
561
+ * This field is private and should not be used.
562
+ */
563
+ readonly [variantOrdinalSymbol]: 1;
564
+ name: string;
565
+ message: string;
566
+ stack?: string | undefined;
567
+ cause?: unknown;
1668
568
  };
1669
- }>;
569
+ };
1670
570
  /**
1671
- * Error types that can occur when using the Bark wallet FFI
571
+ * The single error type surfaced across the Bark FFI.
572
+ *
573
+ * It is a thin, single-variant wrapper around [`anyhow::Error`]. uniffi error
574
+ * types must be enums (callback interfaces require `ConvertError`, which
575
+ * objects cannot provide), and `flat_error` tells uniffi to carry only the
576
+ * `Display` string across the boundary — so the rich anyhow context collapses
577
+ * to a single message on the foreign side.
1672
578
  */
1673
- export type BarkError = InstanceType<(typeof BarkError)[keyof Omit<typeof BarkError, "instanceOf">]>;
579
+ export type Exception = InstanceType<(typeof Exception)[keyof Omit<typeof Exception, "instanceOf">]>;
1674
580
  export declare enum LightningSendStatus_Tags {
1675
581
  Unknown = "Unknown",
1676
582
  InProgress = "InProgress",
@@ -2056,6 +962,15 @@ export interface CustomOnchainWalletCallbacks {
2056
962
  * * `tx_hex` - Hex-encoded transaction
2057
963
  */
2058
964
  storeSignedP2aCpfp(txHex: string): void;
965
+ /**
966
+ * Sync the wallet with the chain.
967
+ *
968
+ * Called by Bark (e.g. the background daemon) to ask the wallet to refresh
969
+ * its view of the chain before reading balances or building transactions.
970
+ * Implementations bring their own chain backend up to date — Bark's chain
971
+ * source is intentionally not passed across the FFI boundary.
972
+ */
973
+ sync(): void;
2059
974
  }
2060
975
  /**
2061
976
  * Callback interface for custom onchain wallet implementations
@@ -2150,6 +1065,15 @@ export declare class CustomOnchainWalletCallbacksImpl extends UniffiAbstractObje
2150
1065
  * * `tx_hex` - Hex-encoded transaction
2151
1066
  */
2152
1067
  storeSignedP2aCpfp(txHex: string): void;
1068
+ /**
1069
+ * Sync the wallet with the chain.
1070
+ *
1071
+ * Called by Bark (e.g. the background daemon) to ask the wallet to refresh
1072
+ * its view of the chain before reading balances or building transactions.
1073
+ * Implementations bring their own chain backend up to date — Bark's chain
1074
+ * source is intentionally not passed across the FFI boundary.
1075
+ */
1076
+ sync(): void;
2153
1077
  /**
2154
1078
  * {@inheritDoc uniffi-bindgen-react-native#UniffiAbstractObject.uniffiDestroy}
2155
1079
  */
@@ -2189,7 +1113,7 @@ export interface NotificationHolderLike {
2189
1113
  * (cancellation only affects the current wait; the stream lives on)
2190
1114
  * - The wallet's notification source was shut down permanently
2191
1115
  *
2192
- * Returns `Err(BarkError::Internal)` if called concurrently on the same holder.
1116
+ * Returns an error if called concurrently on the same holder.
2193
1117
  *
2194
1118
  * After a cancellation this method can be called again normally — the
2195
1119
  * underlying `NotificationStream` is preserved in `self.stream` and a
@@ -2240,7 +1164,7 @@ export declare class NotificationHolder extends UniffiAbstractObject implements
2240
1164
  * (cancellation only affects the current wait; the stream lives on)
2241
1165
  * - The wallet's notification source was shut down permanently
2242
1166
  *
2243
- * Returns `Err(BarkError::Internal)` if called concurrently on the same holder.
1167
+ * Returns an error if called concurrently on the same holder.
2244
1168
  *
2245
1169
  * After a cancellation this method can be called again normally — the
2246
1170
  * underlying `NotificationStream` is preserved in `self.stream` and a
@@ -2295,7 +1219,7 @@ export declare class OnchainWallet extends UniffiAbstractObject implements Oncha
2295
1219
  /**
2296
1220
  * BDK-backed wallet. Opens the shared sqlite cache.
2297
1221
  */
2298
- static default_(mnemonic: string, config: Config, datadir: string, asyncOpts_?: {
1222
+ static default_(network: Network, mnemonic: string, config: Config, datadir: string, asyncOpts_?: {
2299
1223
  signal: AbortSignal;
2300
1224
  }): Promise<OnchainWalletLike>;
2301
1225
  balance(asyncOpts_?: {
@@ -2466,9 +1390,6 @@ export interface WalletLike {
2466
1390
  maintenanceWithOnchainDelegated(onchainWallet: OnchainWalletLike, asyncOpts_?: {
2467
1391
  signal: AbortSignal;
2468
1392
  }): Promise<void>;
2469
- maybeScheduleMaintenanceRefresh(asyncOpts_?: {
2470
- signal: AbortSignal;
2471
- }): Promise</*u32*/ /*u32*/ number | undefined>;
2472
1393
  network(asyncOpts_?: {
2473
1394
  signal: AbortSignal;
2474
1395
  }): Promise<Network>;
@@ -2500,6 +1421,15 @@ export interface WalletLike {
2500
1421
  payLightningOffer(offer: string, amountSats: /*u64*/ bigint | undefined, wait: boolean, asyncOpts_?: {
2501
1422
  signal: AbortSignal;
2502
1423
  }): Promise<LightningSendStatus>;
1424
+ /**
1425
+ * Pay a raw LNURL-pay link (`lnurl1…`). UniFFI-only — lnurl-rs is not wasm-compatible.
1426
+ *
1427
+ * Resolves the LNURL-pay endpoint to a BOLT11 invoice and pays it. Errors
1428
+ * if the link decodes to a non-pay LNURL (auth, withdraw, channel).
1429
+ */
1430
+ payLnurl(lnurl: string, amountSats: bigint, comment: string | undefined, wait: boolean, asyncOpts_?: {
1431
+ signal: AbortSignal;
1432
+ }): Promise<LightningSendStatus>;
2503
1433
  peekAddress(index: number, asyncOpts_?: {
2504
1434
  signal: AbortSignal;
2505
1435
  }): Promise<string>;
@@ -2550,7 +1480,7 @@ export interface WalletLike {
2550
1480
  }): Promise<void>;
2551
1481
  sendArkoorPayment(arkAddress: string, amountSats: bigint, asyncOpts_?: {
2552
1482
  signal: AbortSignal;
2553
- }): Promise<string>;
1483
+ }): Promise<void>;
2554
1484
  sendOnchain(address: string, amountSats: bigint, asyncOpts_?: {
2555
1485
  signal: AbortSignal;
2556
1486
  }): Promise<string>;
@@ -2578,6 +1508,16 @@ export interface WalletLike {
2578
1508
  syncExits(onchainWallet: OnchainWalletLike, asyncOpts_?: {
2579
1509
  signal: AbortSignal;
2580
1510
  }): Promise<void>;
1511
+ /**
1512
+ * Scan for VTXOs that were force-exited on-chain without the user asking
1513
+ * and route them into the unilateral-exit flow so the funds can be claimed.
1514
+ *
1515
+ * This already runs automatically as part of [`Self::sync`]; call it
1516
+ * directly to trigger the scan on demand.
1517
+ */
1518
+ syncForceExitedVtxos(asyncOpts_?: {
1519
+ signal: AbortSignal;
1520
+ }): Promise<void>;
2581
1521
  syncPendingBoards(asyncOpts_?: {
2582
1522
  signal: AbortSignal;
2583
1523
  }): Promise<void>;
@@ -2614,22 +1554,16 @@ export declare class Wallet extends UniffiAbstractObject implements WalletLike {
2614
1554
  readonly [destructorGuardSymbol]: UniffiGcObject;
2615
1555
  readonly [pointerLiteralSymbol]: UniffiHandle;
2616
1556
  private constructor();
2617
- static create(mnemonic: string, config: Config, datadir: string, forceRescan: boolean, asyncOpts_?: {
2618
- signal: AbortSignal;
2619
- }): Promise<WalletLike>;
2620
- static createWithOnchain(mnemonic: string, config: Config, datadir: string, onchainWallet: OnchainWalletLike, forceRescan: boolean, asyncOpts_?: {
2621
- signal: AbortSignal;
2622
- }): Promise<WalletLike>;
2623
- static open(mnemonic: string, config: Config, datadir: string, asyncOpts_?: {
2624
- signal: AbortSignal;
2625
- }): Promise<WalletLike>;
2626
1557
  /**
2627
- * Open an existing wallet and start running the daemon.
1558
+ * Open a wallet (creating it first if `create_if_not_exists` is set),
1559
+ * mirroring [`bark::Wallet::open`]: a single entry point with everything
1560
+ * else optional (see [`WalletOpenArgs`]). For the explicit
1561
+ * initialize-but-don't-open path, use the top-level `create_wallet`.
1562
+ *
1563
+ * `mnemonic_or_seed` accepts either a BIP-39 mnemonic phrase or a 64-byte
1564
+ * hex-encoded seed.
2628
1565
  */
2629
- static openWithDaemon(mnemonic: string, config: Config, datadir: string, onchainWallet: OnchainWalletLike | undefined, asyncOpts_?: {
2630
- signal: AbortSignal;
2631
- }): Promise<WalletLike>;
2632
- static openWithOnchain(mnemonic: string, config: Config, datadir: string, onchainWallet: OnchainWalletLike, asyncOpts_?: {
1566
+ static open(network: Network, mnemonicOrSeed: string, config: Config, args: WalletOpenArgs, asyncOpts_?: {
2633
1567
  signal: AbortSignal;
2634
1568
  }): Promise<WalletLike>;
2635
1569
  allExitsClaimableAtHeight(asyncOpts_?: {
@@ -2671,7 +1605,7 @@ export declare class Wallet extends UniffiAbstractObject implements WalletLike {
2671
1605
  cancelPendingRound(roundId: number, asyncOpts_?: {
2672
1606
  signal: AbortSignal;
2673
1607
  }): Promise<void>;
2674
- checkLightningPayment(paymentHash: string, wait: boolean, asyncOpts_?: {
1608
+ checkLightningPayment(paymentHash: string, wait?: boolean, asyncOpts_?: {
2675
1609
  signal: AbortSignal;
2676
1610
  }): Promise<LightningSendStatus>;
2677
1611
  claimableLightningReceiveBalanceSats(asyncOpts_?: {
@@ -2770,9 +1704,6 @@ export declare class Wallet extends UniffiAbstractObject implements WalletLike {
2770
1704
  maintenanceWithOnchainDelegated(onchainWallet: OnchainWalletLike, asyncOpts_?: {
2771
1705
  signal: AbortSignal;
2772
1706
  }): Promise<void>;
2773
- maybeScheduleMaintenanceRefresh(asyncOpts_?: {
2774
- signal: AbortSignal;
2775
- }): Promise</*u32*/ /*u32*/ number | undefined>;
2776
1707
  network(asyncOpts_?: {
2777
1708
  signal: AbortSignal;
2778
1709
  }): Promise<Network>;
@@ -2795,13 +1726,22 @@ export declare class Wallet extends UniffiAbstractObject implements WalletLike {
2795
1726
  /**
2796
1727
  * Pay to a Lightning Address (LNURL). UniFFI-only — lnurl-rs is not wasm-compatible.
2797
1728
  */
2798
- payLightningAddress(lightningAddress: string, amountSats: bigint, comment: string | undefined, wait: boolean, asyncOpts_?: {
1729
+ payLightningAddress(lightningAddress: string, amountSats: bigint, comment: string | undefined, wait?: boolean, asyncOpts_?: {
2799
1730
  signal: AbortSignal;
2800
1731
  }): Promise<LightningSendStatus>;
2801
- payLightningInvoice(invoice: string, amountSats: /*u64*/ bigint | undefined, wait: boolean, asyncOpts_?: {
1732
+ payLightningInvoice(invoice: string, amountSats: /*u64*/ bigint | undefined, wait?: boolean, asyncOpts_?: {
2802
1733
  signal: AbortSignal;
2803
1734
  }): Promise<LightningSendStatus>;
2804
- payLightningOffer(offer: string, amountSats: /*u64*/ bigint | undefined, wait: boolean, asyncOpts_?: {
1735
+ payLightningOffer(offer: string, amountSats: /*u64*/ bigint | undefined, wait?: boolean, asyncOpts_?: {
1736
+ signal: AbortSignal;
1737
+ }): Promise<LightningSendStatus>;
1738
+ /**
1739
+ * Pay a raw LNURL-pay link (`lnurl1…`). UniFFI-only — lnurl-rs is not wasm-compatible.
1740
+ *
1741
+ * Resolves the LNURL-pay endpoint to a BOLT11 invoice and pays it. Errors
1742
+ * if the link decodes to a non-pay LNURL (auth, withdraw, channel).
1743
+ */
1744
+ payLnurl(lnurl: string, amountSats: bigint, comment: string | undefined, wait?: boolean, asyncOpts_?: {
2805
1745
  signal: AbortSignal;
2806
1746
  }): Promise<LightningSendStatus>;
2807
1747
  peekAddress(index: number, asyncOpts_?: {
@@ -2854,7 +1794,7 @@ export declare class Wallet extends UniffiAbstractObject implements WalletLike {
2854
1794
  }): Promise<void>;
2855
1795
  sendArkoorPayment(arkAddress: string, amountSats: bigint, asyncOpts_?: {
2856
1796
  signal: AbortSignal;
2857
- }): Promise<string>;
1797
+ }): Promise<void>;
2858
1798
  sendOnchain(address: string, amountSats: bigint, asyncOpts_?: {
2859
1799
  signal: AbortSignal;
2860
1800
  }): Promise<string>;
@@ -2882,13 +1822,23 @@ export declare class Wallet extends UniffiAbstractObject implements WalletLike {
2882
1822
  syncExits(onchainWallet: OnchainWalletLike, asyncOpts_?: {
2883
1823
  signal: AbortSignal;
2884
1824
  }): Promise<void>;
1825
+ /**
1826
+ * Scan for VTXOs that were force-exited on-chain without the user asking
1827
+ * and route them into the unilateral-exit flow so the funds can be claimed.
1828
+ *
1829
+ * This already runs automatically as part of [`Self::sync`]; call it
1830
+ * directly to trigger the scan on demand.
1831
+ */
1832
+ syncForceExitedVtxos(asyncOpts_?: {
1833
+ signal: AbortSignal;
1834
+ }): Promise<void>;
2885
1835
  syncPendingBoards(asyncOpts_?: {
2886
1836
  signal: AbortSignal;
2887
1837
  }): Promise<void>;
2888
- tryClaimAllLightningReceives(wait: boolean, asyncOpts_?: {
1838
+ tryClaimAllLightningReceives(wait?: boolean, asyncOpts_?: {
2889
1839
  signal: AbortSignal;
2890
1840
  }): Promise<Array<LightningReceive>>;
2891
- tryClaimLightningReceive(paymentHash: string, wait: boolean, asyncOpts_?: {
1841
+ tryClaimLightningReceive(paymentHash: string, wait?: boolean, asyncOpts_?: {
2892
1842
  signal: AbortSignal;
2893
1843
  }): Promise<void>;
2894
1844
  validateArkoorAddress(address: string, asyncOpts_?: {
@@ -2938,13 +1888,6 @@ declare const _default: Readonly<{
2938
1888
  lift(value: Uint8Array): Balance;
2939
1889
  lower(value: Balance): Uint8Array;
2940
1890
  };
2941
- FfiConverterTypeBarkError: {
2942
- read(from: RustBuffer): BarkError;
2943
- write(value: BarkError, into: RustBuffer): void;
2944
- allocationSize(value: BarkError): number;
2945
- lift(value: Uint8Array): BarkError;
2946
- lower(value: BarkError): Uint8Array;
2947
- };
2948
1891
  FfiConverterTypeBarkLogger: FfiConverterObjectWithCallbacks<BarkLogger>;
2949
1892
  FfiConverterTypeBlockRef: {
2950
1893
  read(from: RustBuffer): BlockRef;
@@ -2975,6 +1918,93 @@ declare const _default: Readonly<{
2975
1918
  lift(value: Uint8Array): Destination;
2976
1919
  lower(value: Destination): Uint8Array;
2977
1920
  };
1921
+ FfiConverterTypeError: {
1922
+ read(from: RustBuffer): {
1923
+ readonly tag: Exception_Tags.Inner;
1924
+ /**
1925
+ * @private
1926
+ * This field is private and should not be used.
1927
+ */
1928
+ readonly [uniffiTypeNameSymbol]: string;
1929
+ /**
1930
+ * @private
1931
+ * This field is private and should not be used.
1932
+ */
1933
+ readonly [variantOrdinalSymbol]: 1;
1934
+ name: string;
1935
+ message: string;
1936
+ stack?: string | undefined;
1937
+ cause?: unknown;
1938
+ };
1939
+ write(value: {
1940
+ readonly tag: Exception_Tags.Inner;
1941
+ /**
1942
+ * @private
1943
+ * This field is private and should not be used.
1944
+ */
1945
+ readonly [uniffiTypeNameSymbol]: string;
1946
+ /**
1947
+ * @private
1948
+ * This field is private and should not be used.
1949
+ */
1950
+ readonly [variantOrdinalSymbol]: 1;
1951
+ name: string;
1952
+ message: string;
1953
+ stack?: string | undefined;
1954
+ cause?: unknown;
1955
+ }, into: RustBuffer): void;
1956
+ allocationSize(value: {
1957
+ readonly tag: Exception_Tags.Inner;
1958
+ /**
1959
+ * @private
1960
+ * This field is private and should not be used.
1961
+ */
1962
+ readonly [uniffiTypeNameSymbol]: string;
1963
+ /**
1964
+ * @private
1965
+ * This field is private and should not be used.
1966
+ */
1967
+ readonly [variantOrdinalSymbol]: 1;
1968
+ name: string;
1969
+ message: string;
1970
+ stack?: string | undefined;
1971
+ cause?: unknown;
1972
+ }): number;
1973
+ lift(value: Uint8Array): {
1974
+ readonly tag: Exception_Tags.Inner;
1975
+ /**
1976
+ * @private
1977
+ * This field is private and should not be used.
1978
+ */
1979
+ readonly [uniffiTypeNameSymbol]: string;
1980
+ /**
1981
+ * @private
1982
+ * This field is private and should not be used.
1983
+ */
1984
+ readonly [variantOrdinalSymbol]: 1;
1985
+ name: string;
1986
+ message: string;
1987
+ stack?: string | undefined;
1988
+ cause?: unknown;
1989
+ };
1990
+ lower(value: {
1991
+ readonly tag: Exception_Tags.Inner;
1992
+ /**
1993
+ * @private
1994
+ * This field is private and should not be used.
1995
+ */
1996
+ readonly [uniffiTypeNameSymbol]: string;
1997
+ /**
1998
+ * @private
1999
+ * This field is private and should not be used.
2000
+ */
2001
+ readonly [variantOrdinalSymbol]: 1;
2002
+ name: string;
2003
+ message: string;
2004
+ stack?: string | undefined;
2005
+ cause?: unknown;
2006
+ }): Uint8Array;
2007
+ };
2978
2008
  FfiConverterTypeExitClaimTransaction: {
2979
2009
  read(from: RustBuffer): ExitClaimTransaction;
2980
2010
  write(value: ExitClaimTransaction, into: RustBuffer): void;
@@ -3111,6 +2141,13 @@ declare const _default: Readonly<{
3111
2141
  lift(value: Uint8Array): WalletNotification;
3112
2142
  lower(value: WalletNotification): Uint8Array;
3113
2143
  };
2144
+ FfiConverterTypeWalletOpenArgs: {
2145
+ read(from: RustBuffer): WalletOpenArgs;
2146
+ write(value: WalletOpenArgs, into: RustBuffer): void;
2147
+ allocationSize(value: WalletOpenArgs): number;
2148
+ lift(value: Uint8Array): WalletOpenArgs;
2149
+ lower(value: WalletOpenArgs): Uint8Array;
2150
+ };
3114
2151
  FfiConverterTypeWalletProperties: {
3115
2152
  read(from: RustBuffer): WalletProperties;
3116
2153
  write(value: WalletProperties, into: RustBuffer): void;