@breeztech/breez-sdk-spark 0.16.1-dev1 → 0.17.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.
@@ -197,6 +197,14 @@ class BreezSdk {
197
197
  const ret = wasm.breezsdk_fetchConversionLimits(this.__wbg_ptr, request);
198
198
  return ret;
199
199
  }
200
+ /**
201
+ * @param {CrossChainRouteFilter} filter
202
+ * @returns {Promise<CrossChainRoutePair[]>}
203
+ */
204
+ getCrossChainRoutes(filter) {
205
+ const ret = wasm.breezsdk_getCrossChainRoutes(this.__wbg_ptr, filter);
206
+ return ret;
207
+ }
200
208
  /**
201
209
  * @param {GetInfoRequest} request
202
210
  * @returns {Promise<GetInfoResponse>}
@@ -1517,6 +1525,17 @@ function postgresStorage(config) {
1517
1525
  }
1518
1526
  exports.postgresStorage = postgresStorage;
1519
1527
 
1528
+ /**
1529
+ * Runs automatically when the wasm module is instantiated. Installs the
1530
+ * panic hook so Rust panics surface as readable `console.error` output
1531
+ * (with the panic message + `file.rs:line`) instead of a bare
1532
+ * `RuntimeError: unreachable`.
1533
+ */
1534
+ function start() {
1535
+ wasm.start();
1536
+ }
1537
+ exports.start = start;
1538
+
1520
1539
  /**
1521
1540
  * Entry point invoked by JavaScript in a worker.
1522
1541
  * @param {number} ptr
@@ -1762,6 +1781,9 @@ function __wbg_get_imports() {
1762
1781
  const ret = arg0.catch(arg1);
1763
1782
  return ret;
1764
1783
  },
1784
+ __wbg_clearInterval_d25b0cf526eff7ae: function(arg0) {
1785
+ globalThis.clearInterval(arg0);
1786
+ },
1765
1787
  __wbg_clearTimeout_113b1cde814ec762: function(arg0) {
1766
1788
  const ret = clearTimeout(arg0);
1767
1789
  return ret;
@@ -1779,6 +1801,9 @@ function __wbg_get_imports() {
1779
1801
  __wbg_close_de471367367aa5cb: function() { return handleError(function (arg0) {
1780
1802
  arg0.close();
1781
1803
  }, arguments); },
1804
+ __wbg_close_f1af935d7d7cec78: function() { return handleError(function (arg0, arg1, arg2, arg3) {
1805
+ arg0.close(arg1, getStringFromWasm0(arg2, arg3));
1806
+ }, arguments); },
1782
1807
  __wbg_code_be6f339819ebb2c4: function(arg0) {
1783
1808
  const ret = arg0.code;
1784
1809
  return ret;
@@ -1954,6 +1979,17 @@ function __wbg_get_imports() {
1954
1979
  __wbg_error_145dadf4216d70bc: function(arg0, arg1) {
1955
1980
  console.error(getStringFromWasm0(arg0, arg1));
1956
1981
  },
1982
+ __wbg_error_a6fa202b58aa1cd3: function(arg0, arg1) {
1983
+ let deferred0_0;
1984
+ let deferred0_1;
1985
+ try {
1986
+ deferred0_0 = arg0;
1987
+ deferred0_1 = arg1;
1988
+ console.error(getStringFromWasm0(arg0, arg1));
1989
+ } finally {
1990
+ wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
1991
+ }
1992
+ },
1957
1993
  __wbg_externalsigners_new: function(arg0) {
1958
1994
  const ret = ExternalSigners.__wrap(arg0);
1959
1995
  return ret;
@@ -2050,6 +2086,23 @@ function __wbg_get_imports() {
2050
2086
  wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2051
2087
  }
2052
2088
  }, arguments); },
2089
+ __wbg_getCrossChainSwap_e3b8fcf14d3d17ce: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
2090
+ let deferred0_0;
2091
+ let deferred0_1;
2092
+ let deferred1_0;
2093
+ let deferred1_1;
2094
+ try {
2095
+ deferred0_0 = arg1;
2096
+ deferred0_1 = arg2;
2097
+ deferred1_0 = arg3;
2098
+ deferred1_1 = arg4;
2099
+ const ret = arg0.getCrossChainSwap(getStringFromWasm0(arg1, arg2), getStringFromWasm0(arg3, arg4));
2100
+ return ret;
2101
+ } finally {
2102
+ wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2103
+ wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
2104
+ }
2105
+ }, arguments); },
2053
2106
  __wbg_getIdentityPublicKey_c6fcd87d66ed6927: function() { return handleError(function (arg0) {
2054
2107
  const ret = arg0.getIdentityPublicKey();
2055
2108
  return ret;
@@ -2332,6 +2385,18 @@ function __wbg_get_imports() {
2332
2385
  const ret = arg0.length;
2333
2386
  return ret;
2334
2387
  },
2388
+ __wbg_listActiveCrossChainSwaps_7339427675c1ddec: function() { return handleError(function (arg0, arg1, arg2) {
2389
+ let deferred0_0;
2390
+ let deferred0_1;
2391
+ try {
2392
+ deferred0_0 = arg1;
2393
+ deferred0_1 = arg2;
2394
+ const ret = arg0.listActiveCrossChainSwaps(getStringFromWasm0(arg1, arg2));
2395
+ return ret;
2396
+ } finally {
2397
+ wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
2398
+ }
2399
+ }, arguments); },
2335
2400
  __wbg_listContacts_0afeb7e9554fdb74: function() { return handleError(function (arg0, arg1) {
2336
2401
  const ret = arg0.listContacts(arg1);
2337
2402
  return ret;
@@ -2381,6 +2446,10 @@ function __wbg_get_imports() {
2381
2446
  const ret = new Headers();
2382
2447
  return ret;
2383
2448
  }, arguments); },
2449
+ __wbg_new_227d7c05414eb861: function() {
2450
+ const ret = new Error();
2451
+ return ret;
2452
+ },
2384
2453
  __wbg_new_2fad8ca02fd00684: function() {
2385
2454
  const ret = new Object();
2386
2455
  return ret;
@@ -2642,6 +2711,14 @@ function __wbg_get_imports() {
2642
2711
  wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
2643
2712
  }
2644
2713
  }, arguments); },
2714
+ __wbg_setCrossChainSwap_9047f4cc41fe2eca: function() { return handleError(function (arg0, arg1) {
2715
+ const ret = arg0.setCrossChainSwap(arg1);
2716
+ return ret;
2717
+ }, arguments); },
2718
+ __wbg_setInterval_2aba203c2a1ea83f: function(arg0, arg1) {
2719
+ const ret = globalThis.setInterval(arg0, arg1);
2720
+ return ret;
2721
+ },
2645
2722
  __wbg_setLeaves_3a013e3266762f4b: function() { return handleError(function (arg0, arg1, arg2, arg3) {
2646
2723
  const ret = arg0.setLeaves(arg1, arg2, arg3);
2647
2724
  return ret;
@@ -2810,6 +2887,13 @@ function __wbg_get_imports() {
2810
2887
  const ret = arg0.signal;
2811
2888
  return ret;
2812
2889
  },
2890
+ __wbg_stack_3b0d974bbf31e44f: function(arg0, arg1) {
2891
+ const ret = arg1.stack;
2892
+ const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
2893
+ const len1 = WASM_VECTOR_LEN;
2894
+ getDataViewMemory0().setInt32(arg0 + 4 * 1, len1, true);
2895
+ getDataViewMemory0().setInt32(arg0 + 4 * 0, ptr1, true);
2896
+ },
2813
2897
  __wbg_startStaticDepositRefund_5b591bbea22aa0d2: function() { return handleError(function (arg0, arg1) {
2814
2898
  const ret = arg0.startStaticDepositRefund(arg1);
2815
2899
  return ret;
@@ -2979,108 +3063,130 @@ function __wbg_get_imports() {
2979
3063
  },
2980
3064
  __wbindgen_cast_0000000000000001: function(arg0, arg1) {
2981
3065
  // 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);
3066
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522);
2983
3067
  return ret;
2984
3068
  },
2985
3069
  __wbindgen_cast_0000000000000002: function(arg0, arg1) {
2986
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 348, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
2987
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57);
3070
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 216, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
3071
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2);
2988
3072
  return ret;
2989
3073
  },
2990
3074
  __wbindgen_cast_0000000000000003: function(arg0, arg1) {
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`.
2992
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_2);
3075
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx: 216, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
3076
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_2);
2993
3077
  return ret;
2994
3078
  },
2995
3079
  __wbindgen_cast_0000000000000004: function(arg0, arg1) {
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`.
2997
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_3);
3080
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("ErrorEvent")], shim_idx: 216, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
3081
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_3);
2998
3082
  return ret;
2999
3083
  },
3000
3084
  __wbindgen_cast_0000000000000005: function(arg0, arg1) {
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);
3085
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("Event")], shim_idx: 216, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
3086
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4);
3003
3087
  return ret;
3004
3088
  },
3005
3089
  __wbindgen_cast_0000000000000006: function(arg0, arg1) {
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);
3090
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx: 216, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
3091
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5);
3008
3092
  return ret;
3009
3093
  },
3010
3094
  __wbindgen_cast_0000000000000007: function(arg0, arg1) {
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);
3095
+ // 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`.
3096
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_6);
3013
3097
  return ret;
3014
3098
  },
3015
3099
  __wbindgen_cast_0000000000000008: function(arg0, arg1) {
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);
3100
+ // 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`.
3101
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_7);
3018
3102
  return ret;
3019
3103
  },
3020
3104
  __wbindgen_cast_0000000000000009: function(arg0, arg1) {
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);
3105
+ // 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`.
3106
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_8);
3107
+ return ret;
3108
+ },
3109
+ __wbindgen_cast_000000000000000a: function(arg0, arg1) {
3110
+ // 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`.
3111
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_9);
3023
3112
  return ret;
3024
3113
  },
3025
- __wbindgen_cast_000000000000000a: function(arg0) {
3114
+ __wbindgen_cast_000000000000000b: function(arg0, arg1) {
3115
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 394, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
3116
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h1d6669a7b693932a);
3117
+ return ret;
3118
+ },
3119
+ __wbindgen_cast_000000000000000c: function(arg0, arg1) {
3120
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 420, ret: Unit, inner_ret: Some(Unit) }, mutable: false }) -> Externref`.
3121
+ const ret = makeClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h0fa3f876e31d2a3e);
3122
+ return ret;
3123
+ },
3124
+ __wbindgen_cast_000000000000000d: function(arg0) {
3026
3125
  // Cast intrinsic for `F64 -> Externref`.
3027
3126
  const ret = arg0;
3028
3127
  return ret;
3029
3128
  },
3030
- __wbindgen_cast_000000000000000b: function(arg0) {
3129
+ __wbindgen_cast_000000000000000e: function(arg0) {
3031
3130
  // Cast intrinsic for `I64 -> Externref`.
3032
3131
  const ret = arg0;
3033
3132
  return ret;
3034
3133
  },
3035
- __wbindgen_cast_000000000000000c: function(arg0, arg1) {
3134
+ __wbindgen_cast_000000000000000f: function(arg0, arg1) {
3036
3135
  // Cast intrinsic for `Ref(Slice(U8)) -> NamedExternref("Uint8Array")`.
3037
3136
  const ret = getArrayU8FromWasm0(arg0, arg1);
3038
3137
  return ret;
3039
3138
  },
3040
- __wbindgen_cast_000000000000000d: function(arg0, arg1) {
3139
+ __wbindgen_cast_0000000000000010: function(arg0, arg1) {
3041
3140
  // Cast intrinsic for `Ref(String) -> Externref`.
3042
3141
  const ret = getStringFromWasm0(arg0, arg1);
3043
3142
  return ret;
3044
3143
  },
3045
- __wbindgen_cast_000000000000000e: function(arg0, arg1) {
3144
+ __wbindgen_cast_0000000000000011: function(arg0, arg1) {
3046
3145
  // Cast intrinsic for `U128 -> Externref`.
3047
3146
  const ret = (BigInt.asUintN(64, arg0) | (BigInt.asUintN(64, arg1) << BigInt(64)));
3048
3147
  return ret;
3049
3148
  },
3050
- __wbindgen_cast_000000000000000f: function(arg0) {
3149
+ __wbindgen_cast_0000000000000012: function(arg0) {
3051
3150
  // Cast intrinsic for `U64 -> Externref`.
3052
3151
  const ret = BigInt.asUintN(64, arg0);
3053
3152
  return ret;
3054
3153
  },
3055
- __wbindgen_cast_0000000000000010: function(arg0, arg1) {
3154
+ __wbindgen_cast_0000000000000013: function(arg0, arg1) {
3056
3155
  var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
3057
3156
  wasm.__wbindgen_free(arg0, arg1 * 4, 4);
3058
3157
  // Cast intrinsic for `Vector(NamedExternref("Contact")) -> Externref`.
3059
3158
  const ret = v0;
3060
3159
  return ret;
3061
3160
  },
3062
- __wbindgen_cast_0000000000000011: function(arg0, arg1) {
3161
+ __wbindgen_cast_0000000000000014: function(arg0, arg1) {
3162
+ var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
3163
+ wasm.__wbindgen_free(arg0, arg1 * 4, 4);
3164
+ // Cast intrinsic for `Vector(NamedExternref("CrossChainRoutePair")) -> Externref`.
3165
+ const ret = v0;
3166
+ return ret;
3167
+ },
3168
+ __wbindgen_cast_0000000000000015: function(arg0, arg1) {
3063
3169
  var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
3064
3170
  wasm.__wbindgen_free(arg0, arg1 * 4, 4);
3065
3171
  // Cast intrinsic for `Vector(NamedExternref("ExternalFrostShareResult")) -> Externref`.
3066
3172
  const ret = v0;
3067
3173
  return ret;
3068
3174
  },
3069
- __wbindgen_cast_0000000000000012: function(arg0, arg1) {
3175
+ __wbindgen_cast_0000000000000016: function(arg0, arg1) {
3070
3176
  var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
3071
3177
  wasm.__wbindgen_free(arg0, arg1 * 4, 4);
3072
3178
  // Cast intrinsic for `Vector(NamedExternref("Webhook")) -> Externref`.
3073
3179
  const ret = v0;
3074
3180
  return ret;
3075
3181
  },
3076
- __wbindgen_cast_0000000000000013: function(arg0, arg1) {
3182
+ __wbindgen_cast_0000000000000017: function(arg0, arg1) {
3077
3183
  var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
3078
3184
  wasm.__wbindgen_free(arg0, arg1 * 4, 4);
3079
3185
  // Cast intrinsic for `Vector(NamedExternref("string")) -> Externref`.
3080
3186
  const ret = v0;
3081
3187
  return ret;
3082
3188
  },
3083
- __wbindgen_cast_0000000000000014: function(arg0, arg1) {
3189
+ __wbindgen_cast_0000000000000018: function(arg0, arg1) {
3084
3190
  var v0 = getArrayU8FromWasm0(arg0, arg1).slice();
3085
3191
  wasm.__wbindgen_free(arg0, arg1 * 1, 1);
3086
3192
  // Cast intrinsic for `Vector(U8) -> Externref`.
@@ -3103,52 +3209,64 @@ function __wbg_get_imports() {
3103
3209
  };
3104
3210
  }
3105
3211
 
3106
- function wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7(arg0, arg1) {
3107
- wasm.wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7(arg0, arg1);
3212
+ function wasm_bindgen__convert__closures_____invoke__h1d6669a7b693932a(arg0, arg1) {
3213
+ wasm.wasm_bindgen__convert__closures_____invoke__h1d6669a7b693932a(arg0, arg1);
3214
+ }
3215
+
3216
+ function wasm_bindgen__convert__closures_____invoke__h0fa3f876e31d2a3e(arg0, arg1) {
3217
+ wasm.wasm_bindgen__convert__closures_____invoke__h0fa3f876e31d2a3e(arg0, arg1);
3108
3218
  }
3109
3219
 
3110
- function wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57(arg0, arg1, arg2) {
3111
- wasm.wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57(arg0, arg1, arg2);
3220
+ function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2(arg0, arg1, arg2) {
3221
+ wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2(arg0, arg1, arg2);
3112
3222
  }
3113
3223
 
3114
- function wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_2(arg0, arg1, arg2) {
3115
- wasm.wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_2(arg0, arg1, arg2);
3224
+ function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_2(arg0, arg1, arg2) {
3225
+ wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_2(arg0, arg1, arg2);
3116
3226
  }
3117
3227
 
3118
- function wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_3(arg0, arg1, arg2) {
3119
- wasm.wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_3(arg0, arg1, arg2);
3228
+ function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_3(arg0, arg1, arg2) {
3229
+ wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_3(arg0, arg1, arg2);
3120
3230
  }
3121
3231
 
3122
- function wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c(arg0, arg1, arg2) {
3123
- const ret = wasm.wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c(arg0, arg1, arg2);
3232
+ function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4(arg0, arg1, arg2) {
3233
+ wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4(arg0, arg1, arg2);
3234
+ }
3235
+
3236
+ function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5(arg0, arg1, arg2) {
3237
+ wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5(arg0, arg1, arg2);
3238
+ }
3239
+
3240
+ function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522(arg0, arg1, arg2) {
3241
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522(arg0, arg1, arg2);
3124
3242
  if (ret[1]) {
3125
3243
  throw takeFromExternrefTable0(ret[0]);
3126
3244
  }
3127
3245
  }
3128
3246
 
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);
3247
+ function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_6(arg0, arg1, arg2) {
3248
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_6(arg0, arg1, arg2);
3131
3249
  if (ret[1]) {
3132
3250
  throw takeFromExternrefTable0(ret[0]);
3133
3251
  }
3134
3252
  }
3135
3253
 
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);
3254
+ function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_7(arg0, arg1, arg2) {
3255
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_7(arg0, arg1, arg2);
3138
3256
  if (ret[1]) {
3139
3257
  throw takeFromExternrefTable0(ret[0]);
3140
3258
  }
3141
3259
  }
3142
3260
 
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);
3261
+ function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_8(arg0, arg1, arg2) {
3262
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_8(arg0, arg1, arg2);
3145
3263
  if (ret[1]) {
3146
3264
  throw takeFromExternrefTable0(ret[0]);
3147
3265
  }
3148
3266
  }
3149
3267
 
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);
3268
+ function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_9(arg0, arg1, arg2) {
3269
+ const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_9(arg0, arg1, arg2);
3152
3270
  if (ret[1]) {
3153
3271
  throw takeFromExternrefTable0(ret[0]);
3154
3272
  }
@@ -3351,6 +3469,31 @@ function isLikeNone(x) {
3351
3469
  return x === undefined || x === null;
3352
3470
  }
3353
3471
 
3472
+ function makeClosure(arg0, arg1, f) {
3473
+ const state = { a: arg0, b: arg1, cnt: 1 };
3474
+ const real = (...args) => {
3475
+
3476
+ // First up with a closure we increment the internal reference
3477
+ // count. This ensures that the Rust closure environment won't
3478
+ // be deallocated while we're invoking it.
3479
+ state.cnt++;
3480
+ try {
3481
+ return f(state.a, state.b, ...args);
3482
+ } finally {
3483
+ real._wbg_cb_unref();
3484
+ }
3485
+ };
3486
+ real._wbg_cb_unref = () => {
3487
+ if (--state.cnt === 0) {
3488
+ wasm.__wbindgen_destroy_closure(state.a, state.b);
3489
+ state.a = 0;
3490
+ CLOSURE_DTORS.unregister(state);
3491
+ }
3492
+ };
3493
+ CLOSURE_DTORS.register(real, state, state);
3494
+ return real;
3495
+ }
3496
+
3354
3497
  function makeMutClosure(arg0, arg1, f) {
3355
3498
  const state = { a: arg0, b: arg1, cnt: 1 };
3356
3499
  const real = (...args) => {
Binary file
@@ -28,6 +28,7 @@ export const breezsdk_deleteContact: (a: number, b: number, c: number) => any;
28
28
  export const breezsdk_deleteLightningAddress: (a: number) => any;
29
29
  export const breezsdk_disconnect: (a: number) => any;
30
30
  export const breezsdk_fetchConversionLimits: (a: number, b: any) => any;
31
+ export const breezsdk_getCrossChainRoutes: (a: number, b: any) => any;
31
32
  export const breezsdk_getInfo: (a: number, b: any) => any;
32
33
  export const breezsdk_getLightningAddress: (a: number) => any;
33
34
  export const breezsdk_getPayment: (a: number, b: any) => any;
@@ -121,6 +122,7 @@ export const sdkbuilder_withRestChainService: (a: number, b: number, c: number,
121
122
  export const sdkbuilder_withSharedContext: (a: number, b: number) => number;
122
123
  export const sdkbuilder_withStorage: (a: number, b: any) => number;
123
124
  export const sdkbuilder_withStorageBackend: (a: number, b: number) => number;
125
+ export const start: () => void;
124
126
  export const tokenissuer_burnIssuerToken: (a: number, b: any) => any;
125
127
  export const tokenissuer_createIssuerToken: (a: number, b: any) => any;
126
128
  export const tokenissuer_freezeIssuerToken: (a: number, b: any) => any;
@@ -146,18 +148,21 @@ export const intounderlyingsink_close: (a: number) => any;
146
148
  export const intounderlyingsink_write: (a: number, b: any) => any;
147
149
  export const intounderlyingsource_cancel: (a: number) => void;
148
150
  export const intounderlyingsource_pull: (a: number, b: any) => any;
149
- export const __wbg_externalbreezsignerhandle_free: (a: number, b: number) => void;
150
151
  export const __wbg_externalsparksignerhandle_free: (a: number, b: number) => void;
151
- export const wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c: (a: number, b: number, c: any) => [number, number];
152
- export const wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_4: (a: number, b: number, c: any) => [number, number];
153
- export const wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_5: (a: number, b: number, c: any) => [number, number];
154
- export const wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_6: (a: number, b: number, c: any) => [number, number];
155
- export const wasm_bindgen__convert__closures_____invoke__h4bd7a023e323559c_7: (a: number, b: number, c: any) => [number, number];
152
+ export const __wbg_externalbreezsignerhandle_free: (a: number, b: number) => void;
153
+ export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522: (a: number, b: number, c: any) => [number, number];
154
+ export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_6: (a: number, b: number, c: any) => [number, number];
155
+ export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_7: (a: number, b: number, c: any) => [number, number];
156
+ export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_8: (a: number, b: number, c: any) => [number, number];
157
+ export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_9: (a: number, b: number, c: any) => [number, number];
156
158
  export const wasm_bindgen__convert__closures_____invoke__h41057d61edf43a32: (a: number, b: number, c: any, d: any) => void;
157
- export const wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57: (a: number, b: number, c: any) => void;
158
- export const wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_2: (a: number, b: number, c: any) => void;
159
- export const wasm_bindgen__convert__closures_____invoke__h4819aba3eed2db57_3: (a: number, b: number, c: any) => void;
160
- export const wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7: (a: number, b: number) => void;
159
+ export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2: (a: number, b: number, c: any) => void;
160
+ export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_2: (a: number, b: number, c: any) => void;
161
+ export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_3: (a: number, b: number, c: any) => void;
162
+ export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4: (a: number, b: number, c: any) => void;
163
+ export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5: (a: number, b: number, c: any) => void;
164
+ export const wasm_bindgen__convert__closures_____invoke__h1d6669a7b693932a: (a: number, b: number) => void;
165
+ export const wasm_bindgen__convert__closures_____invoke__h0fa3f876e31d2a3e: (a: number, b: number) => void;
161
166
  export const __wbindgen_malloc: (a: number, b: number) => number;
162
167
  export const __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
163
168
  export const __wbindgen_free: (a: number, b: number, c: number) => void;
package/nodejs/index.mjs CHANGED
@@ -19,6 +19,7 @@ export const {
19
19
  newRestChainService,
20
20
  newSharedSdkContext,
21
21
  postgresStorage,
22
+ start,
22
23
  task_worker_entry_point,
23
24
  BitcoinChainServiceHandle,
24
25
  BreezSdk,