@breeztech/breez-sdk-spark 0.15.1 → 0.16.1-dev1

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.
Files changed (51) hide show
  1. package/breez-sdk-spark.tgz +0 -0
  2. package/bundler/breez_sdk_spark_wasm.d.ts +511 -215
  3. package/bundler/breez_sdk_spark_wasm.js +1 -1
  4. package/bundler/breez_sdk_spark_wasm_bg.js +567 -414
  5. package/bundler/breez_sdk_spark_wasm_bg.wasm +0 -0
  6. package/bundler/breez_sdk_spark_wasm_bg.wasm.d.ts +55 -46
  7. package/bundler/storage/index.js +205 -15
  8. package/deno/breez_sdk_spark_wasm.d.ts +511 -215
  9. package/deno/breez_sdk_spark_wasm.js +567 -414
  10. package/deno/breez_sdk_spark_wasm_bg.wasm +0 -0
  11. package/deno/breez_sdk_spark_wasm_bg.wasm.d.ts +55 -46
  12. package/nodejs/breez_sdk_spark_wasm.d.ts +511 -215
  13. package/nodejs/breez_sdk_spark_wasm.js +578 -421
  14. package/nodejs/breez_sdk_spark_wasm_bg.wasm +0 -0
  15. package/nodejs/breez_sdk_spark_wasm_bg.wasm.d.ts +55 -46
  16. package/nodejs/index.js +10 -10
  17. package/nodejs/index.mjs +12 -8
  18. package/nodejs/mysql-session-store/errors.cjs +13 -0
  19. package/nodejs/{mysql-session-manager → mysql-session-store}/index.cjs +24 -21
  20. package/nodejs/{mysql-session-manager → mysql-session-store}/migrations.cjs +17 -11
  21. package/nodejs/mysql-session-store/package.json +9 -0
  22. package/nodejs/mysql-storage/index.cjs +229 -111
  23. package/nodejs/mysql-storage/migrations.cjs +37 -2
  24. package/nodejs/mysql-token-store/index.cjs +99 -79
  25. package/nodejs/mysql-token-store/migrations.cjs +59 -2
  26. package/nodejs/mysql-tree-store/index.cjs +15 -9
  27. package/nodejs/mysql-tree-store/migrations.cjs +16 -2
  28. package/nodejs/package.json +2 -2
  29. package/nodejs/postgres-session-store/errors.cjs +13 -0
  30. package/nodejs/{postgres-session-manager → postgres-session-store}/index.cjs +23 -23
  31. package/nodejs/{postgres-session-manager → postgres-session-store}/migrations.cjs +14 -14
  32. package/nodejs/postgres-session-store/package.json +9 -0
  33. package/nodejs/postgres-storage/index.cjs +174 -107
  34. package/nodejs/postgres-storage/migrations.cjs +24 -0
  35. package/nodejs/postgres-token-store/index.cjs +89 -64
  36. package/nodejs/postgres-token-store/migrations.cjs +44 -0
  37. package/nodejs/storage/index.cjs +167 -113
  38. package/nodejs/storage/migrations.cjs +23 -0
  39. package/package.json +6 -1
  40. package/ssr/index.js +52 -28
  41. package/web/breez_sdk_spark_wasm.d.ts +566 -261
  42. package/web/breez_sdk_spark_wasm.js +567 -414
  43. package/web/breez_sdk_spark_wasm_bg.wasm +0 -0
  44. package/web/breez_sdk_spark_wasm_bg.wasm.d.ts +55 -46
  45. package/web/passkey-prf-provider/index.d.ts +203 -0
  46. package/web/passkey-prf-provider/index.js +733 -0
  47. package/web/storage/index.js +205 -15
  48. package/nodejs/mysql-session-manager/errors.cjs +0 -13
  49. package/nodejs/mysql-session-manager/package.json +0 -9
  50. package/nodejs/postgres-session-manager/errors.cjs +0 -13
  51. package/nodejs/postgres-session-manager/package.json +0 -9
@@ -110,18 +110,19 @@ class BreezSdk {
110
110
  return ret;
111
111
  }
112
112
  /**
113
- * @param {BuyBitcoinRequest} request
114
- * @returns {Promise<BuyBitcoinResponse>}
113
+ * @param {AuthorizeTransferRequest} request
114
+ * @returns {Promise<TransferAuthorization>}
115
115
  */
116
- buyBitcoin(request) {
117
- const ret = wasm.breezsdk_buyBitcoin(this.__wbg_ptr, request);
116
+ authorizeLightningAddressTransfer(request) {
117
+ const ret = wasm.breezsdk_authorizeLightningAddressTransfer(this.__wbg_ptr, request);
118
118
  return ret;
119
119
  }
120
120
  /**
121
- * @returns {Promise<void>}
121
+ * @param {BuyBitcoinRequest} request
122
+ * @returns {Promise<BuyBitcoinResponse>}
122
123
  */
123
- cancelLeafOptimization() {
124
- const ret = wasm.breezsdk_cancelLeafOptimization(this.__wbg_ptr);
124
+ buyBitcoin(request) {
125
+ const ret = wasm.breezsdk_buyBitcoin(this.__wbg_ptr, request);
125
126
  return ret;
126
127
  }
127
128
  /**
@@ -156,6 +157,14 @@ class BreezSdk {
156
157
  const ret = wasm.breezsdk_claimHtlcPayment(this.__wbg_ptr, request);
157
158
  return ret;
158
159
  }
160
+ /**
161
+ * @param {ClaimTransferRequest} request
162
+ * @returns {Promise<LightningAddressInfo>}
163
+ */
164
+ claimLightningAddressTransfer(request) {
165
+ const ret = wasm.breezsdk_claimLightningAddressTransfer(this.__wbg_ptr, request);
166
+ return ret;
167
+ }
159
168
  /**
160
169
  * @param {string} id
161
170
  * @returns {Promise<void>}
@@ -196,13 +205,6 @@ class BreezSdk {
196
205
  const ret = wasm.breezsdk_getInfo(this.__wbg_ptr, request);
197
206
  return ret;
198
207
  }
199
- /**
200
- * @returns {OptimizationProgress}
201
- */
202
- getLeafOptimizationProgress() {
203
- const ret = wasm.breezsdk_getLeafOptimizationProgress(this.__wbg_ptr);
204
- return ret;
205
- }
206
208
  /**
207
209
  * @returns {Promise<LightningAddressInfo | undefined>}
208
210
  */
@@ -309,6 +311,14 @@ class BreezSdk {
309
311
  const ret = wasm.breezsdk_lnurlWithdraw(this.__wbg_ptr, request);
310
312
  return ret;
311
313
  }
314
+ /**
315
+ * @param {OptimizeLeavesRequest} request
316
+ * @returns {Promise<OptimizeLeavesResponse>}
317
+ */
318
+ optimizeLeaves(request) {
319
+ const ret = wasm.breezsdk_optimizeLeaves(this.__wbg_ptr, request);
320
+ return ret;
321
+ }
312
322
  /**
313
323
  * @param {string} input
314
324
  * @returns {Promise<InputType>}
@@ -407,13 +417,6 @@ class BreezSdk {
407
417
  const ret = wasm.breezsdk_signMessage(this.__wbg_ptr, request);
408
418
  return ret;
409
419
  }
410
- /**
411
- * @returns {Promise<void>}
412
- */
413
- startLeafOptimization() {
414
- const ret = wasm.breezsdk_startLeafOptimization(this.__wbg_ptr);
415
- return ret;
416
- }
417
420
  /**
418
421
  * @param {SyncWalletRequest} request
419
422
  * @returns {Promise<SyncWalletResponse>}
@@ -451,33 +454,28 @@ if (Symbol.dispose) BreezSdk.prototype[Symbol.dispose] = BreezSdk.prototype.free
451
454
  exports.BreezSdk = BreezSdk;
452
455
 
453
456
  /**
454
- * A default signer implementation that wraps the core SDK's ExternalSigner.
455
- * This is returned by `defaultExternalSigner` and can be passed to `connectWithSigner`.
457
+ * A Rust-backed [`ExternalBreezSigner`] surfaced to JS as a signer object that
458
+ * can be passed to `connectWithSigner` or `SdkBuilder.newWithSigner`. Produced
459
+ * by `defaultExternalSigners` (seed) and `createTurnkeySigner` (Turnkey).
460
+ *
461
+ * [`ExternalBreezSigner`]: breez_sdk_spark::signer::ExternalBreezSigner
456
462
  */
457
- class DefaultSigner {
463
+ class ExternalBreezSignerHandle {
458
464
  static __wrap(ptr) {
459
- const obj = Object.create(DefaultSigner.prototype);
465
+ const obj = Object.create(ExternalBreezSignerHandle.prototype);
460
466
  obj.__wbg_ptr = ptr;
461
- DefaultSignerFinalization.register(obj, obj.__wbg_ptr, obj);
467
+ ExternalBreezSignerHandleFinalization.register(obj, obj.__wbg_ptr, obj);
462
468
  return obj;
463
469
  }
464
470
  __destroy_into_raw() {
465
471
  const ptr = this.__wbg_ptr;
466
472
  this.__wbg_ptr = 0;
467
- DefaultSignerFinalization.unregister(this);
473
+ ExternalBreezSignerHandleFinalization.unregister(this);
468
474
  return ptr;
469
475
  }
470
476
  free() {
471
477
  const ptr = this.__destroy_into_raw();
472
- wasm.__wbg_defaultsigner_free(ptr, 0);
473
- }
474
- /**
475
- * @param {ExternalAggregateFrostRequest} request
476
- * @returns {Promise<ExternalFrostSignature>}
477
- */
478
- aggregateFrost(request) {
479
- const ret = wasm.defaultsigner_aggregateFrost(this.__wbg_ptr, request);
480
- return ret;
478
+ wasm.__wbg_externalbreezsignerhandle_free(ptr, 0);
481
479
  }
482
480
  /**
483
481
  * @param {Uint8Array} message
@@ -489,7 +487,7 @@ class DefaultSigner {
489
487
  const len0 = WASM_VECTOR_LEN;
490
488
  const ptr1 = passStringToWasm0(path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
491
489
  const len1 = WASM_VECTOR_LEN;
492
- const ret = wasm.defaultsigner_decryptEcies(this.__wbg_ptr, ptr0, len0, ptr1, len1);
490
+ const ret = wasm.externalbreezsignerhandle_decryptEcies(this.__wbg_ptr, ptr0, len0, ptr1, len1);
493
491
  return ret;
494
492
  }
495
493
  /**
@@ -499,7 +497,7 @@ class DefaultSigner {
499
497
  derivePublicKey(path) {
500
498
  const ptr0 = passStringToWasm0(path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
501
499
  const len0 = WASM_VECTOR_LEN;
502
- const ret = wasm.defaultsigner_derivePublicKey(this.__wbg_ptr, ptr0, len0);
500
+ const ret = wasm.externalbreezsignerhandle_derivePublicKey(this.__wbg_ptr, ptr0, len0);
503
501
  return ret;
504
502
  }
505
503
  /**
@@ -512,38 +510,7 @@ class DefaultSigner {
512
510
  const len0 = WASM_VECTOR_LEN;
513
511
  const ptr1 = passStringToWasm0(path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
514
512
  const len1 = WASM_VECTOR_LEN;
515
- const ret = wasm.defaultsigner_encryptEcies(this.__wbg_ptr, ptr0, len0, ptr1, len1);
516
- return ret;
517
- }
518
- /**
519
- * @param {ExternalEncryptedSecret} private_key
520
- * @param {PublicKeyBytes} receiver_public_key
521
- * @returns {Promise<Uint8Array>}
522
- */
523
- encryptPrivateKeyForReceiver(private_key, receiver_public_key) {
524
- const ret = wasm.defaultsigner_encryptPrivateKeyForReceiver(this.__wbg_ptr, private_key, receiver_public_key);
525
- return ret;
526
- }
527
- /**
528
- * @returns {Promise<ExternalEncryptedSecret>}
529
- */
530
- generateRandomSecret() {
531
- const ret = wasm.defaultsigner_generateRandomSecret(this.__wbg_ptr);
532
- return ret;
533
- }
534
- /**
535
- * @returns {Promise<ExternalFrostCommitments>}
536
- */
537
- generateRandomSigningCommitment() {
538
- const ret = wasm.defaultsigner_generateRandomSigningCommitment(this.__wbg_ptr);
539
- return ret;
540
- }
541
- /**
542
- * @param {ExternalTreeNodeId} id
543
- * @returns {Promise<PublicKeyBytes>}
544
- */
545
- getPublicKeyForNode(id) {
546
- const ret = wasm.defaultsigner_getPublicKeyForNode(this.__wbg_ptr, id);
513
+ const ret = wasm.externalbreezsignerhandle_encryptEcies(this.__wbg_ptr, ptr0, len0, ptr1, len1);
547
514
  return ret;
548
515
  }
549
516
  /**
@@ -556,25 +523,7 @@ class DefaultSigner {
556
523
  const len0 = WASM_VECTOR_LEN;
557
524
  const ptr1 = passStringToWasm0(path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
558
525
  const len1 = WASM_VECTOR_LEN;
559
- const ret = wasm.defaultsigner_hmacSha256(this.__wbg_ptr, ptr0, len0, ptr1, len1);
560
- return ret;
561
- }
562
- /**
563
- * @returns {PublicKeyBytes}
564
- */
565
- identityPublicKey() {
566
- const ret = wasm.defaultsigner_identityPublicKey(this.__wbg_ptr);
567
- if (ret[2]) {
568
- throw takeFromExternrefTable0(ret[1]);
569
- }
570
- return takeFromExternrefTable0(ret[0]);
571
- }
572
- /**
573
- * @param {ExternalSecretSource} private_key
574
- * @returns {Promise<PublicKeyBytes>}
575
- */
576
- publicKeyFromSecret(private_key) {
577
- const ret = wasm.defaultsigner_publicKeyFromSecret(this.__wbg_ptr, private_key);
526
+ const ret = wasm.externalbreezsignerhandle_hmacSha256(this.__wbg_ptr, ptr0, len0, ptr1, len1);
578
527
  return ret;
579
528
  }
580
529
  /**
@@ -585,7 +534,7 @@ class DefaultSigner {
585
534
  signEcdsa(message, path) {
586
535
  const ptr0 = passStringToWasm0(path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
587
536
  const len0 = WASM_VECTOR_LEN;
588
- const ret = wasm.defaultsigner_signEcdsa(this.__wbg_ptr, message, ptr0, len0);
537
+ const ret = wasm.externalbreezsignerhandle_signEcdsa(this.__wbg_ptr, message, ptr0, len0);
589
538
  return ret;
590
539
  }
591
540
  /**
@@ -596,15 +545,7 @@ class DefaultSigner {
596
545
  signEcdsaRecoverable(message, path) {
597
546
  const ptr0 = passStringToWasm0(path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
598
547
  const len0 = WASM_VECTOR_LEN;
599
- const ret = wasm.defaultsigner_signEcdsaRecoverable(this.__wbg_ptr, message, ptr0, len0);
600
- return ret;
601
- }
602
- /**
603
- * @param {ExternalSignFrostRequest} request
604
- * @returns {Promise<ExternalFrostSignatureShare>}
605
- */
606
- signFrost(request) {
607
- const ret = wasm.defaultsigner_signFrost(this.__wbg_ptr, request);
548
+ const ret = wasm.externalbreezsignerhandle_signEcdsaRecoverable(this.__wbg_ptr, message, ptr0, len0);
608
549
  return ret;
609
550
  }
610
551
  /**
@@ -617,55 +558,208 @@ class DefaultSigner {
617
558
  const len0 = WASM_VECTOR_LEN;
618
559
  const ptr1 = passStringToWasm0(path, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
619
560
  const len1 = WASM_VECTOR_LEN;
620
- const ret = wasm.defaultsigner_signHashSchnorr(this.__wbg_ptr, ptr0, len0, ptr1, len1);
561
+ const ret = wasm.externalbreezsignerhandle_signHashSchnorr(this.__wbg_ptr, ptr0, len0, ptr1, len1);
621
562
  return ret;
622
563
  }
564
+ }
565
+ if (Symbol.dispose) ExternalBreezSignerHandle.prototype[Symbol.dispose] = ExternalBreezSignerHandle.prototype.free;
566
+ exports.ExternalBreezSignerHandle = ExternalBreezSignerHandle;
567
+
568
+ /**
569
+ * The two external signers for the SDK's signer-based connect. Returned by
570
+ * `defaultExternalSigners` (seed) and `createTurnkeySigner` (Turnkey); pass
571
+ * both halves to `connectWithSigner` or `SdkBuilder.newWithSigner`.
572
+ */
573
+ class ExternalSigners {
574
+ static __wrap(ptr) {
575
+ const obj = Object.create(ExternalSigners.prototype);
576
+ obj.__wbg_ptr = ptr;
577
+ ExternalSignersFinalization.register(obj, obj.__wbg_ptr, obj);
578
+ return obj;
579
+ }
580
+ __destroy_into_raw() {
581
+ const ptr = this.__wbg_ptr;
582
+ this.__wbg_ptr = 0;
583
+ ExternalSignersFinalization.unregister(this);
584
+ return ptr;
585
+ }
586
+ free() {
587
+ const ptr = this.__destroy_into_raw();
588
+ wasm.__wbg_externalsigners_free(ptr, 0);
589
+ }
623
590
  /**
624
- * @param {ExternalSecretToSplit} secret
625
- * @param {number} threshold
626
- * @param {number} num_shares
627
- * @returns {Promise<ExternalVerifiableSecretShare[]>}
591
+ * External signer for non-Spark SDK signing (LNURL-auth, sync, message
592
+ * signing, ECIES).
593
+ * @returns {ExternalBreezSignerHandle}
628
594
  */
629
- splitSecretWithProofs(secret, threshold, num_shares) {
630
- const ret = wasm.defaultsigner_splitSecretWithProofs(this.__wbg_ptr, secret, threshold, num_shares);
631
- return ret;
595
+ get breezSigner() {
596
+ const ret = wasm.externalsigners_breezSigner(this.__wbg_ptr);
597
+ return ExternalBreezSignerHandle.__wrap(ret);
632
598
  }
633
599
  /**
634
- * @param {number} index
635
- * @returns {Promise<SecretBytes>}
600
+ * External high-level Spark signer for the Spark wallet flows.
601
+ * @returns {ExternalSparkSignerHandle}
636
602
  */
637
- staticDepositSecret(index) {
638
- const ret = wasm.defaultsigner_staticDepositSecret(this.__wbg_ptr, index);
603
+ get sparkSigner() {
604
+ const ret = wasm.externalsigners_sparkSigner(this.__wbg_ptr);
605
+ return ExternalSparkSignerHandle.__wrap(ret);
606
+ }
607
+ }
608
+ if (Symbol.dispose) ExternalSigners.prototype[Symbol.dispose] = ExternalSigners.prototype.free;
609
+ exports.ExternalSigners = ExternalSigners;
610
+
611
+ /**
612
+ * A Rust-backed [`ExternalSparkSigner`] surfaced to JS as a signer object that
613
+ * can be passed to `connectWithSigner` or `SdkBuilder.newWithSigner`. Produced
614
+ * by `defaultExternalSigners` (seed) and `createTurnkeySigner` (Turnkey).
615
+ *
616
+ * [`ExternalSparkSigner`]: breez_sdk_spark::signer::ExternalSparkSigner
617
+ */
618
+ class ExternalSparkSignerHandle {
619
+ static __wrap(ptr) {
620
+ const obj = Object.create(ExternalSparkSignerHandle.prototype);
621
+ obj.__wbg_ptr = ptr;
622
+ ExternalSparkSignerHandleFinalization.register(obj, obj.__wbg_ptr, obj);
623
+ return obj;
624
+ }
625
+ __destroy_into_raw() {
626
+ const ptr = this.__wbg_ptr;
627
+ this.__wbg_ptr = 0;
628
+ ExternalSparkSignerHandleFinalization.unregister(this);
629
+ return ptr;
630
+ }
631
+ free() {
632
+ const ptr = this.__destroy_into_raw();
633
+ wasm.__wbg_externalsparksignerhandle_free(ptr, 0);
634
+ }
635
+ /**
636
+ * @returns {Promise<PublicKeyBytes>}
637
+ */
638
+ getIdentityPublicKey() {
639
+ const ret = wasm.externalsparksignerhandle_getIdentityPublicKey(this.__wbg_ptr);
639
640
  return ret;
640
641
  }
641
642
  /**
642
- * @param {number} index
643
- * @returns {Promise<ExternalSecretSource>}
643
+ * @param {ExternalTreeNodeId} leaf_id
644
+ * @returns {Promise<PublicKeyBytes>}
644
645
  */
645
- staticDepositSecretEncrypted(index) {
646
- const ret = wasm.defaultsigner_staticDepositSecretEncrypted(this.__wbg_ptr, index);
646
+ getPublicKeyForLeaf(leaf_id) {
647
+ const ret = wasm.externalsparksignerhandle_getPublicKeyForLeaf(this.__wbg_ptr, leaf_id);
647
648
  return ret;
648
649
  }
649
650
  /**
650
651
  * @param {number} index
651
652
  * @returns {Promise<PublicKeyBytes>}
652
653
  */
653
- staticDepositSigningKey(index) {
654
- const ret = wasm.defaultsigner_staticDepositSigningKey(this.__wbg_ptr, index);
654
+ getStaticDepositPublicKey(index) {
655
+ const ret = wasm.externalsparksignerhandle_getStaticDepositPublicKey(this.__wbg_ptr, index);
656
+ return ret;
657
+ }
658
+ /**
659
+ * @param {ExternalPrepareClaimRequest} request
660
+ * @returns {Promise<ExternalPreparedClaim>}
661
+ */
662
+ prepareClaim(request) {
663
+ const ret = wasm.externalsparksignerhandle_prepareClaim(this.__wbg_ptr, request);
664
+ return ret;
665
+ }
666
+ /**
667
+ * @param {ExternalPrepareLightningReceiveRequest} request
668
+ * @returns {Promise<ExternalPreparedLightningReceive>}
669
+ */
670
+ prepareLightningReceive(request) {
671
+ const ret = wasm.externalsparksignerhandle_prepareLightningReceive(this.__wbg_ptr, request);
672
+ return ret;
673
+ }
674
+ /**
675
+ * @param {ExternalPrepareStaticDepositRequest} request
676
+ * @returns {Promise<ExternalPreparedStaticDeposit>}
677
+ */
678
+ prepareStaticDeposit(request) {
679
+ const ret = wasm.externalsparksignerhandle_prepareStaticDeposit(this.__wbg_ptr, request);
680
+ return ret;
681
+ }
682
+ /**
683
+ * @param {ExternalPrepareStaticDepositClaimRequest} request
684
+ * @returns {Promise<ExternalPreparedStaticDepositClaim>}
685
+ */
686
+ prepareStaticDepositClaim(request) {
687
+ const ret = wasm.externalsparksignerhandle_prepareStaticDepositClaim(this.__wbg_ptr, request);
688
+ return ret;
689
+ }
690
+ /**
691
+ * @param {ExternalPrepareTokenTransactionRequest} request
692
+ * @returns {Promise<ExternalPreparedTokenTransaction>}
693
+ */
694
+ prepareTokenTransaction(request) {
695
+ const ret = wasm.externalsparksignerhandle_prepareTokenTransaction(this.__wbg_ptr, request);
696
+ return ret;
697
+ }
698
+ /**
699
+ * @param {ExternalPrepareTransferRequest} request
700
+ * @returns {Promise<ExternalPreparedTransfer>}
701
+ */
702
+ prepareTransfer(request) {
703
+ const ret = wasm.externalsparksignerhandle_prepareTransfer(this.__wbg_ptr, request);
704
+ return ret;
705
+ }
706
+ /**
707
+ * @param {Uint8Array} challenge
708
+ * @returns {Promise<EcdsaSignatureBytes>}
709
+ */
710
+ signAuthenticationChallenge(challenge) {
711
+ const ptr0 = passArray8ToWasm0(challenge, wasm.__wbindgen_malloc);
712
+ const len0 = WASM_VECTOR_LEN;
713
+ const ret = wasm.externalsparksignerhandle_signAuthenticationChallenge(this.__wbg_ptr, ptr0, len0);
714
+ return ret;
715
+ }
716
+ /**
717
+ * @param {ExternalFrostJob[]} jobs
718
+ * @returns {Promise<ExternalFrostShareResult[]>}
719
+ */
720
+ signFrost(jobs) {
721
+ const ptr0 = passArrayJsValueToWasm0(jobs, wasm.__wbindgen_malloc);
722
+ const len0 = WASM_VECTOR_LEN;
723
+ const ret = wasm.externalsparksignerhandle_signFrost(this.__wbg_ptr, ptr0, len0);
724
+ return ret;
725
+ }
726
+ /**
727
+ * @param {Uint8Array} message
728
+ * @returns {Promise<EcdsaSignatureBytes>}
729
+ */
730
+ signMessage(message) {
731
+ const ptr0 = passArray8ToWasm0(message, wasm.__wbindgen_malloc);
732
+ const len0 = WASM_VECTOR_LEN;
733
+ const ret = wasm.externalsparksignerhandle_signMessage(this.__wbg_ptr, ptr0, len0);
655
734
  return ret;
656
735
  }
657
736
  /**
658
- * @param {ExternalSecretSource} signing_key
659
- * @param {ExternalSecretSource} new_signing_key
660
- * @returns {Promise<ExternalSecretSource>}
737
+ * @param {ExternalSignSparkInvoiceRequest} request
738
+ * @returns {Promise<ExternalSignedSparkInvoice>}
739
+ */
740
+ signSparkInvoice(request) {
741
+ const ret = wasm.externalsparksignerhandle_signSparkInvoice(this.__wbg_ptr, request);
742
+ return ret;
743
+ }
744
+ /**
745
+ * @param {ExternalSignStaticDepositRefundRequest} request
746
+ * @returns {Promise<ExternalFrostSignature>}
661
747
  */
662
- subtractSecrets(signing_key, new_signing_key) {
663
- const ret = wasm.defaultsigner_subtractSecrets(this.__wbg_ptr, signing_key, new_signing_key);
748
+ signStaticDepositRefund(request) {
749
+ const ret = wasm.externalsparksignerhandle_signStaticDepositRefund(this.__wbg_ptr, request);
750
+ return ret;
751
+ }
752
+ /**
753
+ * @param {ExternalStartStaticDepositRefundRequest} request
754
+ * @returns {Promise<ExternalStartedStaticDepositRefund>}
755
+ */
756
+ startStaticDepositRefund(request) {
757
+ const ret = wasm.externalsparksignerhandle_startStaticDepositRefund(this.__wbg_ptr, request);
664
758
  return ret;
665
759
  }
666
760
  }
667
- if (Symbol.dispose) DefaultSigner.prototype[Symbol.dispose] = DefaultSigner.prototype.free;
668
- exports.DefaultSigner = DefaultSigner;
761
+ if (Symbol.dispose) ExternalSparkSignerHandle.prototype[Symbol.dispose] = ExternalSparkSignerHandle.prototype.free;
762
+ exports.ExternalSparkSignerHandle = ExternalSparkSignerHandle;
669
763
 
670
764
  class IntoUnderlyingByteSource {
671
765
  __destroy_into_raw() {
@@ -782,143 +876,124 @@ if (Symbol.dispose) IntoUnderlyingSource.prototype[Symbol.dispose] = IntoUnderly
782
876
  exports.IntoUnderlyingSource = IntoUnderlyingSource;
783
877
 
784
878
  /**
785
- * A shareable `MySQL` connection pool. See
786
- * [`PostgresConnectionPool`](super::postgres_pool::PostgresConnectionPool)
787
- * for sharing semantics and lifecycle.
879
+ * High-level orchestrator that collapses register / sign-in flows
880
+ * into single calls. See the matching Rust types for full semantics;
881
+ * the JS surface is a thin wasm-bindgen wrapper.
788
882
  */
789
- class MysqlConnectionPool {
790
- static __wrap(ptr) {
791
- const obj = Object.create(MysqlConnectionPool.prototype);
792
- obj.__wbg_ptr = ptr;
793
- MysqlConnectionPoolFinalization.register(obj, obj.__wbg_ptr, obj);
794
- return obj;
795
- }
883
+ class PasskeyClient {
796
884
  __destroy_into_raw() {
797
885
  const ptr = this.__wbg_ptr;
798
886
  this.__wbg_ptr = 0;
799
- MysqlConnectionPoolFinalization.unregister(this);
887
+ PasskeyClientFinalization.unregister(this);
800
888
  return ptr;
801
889
  }
802
890
  free() {
803
891
  const ptr = this.__destroy_into_raw();
804
- wasm.__wbg_mysqlconnectionpool_free(ptr, 0);
805
- }
806
- }
807
- if (Symbol.dispose) MysqlConnectionPool.prototype[Symbol.dispose] = MysqlConnectionPool.prototype.free;
808
- exports.MysqlConnectionPool = MysqlConnectionPool;
809
-
810
- /**
811
- * Passkey-based wallet operations using WebAuthn PRF extension.
812
- *
813
- * Wraps a `PasskeyPrfProvider` and optional relay configuration to provide
814
- * wallet derivation and label management via Nostr relays.
815
- */
816
- class Passkey {
817
- __destroy_into_raw() {
818
- const ptr = this.__wbg_ptr;
819
- this.__wbg_ptr = 0;
820
- PasskeyFinalization.unregister(this);
821
- return ptr;
822
- }
823
- free() {
824
- const ptr = this.__destroy_into_raw();
825
- wasm.__wbg_passkey_free(ptr, 0);
892
+ wasm.__wbg_passkeyclient_free(ptr, 0);
826
893
  }
827
894
  /**
828
- * Derive a wallet for a given label.
829
- *
830
- * Uses the passkey PRF to derive a `Wallet` containing the seed and resolved label.
831
- *
832
- * @param label - Optional label string (defaults to "Default")
833
- * @param {string | null} [label]
834
- * @returns {Promise<Wallet>}
895
+ * One-shot capability probe (PRF support + domain association)
896
+ * hosts can gate UX on.
897
+ * @returns {Promise<PasskeyAvailability>}
835
898
  */
836
- getWallet(label) {
837
- var ptr0 = isLikeNone(label) ? 0 : passStringToWasm0(label, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
838
- var len0 = WASM_VECTOR_LEN;
839
- const ret = wasm.passkey_getWallet(this.__wbg_ptr, ptr0, len0);
899
+ checkAvailability() {
900
+ const ret = wasm.passkeyclient_checkAvailability(this.__wbg_ptr);
840
901
  return ret;
841
902
  }
842
903
  /**
843
- * Check if passkey PRF is available on this device.
844
- * @returns {Promise<boolean>}
904
+ * Label sub-object. List / publish labels for this passkey's identity.
905
+ * @returns {PasskeyLabels}
845
906
  */
846
- isAvailable() {
847
- const ret = wasm.passkey_isAvailable(this.__wbg_ptr);
848
- return ret;
907
+ labels() {
908
+ const ret = wasm.passkeyclient_labels(this.__wbg_ptr);
909
+ return PasskeyLabels.__wrap(ret);
849
910
  }
850
911
  /**
851
- * List all labels published to Nostr for this passkey's identity.
852
- *
853
- * Requires 1 PRF call (for Nostr identity derivation).
854
- * @returns {Promise<string[]>}
912
+ * Create a `PasskeyClient` backed by the supplied `PrfProvider` and
913
+ * the default Nostr-backed label store. `breezApiKey` enables
914
+ * authenticated (NIP-42) relay access for label storage; omit for
915
+ * public relays only.
916
+ * @param {PrfProvider} prf_provider
917
+ * @param {string | null} [breez_api_key]
918
+ * @param {PasskeyConfig | null} [config]
855
919
  */
856
- listLabels() {
857
- const ret = wasm.passkey_listLabels(this.__wbg_ptr);
858
- return ret;
920
+ constructor(prf_provider, breez_api_key, config) {
921
+ var ptr0 = isLikeNone(breez_api_key) ? 0 : passStringToWasm0(breez_api_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
922
+ var len0 = WASM_VECTOR_LEN;
923
+ const ret = wasm.passkeyclient_new(prf_provider, ptr0, len0, isLikeNone(config) ? 0 : addToExternrefTable0(config));
924
+ this.__wbg_ptr = ret;
925
+ PasskeyClientFinalization.register(this, this.__wbg_ptr, this);
926
+ return this;
859
927
  }
860
928
  /**
861
- * Create a new `Passkey` instance.
862
- *
863
- * @param prfProvider - Platform implementation of passkey PRF operations
864
- * @param relayConfig - Optional configuration for Nostr relay connections
865
- * @param {PasskeyPrfProvider} prf_provider
866
- * @param {NostrRelayConfig | null} [relay_config]
929
+ * First-time setup. Drives the platform's create-passkey ceremony
930
+ * then derives the wallet seed in the same PRF assertion ceremony
931
+ * where the platform supports it.
932
+ * @param {RegisterRequest} request
933
+ * @returns {Promise<RegisterResponse>}
867
934
  */
868
- constructor(prf_provider, relay_config) {
869
- const ret = wasm.passkey_new(prf_provider, isLikeNone(relay_config) ? 0 : addToExternrefTable0(relay_config));
870
- this.__wbg_ptr = ret;
871
- PasskeyFinalization.register(this, this.__wbg_ptr, this);
872
- return this;
935
+ register(request) {
936
+ const ret = wasm.passkeyclient_register(this.__wbg_ptr, request);
937
+ return ret;
873
938
  }
874
939
  /**
875
- * Publish a label to Nostr relays for this passkey's identity.
876
- *
877
- * Idempotent: if the label already exists, it is not published again.
878
- * Requires 1 PRF call.
879
- * @param {string} label
880
- * @returns {Promise<void>}
940
+ * Returning-user sign-in. With `label` set, uses the fast path
941
+ * (one ceremony, no Nostr round-trip). With `label` omitted,
942
+ * derives the default-label wallet and discovers the user's
943
+ * label set in the same ceremony.
944
+ * @param {SignInRequest} request
945
+ * @returns {Promise<SignInResponse>}
881
946
  */
882
- storeLabel(label) {
883
- const ptr0 = passStringToWasm0(label, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
884
- const len0 = WASM_VECTOR_LEN;
885
- const ret = wasm.passkey_storeLabel(this.__wbg_ptr, ptr0, len0);
947
+ signIn(request) {
948
+ const ret = wasm.passkeyclient_signIn(this.__wbg_ptr, request);
886
949
  return ret;
887
950
  }
888
951
  }
889
- if (Symbol.dispose) Passkey.prototype[Symbol.dispose] = Passkey.prototype.free;
890
- exports.Passkey = Passkey;
952
+ if (Symbol.dispose) PasskeyClient.prototype[Symbol.dispose] = PasskeyClient.prototype.free;
953
+ exports.PasskeyClient = PasskeyClient;
891
954
 
892
955
  /**
893
- * A shareable Postgres connection pool.
894
- *
895
- * Construct via [`create_postgres_connection_pool`] and pass the same handle to multiple
896
- * `SdkBuilder`s via `withPostgresConnectionPool` to share connections across SDKs.
897
- * Per-tenant scoping is derived from each SDK's seed.
898
- *
899
- * The pool's lifecycle is controlled by the integrator: it stays alive as
900
- * long as any reference is held. `disconnect()` does **not** close the pool.
956
+ * Label sub-object surfaced from `PasskeyClient.labels()`.
901
957
  */
902
- class PostgresConnectionPool {
958
+ class PasskeyLabels {
903
959
  static __wrap(ptr) {
904
- const obj = Object.create(PostgresConnectionPool.prototype);
960
+ const obj = Object.create(PasskeyLabels.prototype);
905
961
  obj.__wbg_ptr = ptr;
906
- PostgresConnectionPoolFinalization.register(obj, obj.__wbg_ptr, obj);
962
+ PasskeyLabelsFinalization.register(obj, obj.__wbg_ptr, obj);
907
963
  return obj;
908
964
  }
909
965
  __destroy_into_raw() {
910
966
  const ptr = this.__wbg_ptr;
911
967
  this.__wbg_ptr = 0;
912
- PostgresConnectionPoolFinalization.unregister(this);
968
+ PasskeyLabelsFinalization.unregister(this);
913
969
  return ptr;
914
970
  }
915
971
  free() {
916
972
  const ptr = this.__destroy_into_raw();
917
- wasm.__wbg_postgresconnectionpool_free(ptr, 0);
973
+ wasm.__wbg_passkeylabels_free(ptr, 0);
974
+ }
975
+ /**
976
+ * List labels published for this passkey's identity.
977
+ * @returns {Promise<string[]>}
978
+ */
979
+ list() {
980
+ const ret = wasm.passkeylabels_list(this.__wbg_ptr);
981
+ return ret;
982
+ }
983
+ /**
984
+ * Idempotently publish `label` for this passkey's identity.
985
+ * @param {string} label
986
+ * @returns {Promise<void>}
987
+ */
988
+ store(label) {
989
+ const ptr0 = passStringToWasm0(label, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
990
+ const len0 = WASM_VECTOR_LEN;
991
+ const ret = wasm.passkeylabels_store(this.__wbg_ptr, ptr0, len0);
992
+ return ret;
918
993
  }
919
994
  }
920
- if (Symbol.dispose) PostgresConnectionPool.prototype[Symbol.dispose] = PostgresConnectionPool.prototype.free;
921
- exports.PostgresConnectionPool = PostgresConnectionPool;
995
+ if (Symbol.dispose) PasskeyLabels.prototype[Symbol.dispose] = PasskeyLabels.prototype.free;
996
+ exports.PasskeyLabels = PasskeyLabels;
922
997
 
923
998
  class SdkBuilder {
924
999
  static __wrap(ptr) {
@@ -956,11 +1031,21 @@ class SdkBuilder {
956
1031
  }
957
1032
  /**
958
1033
  * @param {Config} config
959
- * @param {ExternalSigner} signer
1034
+ * @param {ExternalBreezSigner} breez_signer
1035
+ * @param {ExternalSparkSigner} spark_signer
1036
+ * @returns {SdkBuilder}
1037
+ */
1038
+ static newWithSigner(config, breez_signer, spark_signer) {
1039
+ const ret = wasm.sdkbuilder_newWithSigner(config, breez_signer, spark_signer);
1040
+ return SdkBuilder.__wrap(ret);
1041
+ }
1042
+ /**
1043
+ * @param {number} account_number
960
1044
  * @returns {SdkBuilder}
961
1045
  */
962
- static newWithSigner(config, signer) {
963
- const ret = wasm.sdkbuilder_newWithSigner(config, signer);
1046
+ withAccountNumber(account_number) {
1047
+ const ptr = this.__destroy_into_raw();
1048
+ const ret = wasm.sdkbuilder_withAccountNumber(ptr, account_number);
964
1049
  return SdkBuilder.__wrap(ret);
965
1050
  }
966
1051
  /**
@@ -992,15 +1077,6 @@ class SdkBuilder {
992
1077
  const ret = wasm.sdkbuilder_withFiatService(ptr, fiat_service);
993
1078
  return SdkBuilder.__wrap(ret);
994
1079
  }
995
- /**
996
- * @param {KeySetConfig} config
997
- * @returns {SdkBuilder}
998
- */
999
- withKeySet(config) {
1000
- const ptr = this.__destroy_into_raw();
1001
- const ret = wasm.sdkbuilder_withKeySet(ptr, config);
1002
- return SdkBuilder.__wrap(ret);
1003
- }
1004
1080
  /**
1005
1081
  * @param {RestClient} lnurl_client
1006
1082
  * @returns {SdkBuilder}
@@ -1011,8 +1087,7 @@ class SdkBuilder {
1011
1087
  return SdkBuilder.__wrap(ret);
1012
1088
  }
1013
1089
  /**
1014
- * **Deprecated.** Call `createMysqlConnectionPool(config)` and
1015
- * `withMysqlConnectionPool(pool)` instead.
1090
+ * **Deprecated.** Use `withStorageBackend(mysqlStorage(config))`.
1016
1091
  * @param {MysqlStorageConfig} config
1017
1092
  * @returns {SdkBuilder}
1018
1093
  */
@@ -1024,20 +1099,6 @@ class SdkBuilder {
1024
1099
  }
1025
1100
  return SdkBuilder.__wrap(ret[0]);
1026
1101
  }
1027
- /**
1028
- * Sets a shared `MySQL` connection pool as the backend for all stores.
1029
- *
1030
- * If the same builder also receives a `WasmSdkContext` carrying a MySQL
1031
- * pool, `build()` returns an error — pick one source.
1032
- * @param {MysqlConnectionPool} pool
1033
- * @returns {SdkBuilder}
1034
- */
1035
- withMysqlConnectionPool(pool) {
1036
- const ptr = this.__destroy_into_raw();
1037
- _assertClass(pool, MysqlConnectionPool);
1038
- const ret = wasm.sdkbuilder_withMysqlConnectionPool(ptr, pool.__wbg_ptr);
1039
- return SdkBuilder.__wrap(ret);
1040
- }
1041
1102
  /**
1042
1103
  * @param {PaymentObserver} payment_observer
1043
1104
  * @returns {SdkBuilder}
@@ -1048,8 +1109,7 @@ class SdkBuilder {
1048
1109
  return SdkBuilder.__wrap(ret);
1049
1110
  }
1050
1111
  /**
1051
- * **Deprecated.** Call `createPostgresConnectionPool(config)` and
1052
- * `withPostgresConnectionPool(pool)` instead.
1112
+ * **Deprecated.** Use `withStorageBackend(postgresStorage(config))`.
1053
1113
  * @param {PostgresStorageConfig} config
1054
1114
  * @returns {SdkBuilder}
1055
1115
  */
@@ -1061,20 +1121,6 @@ class SdkBuilder {
1061
1121
  }
1062
1122
  return SdkBuilder.__wrap(ret[0]);
1063
1123
  }
1064
- /**
1065
- * Sets a shared Postgres connection pool as the backend for all stores.
1066
- *
1067
- * If the same builder also receives a `WasmSdkContext` carrying a
1068
- * Postgres pool, `build()` returns an error — pick one source.
1069
- * @param {PostgresConnectionPool} pool
1070
- * @returns {SdkBuilder}
1071
- */
1072
- withPostgresConnectionPool(pool) {
1073
- const ptr = this.__destroy_into_raw();
1074
- _assertClass(pool, PostgresConnectionPool);
1075
- const ret = wasm.sdkbuilder_withPostgresConnectionPool(ptr, pool.__wbg_ptr);
1076
- return SdkBuilder.__wrap(ret);
1077
- }
1078
1124
  /**
1079
1125
  * @param {string} url
1080
1126
  * @param {ChainApiType} api_type
@@ -1112,6 +1158,21 @@ class SdkBuilder {
1112
1158
  const ret = wasm.sdkbuilder_withStorage(ptr, storage);
1113
1159
  return SdkBuilder.__wrap(ret);
1114
1160
  }
1161
+ /**
1162
+ * Sets one of the SDK's built-in storage backends.
1163
+ *
1164
+ * Construct the [`WasmStorageConfig`] via `defaultStorage`,
1165
+ * `postgresStorage` or `mysqlStorage`.
1166
+ * @param {WasmStorageConfig} config
1167
+ * @returns {SdkBuilder}
1168
+ */
1169
+ withStorageBackend(config) {
1170
+ const ptr = this.__destroy_into_raw();
1171
+ _assertClass(config, WasmStorageConfig);
1172
+ var ptr0 = config.__destroy_into_raw();
1173
+ const ret = wasm.sdkbuilder_withStorageBackend(ptr, ptr0);
1174
+ return SdkBuilder.__wrap(ret);
1175
+ }
1115
1176
  }
1116
1177
  if (Symbol.dispose) SdkBuilder.prototype[Symbol.dispose] = SdkBuilder.prototype.free;
1117
1178
  exports.SdkBuilder = SdkBuilder;
@@ -1219,6 +1280,33 @@ class WasmSdkContext {
1219
1280
  if (Symbol.dispose) WasmSdkContext.prototype[Symbol.dispose] = WasmSdkContext.prototype.free;
1220
1281
  exports.WasmSdkContext = WasmSdkContext;
1221
1282
 
1283
+ /**
1284
+ * Selects one of the SDK's built-in storage backends.
1285
+ *
1286
+ * Construct it via `defaultStorage`, `postgresStorage` or `mysqlStorage` and
1287
+ * pass it to `SdkBuilder.withStorageBackend`.
1288
+ */
1289
+ class WasmStorageConfig {
1290
+ static __wrap(ptr) {
1291
+ const obj = Object.create(WasmStorageConfig.prototype);
1292
+ obj.__wbg_ptr = ptr;
1293
+ WasmStorageConfigFinalization.register(obj, obj.__wbg_ptr, obj);
1294
+ return obj;
1295
+ }
1296
+ __destroy_into_raw() {
1297
+ const ptr = this.__wbg_ptr;
1298
+ this.__wbg_ptr = 0;
1299
+ WasmStorageConfigFinalization.unregister(this);
1300
+ return ptr;
1301
+ }
1302
+ free() {
1303
+ const ptr = this.__destroy_into_raw();
1304
+ wasm.__wbg_wasmstorageconfig_free(ptr, 0);
1305
+ }
1306
+ }
1307
+ if (Symbol.dispose) WasmStorageConfig.prototype[Symbol.dispose] = WasmStorageConfig.prototype.free;
1308
+ exports.WasmStorageConfig = WasmStorageConfig;
1309
+
1222
1310
  /**
1223
1311
  * @param {ConnectRequest} request
1224
1312
  * @returns {Promise<BreezSdk>}
@@ -1231,45 +1319,31 @@ exports.connect = connect;
1231
1319
 
1232
1320
  /**
1233
1321
  * @param {Config} config
1234
- * @param {ExternalSigner} signer
1322
+ * @param {ExternalBreezSigner} breez_signer
1323
+ * @param {ExternalSparkSigner} spark_signer
1235
1324
  * @param {string} storage_dir
1236
1325
  * @returns {Promise<BreezSdk>}
1237
1326
  */
1238
- function connectWithSigner(config, signer, storage_dir) {
1327
+ function connectWithSigner(config, breez_signer, spark_signer, storage_dir) {
1239
1328
  const ptr0 = passStringToWasm0(storage_dir, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1240
1329
  const len0 = WASM_VECTOR_LEN;
1241
- const ret = wasm.connectWithSigner(config, signer, ptr0, len0);
1330
+ const ret = wasm.connectWithSigner(config, breez_signer, spark_signer, ptr0, len0);
1242
1331
  return ret;
1243
1332
  }
1244
1333
  exports.connectWithSigner = connectWithSigner;
1245
1334
 
1246
1335
  /**
1247
- * Creates a shareable `MySQL` connection pool from the given config.
1248
- * @param {MysqlStorageConfig} config
1249
- * @returns {MysqlConnectionPool}
1250
- */
1251
- function createMysqlConnectionPool(config) {
1252
- const ret = wasm.createMysqlConnectionPool(config);
1253
- if (ret[2]) {
1254
- throw takeFromExternrefTable0(ret[1]);
1255
- }
1256
- return MysqlConnectionPool.__wrap(ret[0]);
1257
- }
1258
- exports.createMysqlConnectionPool = createMysqlConnectionPool;
1259
-
1260
- /**
1261
- * Creates a shareable Postgres connection pool from the given config.
1262
- * @param {PostgresStorageConfig} config
1263
- * @returns {PostgresConnectionPool}
1336
+ * Builds the Turnkey-backed signers from `config`, then pass
1337
+ * `signers.breezSigner` and `signers.sparkSigner` to `connectWithSigner`,
1338
+ * exactly as with any other external signer.
1339
+ * @param {TurnkeyConfig} config
1340
+ * @returns {Promise<ExternalSigners>}
1264
1341
  */
1265
- function createPostgresConnectionPool(config) {
1266
- const ret = wasm.createPostgresConnectionPool(config);
1267
- if (ret[2]) {
1268
- throw takeFromExternrefTable0(ret[1]);
1269
- }
1270
- return PostgresConnectionPool.__wrap(ret[0]);
1342
+ function createTurnkeySigner(config) {
1343
+ const ret = wasm.createTurnkeySigner(config);
1344
+ return ret;
1271
1345
  }
1272
- exports.createPostgresConnectionPool = createPostgresConnectionPool;
1346
+ exports.createTurnkeySigner = createTurnkeySigner;
1273
1347
 
1274
1348
  /**
1275
1349
  * @param {Network} network
@@ -1282,24 +1356,28 @@ function defaultConfig(network) {
1282
1356
  exports.defaultConfig = defaultConfig;
1283
1357
 
1284
1358
  /**
1359
+ * Creates the default external signers from a mnemonic phrase.
1360
+ *
1361
+ * Key derivation matches the seed-based connect path: an SDK built either
1362
+ * way from the same mnemonic is the same wallet.
1285
1363
  * @param {string} mnemonic
1286
1364
  * @param {string | null | undefined} passphrase
1287
1365
  * @param {Network} network
1288
- * @param {KeySetConfig | null} [key_set_config]
1289
- * @returns {DefaultSigner}
1366
+ * @param {number | null} [account_number]
1367
+ * @returns {ExternalSigners}
1290
1368
  */
1291
- function defaultExternalSigner(mnemonic, passphrase, network, key_set_config) {
1369
+ function defaultExternalSigners(mnemonic, passphrase, network, account_number) {
1292
1370
  const ptr0 = passStringToWasm0(mnemonic, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1293
1371
  const len0 = WASM_VECTOR_LEN;
1294
1372
  var ptr1 = isLikeNone(passphrase) ? 0 : passStringToWasm0(passphrase, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1295
1373
  var len1 = WASM_VECTOR_LEN;
1296
- const ret = wasm.defaultExternalSigner(ptr0, len0, ptr1, len1, network, isLikeNone(key_set_config) ? 0 : addToExternrefTable0(key_set_config));
1374
+ const ret = wasm.defaultExternalSigners(ptr0, len0, ptr1, len1, network, isLikeNone(account_number) ? Number.MAX_SAFE_INTEGER : (account_number) >>> 0);
1297
1375
  if (ret[2]) {
1298
1376
  throw takeFromExternrefTable0(ret[1]);
1299
1377
  }
1300
- return DefaultSigner.__wrap(ret[0]);
1378
+ return ExternalSigners.__wrap(ret[0]);
1301
1379
  }
1302
- exports.defaultExternalSigner = defaultExternalSigner;
1380
+ exports.defaultExternalSigners = defaultExternalSigners;
1303
1381
 
1304
1382
  /**
1305
1383
  * Creates a default MySQL storage configuration with sensible defaults.
@@ -1349,9 +1427,20 @@ function defaultServerConfig(network) {
1349
1427
  exports.defaultServerConfig = defaultServerConfig;
1350
1428
 
1351
1429
  /**
1352
- * Creates a default external signer from a mnemonic phrase.
1353
- *
1354
- * This creates a signer that can be used with `connectWithSigner` or `SdkBuilder.newWithSigner`.
1430
+ * File-based storage rooted at `storageDir` IndexedDB in the browser,
1431
+ * SQLite under Node.js.
1432
+ * @param {string} storage_dir
1433
+ * @returns {WasmStorageConfig}
1434
+ */
1435
+ function defaultStorage(storage_dir) {
1436
+ const ptr0 = passStringToWasm0(storage_dir, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1437
+ const len0 = WASM_VECTOR_LEN;
1438
+ const ret = wasm.defaultStorage(ptr0, len0);
1439
+ return WasmStorageConfig.__wrap(ret);
1440
+ }
1441
+ exports.defaultStorage = defaultStorage;
1442
+
1443
+ /**
1355
1444
  * @returns {Promise<SparkStatus>}
1356
1445
  */
1357
1446
  function getSparkStatus() {
@@ -1373,6 +1462,17 @@ function initLogging(logger, filter) {
1373
1462
  }
1374
1463
  exports.initLogging = initLogging;
1375
1464
 
1465
+ /**
1466
+ * `MySQL`-backed storage built from `config`.
1467
+ * @param {MysqlStorageConfig} config
1468
+ * @returns {WasmStorageConfig}
1469
+ */
1470
+ function mysqlStorage(config) {
1471
+ const ret = wasm.mysqlStorage(config);
1472
+ return WasmStorageConfig.__wrap(ret);
1473
+ }
1474
+ exports.mysqlStorage = mysqlStorage;
1475
+
1376
1476
  /**
1377
1477
  * Constructs a shareable REST-based Bitcoin chain service.
1378
1478
  *
@@ -1406,6 +1506,17 @@ function newSharedSdkContext(config) {
1406
1506
  }
1407
1507
  exports.newSharedSdkContext = newSharedSdkContext;
1408
1508
 
1509
+ /**
1510
+ * `PostgreSQL`-backed storage built from `config`.
1511
+ * @param {PostgresStorageConfig} config
1512
+ * @returns {WasmStorageConfig}
1513
+ */
1514
+ function postgresStorage(config) {
1515
+ const ret = wasm.postgresStorage(config);
1516
+ return WasmStorageConfig.__wrap(ret);
1517
+ }
1518
+ exports.postgresStorage = postgresStorage;
1519
+
1409
1520
  /**
1410
1521
  * Entry point invoked by JavaScript in a worker.
1411
1522
  * @param {number} ptr
@@ -1548,13 +1659,19 @@ function __wbg_get_imports() {
1548
1659
  const ret = arg0.addLeaves(arg1);
1549
1660
  return ret;
1550
1661
  }, arguments); },
1551
- __wbg_aggregateFrost_8eb928d3bf25ad91: function() { return handleError(function (arg0, arg1) {
1552
- const ret = arg0.aggregateFrost(arg1);
1662
+ __wbg_afterSend_465a6d26048f7342: function() { return handleError(function (arg0, arg1, arg2) {
1663
+ var v0 = getArrayJsValueFromWasm0(arg1, arg2).slice();
1664
+ wasm.__wbindgen_free(arg1, arg2 * 4, 4);
1665
+ const ret = arg0.afterSend(v0);
1553
1666
  return ret;
1554
1667
  }, arguments); },
1555
1668
  __wbg_append_8df396311184f750: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1556
1669
  arg0.append(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
1557
1670
  }, arguments); },
1671
+ __wbg_applyPaymentUpdate_8526d773e5ac8314: function() { return handleError(function (arg0, arg1) {
1672
+ const ret = arg0.applyPaymentUpdate(arg1);
1673
+ return ret;
1674
+ }, arguments); },
1558
1675
  __wbg_arrayBuffer_87e3ac06d961f7a0: function() { return handleError(function (arg0) {
1559
1676
  const ret = arg0.arrayBuffer();
1560
1677
  return ret;
@@ -1678,8 +1795,8 @@ function __wbg_get_imports() {
1678
1795
  const ret = createMysqlPool(arg0);
1679
1796
  return ret;
1680
1797
  }, arguments); },
1681
- __wbg_createMysqlSessionManagerWithPool_81f4147900a5a954: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1682
- const ret = createMysqlSessionManagerWithPool(arg0, getArrayU8FromWasm0(arg1, arg2), arg3, arg4 !== 0);
1798
+ __wbg_createMysqlSessionStoreWithPool_52192c9b2932ff7c: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1799
+ const ret = createMysqlSessionStoreWithPool(arg0, getArrayU8FromWasm0(arg1, arg2), arg3, arg4 !== 0);
1683
1800
  return ret;
1684
1801
  }, arguments); },
1685
1802
  __wbg_createMysqlStorageWithPool_22d23b0d068eae47: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
@@ -1694,12 +1811,16 @@ function __wbg_get_imports() {
1694
1811
  const ret = createMysqlTreeStoreWithPool(arg0, getArrayU8FromWasm0(arg1, arg2), arg3, arg4, arg5 !== 0);
1695
1812
  return ret;
1696
1813
  }, arguments); },
1814
+ __wbg_createPasskey_5ceae054474c582a: function() { return handleError(function (arg0, arg1) {
1815
+ const ret = arg0.createPasskey(arg1);
1816
+ return ret;
1817
+ }, arguments); },
1697
1818
  __wbg_createPostgresPool_3c396c7ab2f0eab2: function() { return handleError(function (arg0) {
1698
1819
  const ret = createPostgresPool(arg0);
1699
1820
  return ret;
1700
1821
  }, arguments); },
1701
- __wbg_createPostgresSessionManagerWithPool_989bf80d96829c18: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1702
- const ret = createPostgresSessionManagerWithPool(arg0, getArrayU8FromWasm0(arg1, arg2), arg3, arg4 !== 0);
1822
+ __wbg_createPostgresSessionStoreWithPool_dd76c7c3517d7bd0: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1823
+ const ret = createPostgresSessionStoreWithPool(arg0, getArrayU8FromWasm0(arg1, arg2), arg3, arg4 !== 0);
1703
1824
  return ret;
1704
1825
  }, arguments); },
1705
1826
  __wbg_createPostgresStorageWithPool_9408116e32ab58f8: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
@@ -1722,6 +1843,20 @@ function __wbg_get_imports() {
1722
1843
  const ret = arg0.data;
1723
1844
  return ret;
1724
1845
  },
1846
+ __wbg_decryptEcies_ebe426814020926b: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1847
+ let deferred1_0;
1848
+ let deferred1_1;
1849
+ try {
1850
+ var v0 = getArrayU8FromWasm0(arg1, arg2).slice();
1851
+ wasm.__wbindgen_free(arg1, arg2 * 1, 1);
1852
+ deferred1_0 = arg3;
1853
+ deferred1_1 = arg4;
1854
+ const ret = arg0.decryptEcies(v0, getStringFromWasm0(arg3, arg4));
1855
+ return ret;
1856
+ } finally {
1857
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
1858
+ }
1859
+ }, arguments); },
1725
1860
  __wbg_deleteCachedItem_b8fbe3ebea21ed7e: function() { return handleError(function (arg0, arg1, arg2) {
1726
1861
  let deferred0_0;
1727
1862
  let deferred0_1;
@@ -1775,19 +1910,7 @@ function __wbg_get_imports() {
1775
1910
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
1776
1911
  }
1777
1912
  }, arguments); },
1778
- __wbg_derivePrfSeed_7a4ec7d929c9bcca: function() { return handleError(function (arg0, arg1, arg2) {
1779
- let deferred0_0;
1780
- let deferred0_1;
1781
- try {
1782
- deferred0_0 = arg1;
1783
- deferred0_1 = arg2;
1784
- const ret = arg0.derivePrfSeed(getStringFromWasm0(arg1, arg2));
1785
- return ret;
1786
- } finally {
1787
- wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
1788
- }
1789
- }, arguments); },
1790
- __wbg_derivePublicKey_bab57284cd981e9a: function() { return handleError(function (arg0, arg1, arg2) {
1913
+ __wbg_derivePublicKey_1bc53f60dc792488: function() { return handleError(function (arg0, arg1, arg2) {
1791
1914
  let deferred0_0;
1792
1915
  let deferred0_1;
1793
1916
  try {
@@ -1799,25 +1922,15 @@ function __wbg_get_imports() {
1799
1922
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
1800
1923
  }
1801
1924
  }, arguments); },
1925
+ __wbg_deriveSeeds_5c331613e2894c56: function() { return handleError(function (arg0, arg1, arg2) {
1926
+ const ret = arg0.deriveSeeds(arg1, arg2);
1927
+ return ret;
1928
+ }, arguments); },
1802
1929
  __wbg_done_b1afd6201ac045e0: function(arg0) {
1803
1930
  const ret = arg0.done;
1804
1931
  return ret;
1805
1932
  },
1806
- __wbg_eciesDecrypt_986d793295625dc9: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1807
- let deferred1_0;
1808
- let deferred1_1;
1809
- try {
1810
- var v0 = getArrayU8FromWasm0(arg1, arg2).slice();
1811
- wasm.__wbindgen_free(arg1, arg2 * 1, 1);
1812
- deferred1_0 = arg3;
1813
- deferred1_1 = arg4;
1814
- const ret = arg0.eciesDecrypt(v0, getStringFromWasm0(arg3, arg4));
1815
- return ret;
1816
- } finally {
1817
- wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
1818
- }
1819
- }, arguments); },
1820
- __wbg_eciesEncrypt_95486f45d5d74f6a: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1933
+ __wbg_encryptEcies_6a990da1c19d1f7c: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
1821
1934
  let deferred1_0;
1822
1935
  let deferred1_1;
1823
1936
  try {
@@ -1825,16 +1938,12 @@ function __wbg_get_imports() {
1825
1938
  wasm.__wbindgen_free(arg1, arg2 * 1, 1);
1826
1939
  deferred1_0 = arg3;
1827
1940
  deferred1_1 = arg4;
1828
- const ret = arg0.eciesEncrypt(v0, getStringFromWasm0(arg3, arg4));
1941
+ const ret = arg0.encryptEcies(v0, getStringFromWasm0(arg3, arg4));
1829
1942
  return ret;
1830
1943
  } finally {
1831
1944
  wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
1832
1945
  }
1833
1946
  }, arguments); },
1834
- __wbg_encryptPrivateKeyForReceiver_a5414ece502e2eec: function() { return handleError(function (arg0, arg1, arg2) {
1835
- const ret = arg0.encryptPrivateKeyForReceiver(arg1, arg2);
1836
- return ret;
1837
- }, arguments); },
1838
1947
  __wbg_enqueue_6c7cd543c0f3828e: function() { return handleError(function (arg0, arg1) {
1839
1948
  arg0.enqueue(arg1);
1840
1949
  }, arguments); },
@@ -1845,6 +1954,10 @@ function __wbg_get_imports() {
1845
1954
  __wbg_error_145dadf4216d70bc: function(arg0, arg1) {
1846
1955
  console.error(getStringFromWasm0(arg0, arg1));
1847
1956
  },
1957
+ __wbg_externalsigners_new: function(arg0) {
1958
+ const ret = ExternalSigners.__wrap(arg0);
1959
+ return ret;
1960
+ },
1848
1961
  __wbg_fetchFiatCurrencies_8afa0468f01bf013: function() { return handleError(function (arg0) {
1849
1962
  const ret = arg0.fetchFiatCurrencies();
1850
1963
  return ret;
@@ -1893,14 +2006,10 @@ function __wbg_get_imports() {
1893
2006
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
1894
2007
  }
1895
2008
  }, arguments); },
1896
- __wbg_generateFrostSigningCommitments_1e8b83b2bed675c9: function() { return handleError(function (arg0) {
1897
- const ret = arg0.generateFrostSigningCommitments();
2009
+ __wbg_from_ff141b1e4c69b979: function(arg0) {
2010
+ const ret = Array.from(arg0);
1898
2011
  return ret;
1899
- }, arguments); },
1900
- __wbg_generateRandomSecret_432432761a2594b7: function() { return handleError(function (arg0) {
1901
- const ret = arg0.generateRandomSecret();
1902
- return ret;
1903
- }, arguments); },
2012
+ },
1904
2013
  __wbg_getAddressUtxos_9526b6d8078b867e: function() { return handleError(function (arg0, arg1, arg2) {
1905
2014
  let deferred0_0;
1906
2015
  let deferred0_1;
@@ -1941,6 +2050,10 @@ function __wbg_get_imports() {
1941
2050
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
1942
2051
  }
1943
2052
  }, arguments); },
2053
+ __wbg_getIdentityPublicKey_c6fcd87d66ed6927: function() { return handleError(function (arg0) {
2054
+ const ret = arg0.getIdentityPublicKey();
2055
+ return ret;
2056
+ }, arguments); },
1944
2057
  __wbg_getLeaves_5259dc2b9de80ff0: function() { return handleError(function (arg0) {
1945
2058
  const ret = arg0.getLeaves();
1946
2059
  return ret;
@@ -1975,12 +2088,8 @@ function __wbg_get_imports() {
1975
2088
  const ret = arg0.getPaymentsByParentIds(v0);
1976
2089
  return ret;
1977
2090
  }, arguments); },
1978
- __wbg_getPublicKeyForNode_1c1b34ec571148c2: function() { return handleError(function (arg0, arg1) {
1979
- const ret = arg0.getPublicKeyForNode(arg1);
1980
- return ret;
1981
- }, arguments); },
1982
- __wbg_getPublicKeyFromSecretSource_cecb0b3d2ce521bd: function() { return handleError(function (arg0, arg1) {
1983
- const ret = arg0.getPublicKeyFromSecretSource(arg1);
2091
+ __wbg_getPublicKeyForLeaf_9826724c9b0c3963: function() { return handleError(function (arg0, arg1) {
2092
+ const ret = arg0.getPublicKeyForLeaf(arg1);
1984
2093
  return ret;
1985
2094
  }, arguments); },
1986
2095
  __wbg_getRandomValues_c44a50d8cfdaebeb: function() { return handleError(function (arg0, arg1) {
@@ -2005,7 +2114,7 @@ function __wbg_get_imports() {
2005
2114
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2006
2115
  }
2007
2116
  }, arguments); },
2008
- __wbg_getSession_05b1be4bb146adcf: function() { return handleError(function (arg0, arg1, arg2) {
2117
+ __wbg_getSession_95998cc236a30653: function() { return handleError(function (arg0, arg1, arg2) {
2009
2118
  let deferred0_0;
2010
2119
  let deferred0_1;
2011
2120
  try {
@@ -2017,18 +2126,10 @@ function __wbg_get_imports() {
2017
2126
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2018
2127
  }
2019
2128
  }, arguments); },
2020
- __wbg_getStaticDepositPrivateKey_82943f7a0fe1208d: function() { return handleError(function (arg0, arg1) {
2021
- const ret = arg0.getStaticDepositPrivateKey(arg1 >>> 0);
2022
- return ret;
2023
- }, arguments); },
2024
- __wbg_getStaticDepositPublicKey_8424ddc7bb238008: function() { return handleError(function (arg0, arg1) {
2129
+ __wbg_getStaticDepositPublicKey_9c7c893612c4c53f: function() { return handleError(function (arg0, arg1) {
2025
2130
  const ret = arg0.getStaticDepositPublicKey(arg1 >>> 0);
2026
2131
  return ret;
2027
2132
  }, arguments); },
2028
- __wbg_getStaticDepositSecretSource_86007c41c79d2bea: function() { return handleError(function (arg0, arg1) {
2029
- const ret = arg0.getStaticDepositSecretSource(arg1 >>> 0);
2030
- return ret;
2031
- }, arguments); },
2032
2133
  __wbg_getTokenBalances_b788cda26e92f342: function() { return handleError(function (arg0) {
2033
2134
  const ret = arg0.getTokenBalances();
2034
2135
  return ret;
@@ -2061,6 +2162,10 @@ function __wbg_get_imports() {
2061
2162
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2062
2163
  }
2063
2164
  }, arguments); },
2165
+ __wbg_get_41476db20fef99a8: function() { return handleError(function (arg0, arg1) {
2166
+ const ret = Reflect.get(arg0, arg1);
2167
+ return ret;
2168
+ }, arguments); },
2064
2169
  __wbg_get_652f640b3b0b6e3e: function(arg0, arg1) {
2065
2170
  const ret = arg0[arg1 >>> 0];
2066
2171
  return ret;
@@ -2093,7 +2198,7 @@ function __wbg_get_imports() {
2093
2198
  const ret = arg0.headers;
2094
2199
  return ret;
2095
2200
  },
2096
- __wbg_hmacSha256_44b56787dc85796b: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
2201
+ __wbg_hmacSha256_04164bea6bd3c7d4: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
2097
2202
  let deferred1_0;
2098
2203
  let deferred1_1;
2099
2204
  try {
@@ -2107,10 +2212,6 @@ function __wbg_get_imports() {
2107
2212
  wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
2108
2213
  }
2109
2214
  }, arguments); },
2110
- __wbg_identityPublicKey_157f9d906d49e5c4: function() { return handleError(function (arg0) {
2111
- const ret = arg0.identityPublicKey();
2112
- return ret;
2113
- }, arguments); },
2114
2215
  __wbg_insertContact_cc39397cb8e88ff8: function() { return handleError(function (arg0, arg1) {
2115
2216
  const ret = arg0.insertContact(arg1);
2116
2217
  return ret;
@@ -2127,10 +2228,6 @@ function __wbg_get_imports() {
2127
2228
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2128
2229
  }
2129
2230
  }, arguments); },
2130
- __wbg_insertPayment_830c37c6efef1f8a: function() { return handleError(function (arg0, arg1) {
2131
- const ret = arg0.insertPayment(arg1);
2132
- return ret;
2133
- }, arguments); },
2134
2231
  __wbg_instanceof_ArrayBuffer_eab9f28fbec23477: function(arg0) {
2135
2232
  let result;
2136
2233
  try {
@@ -2215,14 +2312,14 @@ function __wbg_get_imports() {
2215
2312
  const ret = Array.isArray(arg0);
2216
2313
  return ret;
2217
2314
  },
2218
- __wbg_isPrfAvailable_f77f283e48e966e1: function() { return handleError(function (arg0) {
2219
- const ret = arg0.isPrfAvailable();
2220
- return ret;
2221
- }, arguments); },
2222
2315
  __wbg_isSafeInteger_3c56c421a5b4cce4: function(arg0) {
2223
2316
  const ret = Number.isSafeInteger(arg0);
2224
2317
  return ret;
2225
2318
  },
2319
+ __wbg_isSupported_0fab0220495a1089: function() { return handleError(function (arg0) {
2320
+ const ret = arg0.isSupported();
2321
+ return ret;
2322
+ }, arguments); },
2226
2323
  __wbg_iterator_9d68985a1d096fc2: function() {
2227
2324
  const ret = Symbol.iterator;
2228
2325
  return ret;
@@ -2423,6 +2520,30 @@ function __wbg_get_imports() {
2423
2520
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2424
2521
  }
2425
2522
  }, arguments); },
2523
+ __wbg_prepareClaim_1286899715876e7d: function() { return handleError(function (arg0, arg1) {
2524
+ const ret = arg0.prepareClaim(arg1);
2525
+ return ret;
2526
+ }, arguments); },
2527
+ __wbg_prepareLightningReceive_fe5b5a46a5d5d976: function() { return handleError(function (arg0, arg1) {
2528
+ const ret = arg0.prepareLightningReceive(arg1);
2529
+ return ret;
2530
+ }, arguments); },
2531
+ __wbg_prepareStaticDepositClaim_2aac4f9634448525: function() { return handleError(function (arg0, arg1) {
2532
+ const ret = arg0.prepareStaticDepositClaim(arg1);
2533
+ return ret;
2534
+ }, arguments); },
2535
+ __wbg_prepareStaticDeposit_66175a4078320749: function() { return handleError(function (arg0, arg1) {
2536
+ const ret = arg0.prepareStaticDeposit(arg1);
2537
+ return ret;
2538
+ }, arguments); },
2539
+ __wbg_prepareTokenTransaction_d2e097f1363077c0: function() { return handleError(function (arg0, arg1) {
2540
+ const ret = arg0.prepareTokenTransaction(arg1);
2541
+ return ret;
2542
+ }, arguments); },
2543
+ __wbg_prepareTransfer_f1fd01fccd18c85b: function() { return handleError(function (arg0, arg1) {
2544
+ const ret = arg0.prepareTransfer(arg1);
2545
+ return ret;
2546
+ }, arguments); },
2426
2547
  __wbg_process_44c7a14e11e9f69e: function(arg0) {
2427
2548
  const ret = arg0.process;
2428
2549
  return ret;
@@ -2430,6 +2551,10 @@ function __wbg_get_imports() {
2430
2551
  __wbg_prototypesetcall_fd4050e806e1d519: function(arg0, arg1, arg2) {
2431
2552
  Uint8Array.prototype.set.call(getArrayU8FromWasm0(arg0, arg1), arg2);
2432
2553
  },
2554
+ __wbg_push_60a5366c0bb22a7d: function(arg0, arg1) {
2555
+ const ret = arg0.push(arg1);
2556
+ return ret;
2557
+ },
2433
2558
  __wbg_queueMicrotask_40ac6ffc2848ba77: function(arg0) {
2434
2559
  queueMicrotask(arg0);
2435
2560
  },
@@ -2527,7 +2652,7 @@ function __wbg_get_imports() {
2527
2652
  const ret = arg0.setLnurlMetadata(v0);
2528
2653
  return ret;
2529
2654
  }, arguments); },
2530
- __wbg_setSession_35cb471ae7537391: function() { return handleError(function (arg0, arg1, arg2, arg3) {
2655
+ __wbg_setSession_86d7fef1f452677c: function() { return handleError(function (arg0, arg1, arg2, arg3) {
2531
2656
  let deferred0_0;
2532
2657
  let deferred0_1;
2533
2658
  try {
@@ -2619,7 +2744,13 @@ function __wbg_get_imports() {
2619
2744
  __wbg_set_signal_8c5cf4c3b27bd8a8: function(arg0, arg1) {
2620
2745
  arg0.signal = arg1;
2621
2746
  },
2622
- __wbg_signEcdsaRecoverable_e1e9c5e2c8ec869f: function() { return handleError(function (arg0, arg1, arg2, arg3) {
2747
+ __wbg_signAuthenticationChallenge_e2ea9cf87c76a6de: function() { return handleError(function (arg0, arg1, arg2) {
2748
+ var v0 = getArrayU8FromWasm0(arg1, arg2).slice();
2749
+ wasm.__wbindgen_free(arg1, arg2 * 1, 1);
2750
+ const ret = arg0.signAuthenticationChallenge(v0);
2751
+ return ret;
2752
+ }, arguments); },
2753
+ __wbg_signEcdsaRecoverable_978c5526e66a433b: function() { return handleError(function (arg0, arg1, arg2, arg3) {
2623
2754
  let deferred0_0;
2624
2755
  let deferred0_1;
2625
2756
  try {
@@ -2631,7 +2762,7 @@ function __wbg_get_imports() {
2631
2762
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2632
2763
  }
2633
2764
  }, arguments); },
2634
- __wbg_signEcdsa_99eb88e7d9907236: function() { return handleError(function (arg0, arg1, arg2, arg3) {
2765
+ __wbg_signEcdsa_1947a1a2c8f39a16: function() { return handleError(function (arg0, arg1, arg2, arg3) {
2635
2766
  let deferred0_0;
2636
2767
  let deferred0_1;
2637
2768
  try {
@@ -2643,11 +2774,11 @@ function __wbg_get_imports() {
2643
2774
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2644
2775
  }
2645
2776
  }, arguments); },
2646
- __wbg_signFrost_df3d96ac20619b95: function() { return handleError(function (arg0, arg1) {
2777
+ __wbg_signFrost_08951e01d00d4b1c: function() { return handleError(function (arg0, arg1) {
2647
2778
  const ret = arg0.signFrost(arg1);
2648
2779
  return ret;
2649
2780
  }, arguments); },
2650
- __wbg_signHashSchnorr_33c182cb4c2323d5: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
2781
+ __wbg_signHashSchnorr_fc8afda9a7ee021a: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
2651
2782
  let deferred1_0;
2652
2783
  let deferred1_1;
2653
2784
  try {
@@ -2661,12 +2792,26 @@ function __wbg_get_imports() {
2661
2792
  wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
2662
2793
  }
2663
2794
  }, arguments); },
2795
+ __wbg_signMessage_80ec0b0dfc7f00ee: function() { return handleError(function (arg0, arg1, arg2) {
2796
+ var v0 = getArrayU8FromWasm0(arg1, arg2).slice();
2797
+ wasm.__wbindgen_free(arg1, arg2 * 1, 1);
2798
+ const ret = arg0.signMessage(v0);
2799
+ return ret;
2800
+ }, arguments); },
2801
+ __wbg_signSparkInvoice_cca6c7f35b5e85d2: function() { return handleError(function (arg0, arg1) {
2802
+ const ret = arg0.signSparkInvoice(arg1);
2803
+ return ret;
2804
+ }, arguments); },
2805
+ __wbg_signStaticDepositRefund_3a6fb4e71a15bebd: function() { return handleError(function (arg0, arg1) {
2806
+ const ret = arg0.signStaticDepositRefund(arg1);
2807
+ return ret;
2808
+ }, arguments); },
2664
2809
  __wbg_signal_4643ce883b92b553: function(arg0) {
2665
2810
  const ret = arg0.signal;
2666
2811
  return ret;
2667
2812
  },
2668
- __wbg_splitSecretWithProofs_c9d51158a14af659: function() { return handleError(function (arg0, arg1, arg2, arg3) {
2669
- const ret = arg0.splitSecretWithProofs(arg1, arg2 >>> 0, arg3 >>> 0);
2813
+ __wbg_startStaticDepositRefund_5b591bbea22aa0d2: function() { return handleError(function (arg0, arg1) {
2814
+ const ret = arg0.startStaticDepositRefund(arg1);
2670
2815
  return ret;
2671
2816
  }, arguments); },
2672
2817
  __wbg_static_accessor_GLOBAL_THIS_1c7f1bd6c6941fdb: function() {
@@ -2697,10 +2842,6 @@ function __wbg_get_imports() {
2697
2842
  const ret = arg0.subarray(arg1 >>> 0, arg2 >>> 0);
2698
2843
  return ret;
2699
2844
  },
2700
- __wbg_subtractPrivateKeys_c66265ac85e781b7: function() { return handleError(function (arg0, arg1, arg2) {
2701
- const ret = arg0.subtractPrivateKeys(arg1, arg2);
2702
- return ret;
2703
- }, arguments); },
2704
2845
  __wbg_syncAddOutgoingChange_69db2a1430cbd55a: function() { return handleError(function (arg0, arg1) {
2705
2846
  const ret = arg0.syncAddOutgoingChange(arg1);
2706
2847
  return ret;
@@ -2837,48 +2978,48 @@ function __wbg_get_imports() {
2837
2978
  return ret;
2838
2979
  },
2839
2980
  __wbindgen_cast_0000000000000001: function(arg0, arg1) {
2840
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 16, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
2841
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21);
2981
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 17, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
2982
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c);
2842
2983
  return ret;
2843
2984
  },
2844
2985
  __wbindgen_cast_0000000000000002: function(arg0, arg1) {
2845
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 403, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2986
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 348, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2846
2987
  const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57);
2847
2988
  return ret;
2848
2989
  },
2849
2990
  __wbindgen_cast_0000000000000003: function(arg0, arg1) {
2850
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx: 403, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2991
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx: 348, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2851
2992
  const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_2);
2852
2993
  return ret;
2853
2994
  },
2854
2995
  __wbindgen_cast_0000000000000004: function(arg0, arg1) {
2855
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx: 403, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2996
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx: 348, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2856
2997
  const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_3);
2857
2998
  return ret;
2858
2999
  },
2859
3000
  __wbindgen_cast_0000000000000005: function(arg0, arg1) {
2860
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("SessionManager")], shim_idx: 16, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
2861
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_4);
3001
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("SessionStore")], shim_idx: 17, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
3002
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_4);
2862
3003
  return ret;
2863
3004
  },
2864
3005
  __wbindgen_cast_0000000000000006: function(arg0, arg1) {
2865
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("Storage")], shim_idx: 16, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
2866
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_5);
3006
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("Storage")], shim_idx: 17, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
3007
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_5);
2867
3008
  return ret;
2868
3009
  },
2869
3010
  __wbindgen_cast_0000000000000007: function(arg0, arg1) {
2870
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("TokenStore")], shim_idx: 16, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
2871
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_6);
3011
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("TokenStore")], shim_idx: 17, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
3012
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_6);
2872
3013
  return ret;
2873
3014
  },
2874
3015
  __wbindgen_cast_0000000000000008: function(arg0, arg1) {
2875
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("TreeStore")], shim_idx: 16, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
2876
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_7);
3016
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("TreeStore")], shim_idx: 17, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
3017
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_7);
2877
3018
  return ret;
2878
3019
  },
2879
3020
  __wbindgen_cast_0000000000000009: function(arg0, arg1) {
2880
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 408, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2881
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h124479769cd429fd);
3021
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 353, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
3022
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7);
2882
3023
  return ret;
2883
3024
  },
2884
3025
  __wbindgen_cast_000000000000000a: function(arg0) {
@@ -2921,7 +3062,7 @@ function __wbg_get_imports() {
2921
3062
  __wbindgen_cast_0000000000000011: function(arg0, arg1) {
2922
3063
  var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
2923
3064
  wasm.__wbindgen_free(arg0, arg1 * 4, 4);
2924
- // Cast intrinsic for `Vector(NamedExternref("ExternalVerifiableSecretShare")) -> Externref`.
3065
+ // Cast intrinsic for `Vector(NamedExternref("ExternalFrostShareResult")) -> Externref`.
2925
3066
  const ret = v0;
2926
3067
  return ret;
2927
3068
  },
@@ -2962,8 +3103,8 @@ function __wbg_get_imports() {
2962
3103
  };
2963
3104
  }
2964
3105
 
2965
- function wasm_bindgen__convert__closures_____invoke__h124479769cd429fd(arg0, arg1) {
2966
- wasm.wasm_bindgen__convert__closures_____invoke__h124479769cd429fd(arg0, arg1);
3106
+ function wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7(arg0, arg1) {
3107
+ wasm.wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7(arg0, arg1);
2967
3108
  }
2968
3109
 
2969
3110
  function wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57(arg0, arg1, arg2) {
@@ -2978,36 +3119,36 @@ function wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_3(arg0, a
2978
3119
  wasm.wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_3(arg0, arg1, arg2);
2979
3120
  }
2980
3121
 
2981
- function wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21(arg0, arg1, arg2) {
2982
- const ret = wasm.wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21(arg0, arg1, arg2);
3122
+ function wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c(arg0, arg1, arg2) {
3123
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c(arg0, arg1, arg2);
2983
3124
  if (ret[1]) {
2984
3125
  throw takeFromExternrefTable0(ret[0]);
2985
3126
  }
2986
3127
  }
2987
3128
 
2988
- function wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_4(arg0, arg1, arg2) {
2989
- const ret = wasm.wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_4(arg0, arg1, arg2);
3129
+ function wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_4(arg0, arg1, arg2) {
3130
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_4(arg0, arg1, arg2);
2990
3131
  if (ret[1]) {
2991
3132
  throw takeFromExternrefTable0(ret[0]);
2992
3133
  }
2993
3134
  }
2994
3135
 
2995
- function wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_5(arg0, arg1, arg2) {
2996
- const ret = wasm.wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_5(arg0, arg1, arg2);
3136
+ function wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_5(arg0, arg1, arg2) {
3137
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_5(arg0, arg1, arg2);
2997
3138
  if (ret[1]) {
2998
3139
  throw takeFromExternrefTable0(ret[0]);
2999
3140
  }
3000
3141
  }
3001
3142
 
3002
- function wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_6(arg0, arg1, arg2) {
3003
- const ret = wasm.wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_6(arg0, arg1, arg2);
3143
+ function wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_6(arg0, arg1, arg2) {
3144
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_6(arg0, arg1, arg2);
3004
3145
  if (ret[1]) {
3005
3146
  throw takeFromExternrefTable0(ret[0]);
3006
3147
  }
3007
3148
  }
3008
3149
 
3009
- function wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_7(arg0, arg1, arg2) {
3010
- const ret = wasm.wasm_bindgen__convert__closures_____invoke__h013a98c02f3b4b21_7(arg0, arg1, arg2);
3150
+ function wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_7(arg0, arg1, arg2) {
3151
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_7(arg0, arg1, arg2);
3011
3152
  if (ret[1]) {
3012
3153
  throw takeFromExternrefTable0(ret[0]);
3013
3154
  }
@@ -3043,9 +3184,15 @@ const BitcoinChainServiceHandleFinalization = (typeof FinalizationRegistry === '
3043
3184
  const BreezSdkFinalization = (typeof FinalizationRegistry === 'undefined')
3044
3185
  ? { register: () => {}, unregister: () => {} }
3045
3186
  : new FinalizationRegistry(ptr => wasm.__wbg_breezsdk_free(ptr, 1));
3046
- const DefaultSignerFinalization = (typeof FinalizationRegistry === 'undefined')
3187
+ const ExternalBreezSignerHandleFinalization = (typeof FinalizationRegistry === 'undefined')
3188
+ ? { register: () => {}, unregister: () => {} }
3189
+ : new FinalizationRegistry(ptr => wasm.__wbg_externalbreezsignerhandle_free(ptr, 1));
3190
+ const ExternalSignersFinalization = (typeof FinalizationRegistry === 'undefined')
3191
+ ? { register: () => {}, unregister: () => {} }
3192
+ : new FinalizationRegistry(ptr => wasm.__wbg_externalsigners_free(ptr, 1));
3193
+ const ExternalSparkSignerHandleFinalization = (typeof FinalizationRegistry === 'undefined')
3047
3194
  ? { register: () => {}, unregister: () => {} }
3048
- : new FinalizationRegistry(ptr => wasm.__wbg_defaultsigner_free(ptr, 1));
3195
+ : new FinalizationRegistry(ptr => wasm.__wbg_externalsparksignerhandle_free(ptr, 1));
3049
3196
  const IntoUnderlyingByteSourceFinalization = (typeof FinalizationRegistry === 'undefined')
3050
3197
  ? { register: () => {}, unregister: () => {} }
3051
3198
  : new FinalizationRegistry(ptr => wasm.__wbg_intounderlyingbytesource_free(ptr, 1));
@@ -3055,15 +3202,12 @@ const IntoUnderlyingSinkFinalization = (typeof FinalizationRegistry === 'undefin
3055
3202
  const IntoUnderlyingSourceFinalization = (typeof FinalizationRegistry === 'undefined')
3056
3203
  ? { register: () => {}, unregister: () => {} }
3057
3204
  : new FinalizationRegistry(ptr => wasm.__wbg_intounderlyingsource_free(ptr, 1));
3058
- const MysqlConnectionPoolFinalization = (typeof FinalizationRegistry === 'undefined')
3205
+ const PasskeyClientFinalization = (typeof FinalizationRegistry === 'undefined')
3059
3206
  ? { register: () => {}, unregister: () => {} }
3060
- : new FinalizationRegistry(ptr => wasm.__wbg_mysqlconnectionpool_free(ptr, 1));
3061
- const PasskeyFinalization = (typeof FinalizationRegistry === 'undefined')
3207
+ : new FinalizationRegistry(ptr => wasm.__wbg_passkeyclient_free(ptr, 1));
3208
+ const PasskeyLabelsFinalization = (typeof FinalizationRegistry === 'undefined')
3062
3209
  ? { register: () => {}, unregister: () => {} }
3063
- : new FinalizationRegistry(ptr => wasm.__wbg_passkey_free(ptr, 1));
3064
- const PostgresConnectionPoolFinalization = (typeof FinalizationRegistry === 'undefined')
3065
- ? { register: () => {}, unregister: () => {} }
3066
- : new FinalizationRegistry(ptr => wasm.__wbg_postgresconnectionpool_free(ptr, 1));
3210
+ : new FinalizationRegistry(ptr => wasm.__wbg_passkeylabels_free(ptr, 1));
3067
3211
  const SdkBuilderFinalization = (typeof FinalizationRegistry === 'undefined')
3068
3212
  ? { register: () => {}, unregister: () => {} }
3069
3213
  : new FinalizationRegistry(ptr => wasm.__wbg_sdkbuilder_free(ptr, 1));
@@ -3073,6 +3217,9 @@ const TokenIssuerFinalization = (typeof FinalizationRegistry === 'undefined')
3073
3217
  const WasmSdkContextFinalization = (typeof FinalizationRegistry === 'undefined')
3074
3218
  ? { register: () => {}, unregister: () => {} }
3075
3219
  : new FinalizationRegistry(ptr => wasm.__wbg_wasmsdkcontext_free(ptr, 1));
3220
+ const WasmStorageConfigFinalization = (typeof FinalizationRegistry === 'undefined')
3221
+ ? { register: () => {}, unregister: () => {} }
3222
+ : new FinalizationRegistry(ptr => wasm.__wbg_wasmstorageconfig_free(ptr, 1));
3076
3223
 
3077
3224
  function addToExternrefTable0(obj) {
3078
3225
  const idx = wasm.__externref_table_alloc();
@@ -3239,6 +3386,16 @@ function passArray8ToWasm0(arg, malloc) {
3239
3386
  return ptr;
3240
3387
  }
3241
3388
 
3389
+ function passArrayJsValueToWasm0(array, malloc) {
3390
+ const ptr = malloc(array.length * 4, 4) >>> 0;
3391
+ for (let i = 0; i < array.length; i++) {
3392
+ const add = addToExternrefTable0(array[i]);
3393
+ getDataViewMemory0().setUint32(ptr + 4 * i, add, true);
3394
+ }
3395
+ WASM_VECTOR_LEN = array.length;
3396
+ return ptr;
3397
+ }
3398
+
3242
3399
  function passStringToWasm0(arg, malloc, realloc) {
3243
3400
  if (realloc === undefined) {
3244
3401
  const buf = cachedTextEncoder.encode(arg);