@breeztech/breez-sdk-spark 0.24.0 → 0.25.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/breez-sdk-spark.tgz +0 -0
- package/bundler/breez_sdk_spark_wasm.d.ts +67 -10
- package/bundler/breez_sdk_spark_wasm_bg.js +47 -101
- package/bundler/breez_sdk_spark_wasm_bg.wasm +0 -0
- package/bundler/breez_sdk_spark_wasm_bg.wasm.d.ts +6 -8
- package/bundler/tree-store/index.js +10 -23
- package/deno/breez_sdk_spark_wasm.d.ts +67 -10
- package/deno/breez_sdk_spark_wasm.js +47 -101
- package/deno/breez_sdk_spark_wasm_bg.wasm +0 -0
- package/deno/breez_sdk_spark_wasm_bg.wasm.d.ts +6 -8
- package/nodejs/breez_sdk_spark_wasm.d.ts +67 -10
- package/nodejs/breez_sdk_spark_wasm.js +47 -101
- package/nodejs/breez_sdk_spark_wasm_bg.wasm +0 -0
- package/nodejs/breez_sdk_spark_wasm_bg.wasm.d.ts +6 -8
- package/nodejs/mysql-tree-store/index.cjs +4 -5
- package/nodejs/postgres-tree-store/index.cjs +3 -4
- package/nodejs/tree-store/index.cjs +1 -3
- package/package.json +1 -1
- package/web/breez_sdk_spark_wasm.d.ts +73 -18
- package/web/breez_sdk_spark_wasm.js +47 -101
- package/web/breez_sdk_spark_wasm_bg.wasm +0 -0
- package/web/breez_sdk_spark_wasm_bg.wasm.d.ts +6 -8
- package/web/tree-store/index.js +10 -23
|
@@ -681,6 +681,15 @@ export interface CheckMessageResponse {
|
|
|
681
681
|
isValid: boolean;
|
|
682
682
|
}
|
|
683
683
|
|
|
684
|
+
export interface CheckUnilateralExitRequest {
|
|
685
|
+
exit: UnilateralExitResponse;
|
|
686
|
+
}
|
|
687
|
+
|
|
688
|
+
export interface CheckUnilateralExitResponse {
|
|
689
|
+
exit: UnilateralExitResponse;
|
|
690
|
+
verdict: UnilateralExitVerdict;
|
|
691
|
+
}
|
|
692
|
+
|
|
684
693
|
export interface ClaimDepositQuote {
|
|
685
694
|
confirmationsRequired: number;
|
|
686
695
|
creditAmountSats: number;
|
|
@@ -746,6 +755,12 @@ export interface Config {
|
|
|
746
755
|
crossChainConfig?: CrossChainConfig;
|
|
747
756
|
}
|
|
748
757
|
|
|
758
|
+
export interface ConfirmedExitNode {
|
|
759
|
+
nodeId: string;
|
|
760
|
+
confirmedBy: ExitNodeConfirmation;
|
|
761
|
+
blockHeight?: number;
|
|
762
|
+
}
|
|
763
|
+
|
|
749
764
|
export interface ConnectRequest {
|
|
750
765
|
config: Config;
|
|
751
766
|
seed: Seed;
|
|
@@ -830,6 +845,17 @@ export interface CrossChainConfig {
|
|
|
830
845
|
defaultTargetOverpayBps?: number;
|
|
831
846
|
}
|
|
832
847
|
|
|
848
|
+
export interface CrossChainReceiveInfo {
|
|
849
|
+
depositAddress: string;
|
|
850
|
+
depositAmount: string;
|
|
851
|
+
expectedReceivedAmount: string;
|
|
852
|
+
destinationAsset: string;
|
|
853
|
+
tokenIdentifier?: string;
|
|
854
|
+
serviceFeeAmount: string;
|
|
855
|
+
serviceFeeAsset?: string;
|
|
856
|
+
expiresAt: number;
|
|
857
|
+
}
|
|
858
|
+
|
|
833
859
|
export interface CrossChainRoutePair {
|
|
834
860
|
provider: CrossChainProvider;
|
|
835
861
|
chain: string;
|
|
@@ -838,8 +864,8 @@ export interface CrossChainRoutePair {
|
|
|
838
864
|
contractAddress?: string;
|
|
839
865
|
decimals: number;
|
|
840
866
|
exactOutEligible: boolean;
|
|
841
|
-
|
|
842
|
-
|
|
867
|
+
acceptedAssets: SparkAsset[];
|
|
868
|
+
deliveryMethods: DeliveryMethod[];
|
|
843
869
|
}
|
|
844
870
|
|
|
845
871
|
export interface CurrencyInfo {
|
|
@@ -872,6 +898,19 @@ export interface EventListener {
|
|
|
872
898
|
onEvent: (e: SdkEvent) => void;
|
|
873
899
|
}
|
|
874
900
|
|
|
901
|
+
export interface ExitChainState {
|
|
902
|
+
confirmedNodes: ConfirmedExitNode[];
|
|
903
|
+
refunds: ExitRefund[];
|
|
904
|
+
stoppedLeafIds: string[];
|
|
905
|
+
unverifiedNodeIds: string[];
|
|
906
|
+
unverifiableConfirmedNodeIds: string[];
|
|
907
|
+
}
|
|
908
|
+
|
|
909
|
+
export interface ExitRefund {
|
|
910
|
+
leafId: string;
|
|
911
|
+
state: ExitRefundState;
|
|
912
|
+
}
|
|
913
|
+
|
|
875
914
|
export interface ExportUnilateralExitStateResponse {
|
|
876
915
|
exitState: string;
|
|
877
916
|
}
|
|
@@ -1486,11 +1525,14 @@ export interface PrepareUnilateralExitResponse {
|
|
|
1486
1525
|
leaves: UnilateralExitLeaf[];
|
|
1487
1526
|
recoverableValueSat: number;
|
|
1488
1527
|
totalFeeSat: number;
|
|
1528
|
+
cpfpFeeSat: number;
|
|
1489
1529
|
fanoutFeeSat: number;
|
|
1530
|
+
sweepFeeSat: number;
|
|
1490
1531
|
singleUtxoFundingSat: number;
|
|
1491
1532
|
perBranchFunding: PerBranchFunding[];
|
|
1492
1533
|
feeRateSatPerVbyte: number;
|
|
1493
1534
|
destination: string;
|
|
1535
|
+
exitChainState: ExitChainState;
|
|
1494
1536
|
}
|
|
1495
1537
|
|
|
1496
1538
|
export interface ProvisionalPayment {
|
|
@@ -1530,6 +1572,7 @@ export interface ReceivePaymentRequest {
|
|
|
1530
1572
|
export interface ReceivePaymentResponse {
|
|
1531
1573
|
paymentRequest: string;
|
|
1532
1574
|
fee: bigint;
|
|
1575
|
+
crossChainInfo?: CrossChainReceiveInfo;
|
|
1533
1576
|
}
|
|
1534
1577
|
|
|
1535
1578
|
export interface RecommendedFees {
|
|
@@ -1635,6 +1678,7 @@ export interface SendOnchainFeeQuote {
|
|
|
1635
1678
|
speedFast: SendOnchainSpeedFeeQuote;
|
|
1636
1679
|
speedMedium: SendOnchainSpeedFeeQuote;
|
|
1637
1680
|
speedSlow: SendOnchainSpeedFeeQuote;
|
|
1681
|
+
isEstimate: boolean;
|
|
1638
1682
|
}
|
|
1639
1683
|
|
|
1640
1684
|
export interface SendOnchainSpeedFeeQuote {
|
|
@@ -1921,8 +1965,12 @@ export interface UnilateralExitRequest {
|
|
|
1921
1965
|
export interface UnilateralExitResponse {
|
|
1922
1966
|
recoverableValueSat: number;
|
|
1923
1967
|
totalFeeSat: number;
|
|
1968
|
+
cpfpFeeSat: number;
|
|
1969
|
+
fanoutFeeSat: number;
|
|
1970
|
+
sweepFeeSat: number;
|
|
1924
1971
|
leaves: UnilateralExitLeaf[];
|
|
1925
1972
|
transactions: UnilateralExitTransaction[];
|
|
1973
|
+
fundingInputs: CpfpInput[];
|
|
1926
1974
|
}
|
|
1927
1975
|
|
|
1928
1976
|
export interface UnilateralExitTransaction {
|
|
@@ -1933,7 +1981,7 @@ export interface UnilateralExitTransaction {
|
|
|
1933
1981
|
cpfpTxHex?: string;
|
|
1934
1982
|
csvTimelockBlocks?: number;
|
|
1935
1983
|
dependsOn: string[];
|
|
1936
|
-
status:
|
|
1984
|
+
status: ExitTransactionStatus;
|
|
1937
1985
|
}
|
|
1938
1986
|
|
|
1939
1987
|
export interface UnregisterWebhookRequest {
|
|
@@ -2003,13 +2051,11 @@ export type BuyBitcoinRequest = { type: "moonpay"; lockedAmountSat?: number; red
|
|
|
2003
2051
|
|
|
2004
2052
|
export type ChainApiType = "esplora" | "mempoolSpace";
|
|
2005
2053
|
|
|
2006
|
-
export type ConfirmationStatus = "confirmed" | "unconfirmed" | "unverified";
|
|
2007
|
-
|
|
2008
2054
|
export type ConversionChain = { type: "spark" } | { type: "lightning" } | { type: "external"; name: string; chainId?: string };
|
|
2009
2055
|
|
|
2010
2056
|
export type ConversionFilter = "ammRefundNeeded" | "orchestraPending" | "boltzPending";
|
|
2011
2057
|
|
|
2012
|
-
export type ConversionInfo = { type: "amm"; poolId: string; conversionId: string; status: ConversionStatus; fee?: string; purpose?: ConversionPurpose; amountAdjustment?: AmountAdjustmentReason; degradation?: SwapDegradation } | { type: "orchestra"; chain: string; chainId?: string; asset?: string; assetContract?: string; recipientAddress: string; assetAmountIn?: string; estimatedOut: string; deliveredAmount?: string; status: ConversionStatus; feeAmount?: string; serviceFeeAmount?: string; serviceFeeAsset?: string; assetDecimals: number; orderId: string; quoteId: string; readToken?: string } | { type: "boltz"; chain: string; chainId?: string; asset?: string; assetContract?: string; recipientAddress: string; assetAmountIn?: string; estimatedOut: string; deliveredAmount?: string; status: ConversionStatus; feeAmount?: string; serviceFeeAmount?: string; serviceFeeAsset?: string; assetDecimals: number; swapId: string; invoice: string; invoiceAmountSats: number; bridgeRef?: string; maxSlippageBps: number; quoteDegraded?: boolean };
|
|
2058
|
+
export type ConversionInfo = { type: "amm"; poolId: string; conversionId: string; status: ConversionStatus; fee?: string; purpose?: ConversionPurpose; amountAdjustment?: AmountAdjustmentReason; degradation?: SwapDegradation } | { type: "orchestra"; chain: string; chainId?: string; asset?: string; assetContract?: string; recipientAddress: string; assetAmountIn?: string; estimatedOut: string; deliveredAmount?: string; externalTxHash?: string; status: ConversionStatus; feeAmount?: string; serviceFeeAmount?: string; serviceFeeAsset?: string; assetDecimals: number; orderId: string; quoteId: string; readToken?: string } | { type: "boltz"; chain: string; chainId?: string; asset?: string; assetContract?: string; recipientAddress: string; assetAmountIn?: string; estimatedOut: string; deliveredAmount?: string; status: ConversionStatus; feeAmount?: string; serviceFeeAmount?: string; serviceFeeAsset?: string; assetDecimals: number; swapId: string; invoice: string; invoiceAmountSats: number; bridgeRef?: string; maxSlippageBps: number; quoteDegraded?: boolean };
|
|
2013
2059
|
|
|
2014
2060
|
export type ConversionProvider = "amm" | "orchestra" | "boltz";
|
|
2015
2061
|
|
|
@@ -2033,10 +2079,18 @@ export type CrossChainProviderContext = { type: "orchestra"; quoteId: string; de
|
|
|
2033
2079
|
|
|
2034
2080
|
export type CrossChainRouteFilter = { type: "send"; addressDetails: CrossChainAddressDetails } | { type: "receive"; contractAddress?: string } | { type: "paymentLink"; addressDetails: CrossChainAddressDetails };
|
|
2035
2081
|
|
|
2082
|
+
export type DeliveryMethod = "spark" | "lightning" | "bitcoin";
|
|
2083
|
+
|
|
2036
2084
|
export type DepositClaimError = { type: "maxDepositClaimFeeExceeded"; tx: string; vout: number; maxFee?: Fee; requiredFeeSats: number; requiredFeeRateSatPerVbyte: number } | { type: "missingUtxo"; tx: string; vout: number } | { type: "generic"; message: string };
|
|
2037
2085
|
|
|
2038
2086
|
export type ExitLeafSelection = { type: "auto" } | { type: "specific"; leafIds: string[] };
|
|
2039
2087
|
|
|
2088
|
+
export type ExitNodeConfirmation = "cpfp" | "direct";
|
|
2089
|
+
|
|
2090
|
+
export type ExitRefundState = { type: "onChain"; txHex: string; vout: number; valueSat: number; blockHeight?: number } | { type: "swept" };
|
|
2091
|
+
|
|
2092
|
+
export type ExitTransactionStatus = { type: "confirmed"; blockHeight?: number } | { type: "ready" } | { type: "waitingForDependencies" } | { type: "waitingForTimelock"; spendableAtHeight?: number } | { type: "unverified" };
|
|
2093
|
+
|
|
2040
2094
|
export type ExternalFrostDerivation = { type: "signingLeaf"; leafId: ExternalTreeNodeId } | { type: "staticDeposit"; index: number } | { type: "htlcPreimage" } | { type: "identity" };
|
|
2041
2095
|
|
|
2042
2096
|
export type ExternalSparkInvoiceKind = "sats" | "tokens";
|
|
@@ -2083,7 +2137,7 @@ export type PublishSignedLnurlPayResponse = { type: "swapCompleted" } | { type:
|
|
|
2083
2137
|
|
|
2084
2138
|
export type PublishSignedTransferPackageResponse = { type: "swapCompleted" } | { type: "paymentSent"; payment: Payment } | { type: "paymentsSent"; payments: Payment[] };
|
|
2085
2139
|
|
|
2086
|
-
export type ReceivePaymentMethod = { type: "sparkAddress" } | { type: "sparkInvoice"; amount?: string; tokenIdentifier?: string; expiryTime?: number; description?: string; senderPublicKey?: string } | { type: "bitcoinAddress"; newAddress?: boolean } | { type: "bolt11Invoice"; description: string; amountSats?: number; expirySecs?: number; paymentHash?: string; receiverIdentityPublicKey?: string };
|
|
2140
|
+
export type ReceivePaymentMethod = { type: "sparkAddress" } | { type: "sparkInvoice"; amount?: string; tokenIdentifier?: string; expiryTime?: number; description?: string; senderPublicKey?: string } | { type: "bitcoinAddress"; newAddress?: boolean } | { type: "bolt11Invoice"; description: string; amountSats?: number; expirySecs?: number; paymentHash?: string; receiverIdentityPublicKey?: string } | { type: "crossChain"; route: CrossChainRoutePair; amount: string; destination?: SparkAsset; feeMode?: CrossChainFeeMode; maxSlippageBps?: number; targetOverpayBps?: number };
|
|
2087
2141
|
|
|
2088
2142
|
export type RefundState = { type: "broadcastPending"; lastError?: string } | { type: "broadcast" };
|
|
2089
2143
|
|
|
@@ -2099,9 +2153,7 @@ export type ServiceStatus = "operational" | "degraded" | "partial" | "unknown" |
|
|
|
2099
2153
|
|
|
2100
2154
|
export type SessionStoreError = { type: "notFound" } | ({ type: "generic" } & string);
|
|
2101
2155
|
|
|
2102
|
-
export type
|
|
2103
|
-
|
|
2104
|
-
export type SourceChain = "spark" | "lightning" | "bitcoin";
|
|
2156
|
+
export type SparkAsset = { type: "bitcoin" } | { type: "token"; tokenIdentifier: string };
|
|
2105
2157
|
|
|
2106
2158
|
export type SparkHtlcStatus = "waitingForPreimage" | "preimageShared" | "returned";
|
|
2107
2159
|
|
|
@@ -2123,8 +2175,12 @@ export type TransferSignature = { type: "transfer"; signed: ExternalPreparedTran
|
|
|
2123
2175
|
|
|
2124
2176
|
export type TransferTarget = { type: "spark"; address: string; sparkInvoice?: string } | { type: "lightning"; bolt11: string; lnurlPay?: LnurlPayContext; feePolicy: FeePolicy; completionTimeoutSecs?: number } | { type: "coopExit"; address: string; feeQuote: SendOnchainFeeQuote; confirmationSpeed: OnchainConfirmationSpeed };
|
|
2125
2177
|
|
|
2178
|
+
export type UnilateralExitRedoReason = "onChainStateDiverged";
|
|
2179
|
+
|
|
2126
2180
|
export type UnilateralExitTxKind = "fanOut" | "node" | "refund" | "sweep";
|
|
2127
2181
|
|
|
2182
|
+
export type UnilateralExitVerdict = { type: "valid" } | { type: "done" } | { type: "redo"; reason: UnilateralExitRedoReason };
|
|
2183
|
+
|
|
2128
2184
|
export type UnsignedTransferPackage = { type: "swap"; prepareTransfer: ExternalPrepareTransferRequest; targetAmounts: number[]; amountSat: number; feeSat: number } | { type: "transfer"; prepareTransfer: ExternalPrepareTransferRequest; amountSat: number; feeSat: number; target: TransferTarget } | { type: "token"; prepareTokenTransaction: ExternalPrepareTokenTransactionRequest; tokenContext: number[]; tokenIdentifier: string; amount: string; fee: string; isSwap: boolean } | { type: "tokenBatch"; prepareTokenTransaction: ExternalPrepareTokenTransactionRequest; tokenContext: number[]; totals: BatchTotal[]; isSwap: boolean };
|
|
2129
2185
|
|
|
2130
2186
|
export type UpdateDepositPayload = { type: "claimError"; error: DepositClaimError } | { type: "refund"; refundTxid: string; refundTx: string; state: RefundState } | { type: "instantClaim"; status: InstantClaimStatus } | { type: "refundBroadcastState"; refundTxid: string; state: RefundState };
|
|
@@ -2167,6 +2223,7 @@ export class BreezSdk {
|
|
|
2167
2223
|
buyBitcoin(request: BuyBitcoinRequest): Promise<BuyBitcoinResponse>;
|
|
2168
2224
|
checkLightningAddressAvailable(request: CheckLightningAddressRequest): Promise<boolean>;
|
|
2169
2225
|
checkMessage(request: CheckMessageRequest): Promise<CheckMessageResponse>;
|
|
2226
|
+
checkUnilateralExit(request: CheckUnilateralExitRequest): Promise<CheckUnilateralExitResponse>;
|
|
2170
2227
|
claimDeposit(request: ClaimDepositRequest): Promise<ClaimDepositResponse>;
|
|
2171
2228
|
claimHtlcPayment(request: ClaimHtlcPaymentRequest): Promise<ClaimHtlcPaymentResponse>;
|
|
2172
2229
|
claimLightningAddressTransfer(request: ClaimTransferRequest): Promise<LightningAddressInfo>;
|
|
@@ -192,6 +192,14 @@ export class BreezSdk {
|
|
|
192
192
|
const ret = wasm.breezsdk_checkMessage(this.__wbg_ptr, request);
|
|
193
193
|
return ret;
|
|
194
194
|
}
|
|
195
|
+
/**
|
|
196
|
+
* @param {CheckUnilateralExitRequest} request
|
|
197
|
+
* @returns {Promise<CheckUnilateralExitResponse>}
|
|
198
|
+
*/
|
|
199
|
+
checkUnilateralExit(request) {
|
|
200
|
+
const ret = wasm.breezsdk_checkUnilateralExit(this.__wbg_ptr, request);
|
|
201
|
+
return ret;
|
|
202
|
+
}
|
|
195
203
|
/**
|
|
196
204
|
* @param {ClaimDepositRequest} request
|
|
197
205
|
* @returns {Promise<ClaimDepositResponse>}
|
|
@@ -2206,9 +2214,6 @@ function __wbg_get_imports() {
|
|
|
2206
2214
|
const ret = arg0.catch(arg1);
|
|
2207
2215
|
return ret;
|
|
2208
2216
|
},
|
|
2209
|
-
__wbg_clearInterval_d25b0cf526eff7ae: function(arg0) {
|
|
2210
|
-
globalThis.clearInterval(arg0);
|
|
2211
|
-
},
|
|
2212
2217
|
__wbg_clearTimeout_113b1cde814ec762: function(arg0) {
|
|
2213
2218
|
const ret = clearTimeout(arg0);
|
|
2214
2219
|
return ret;
|
|
@@ -2226,9 +2231,6 @@ function __wbg_get_imports() {
|
|
|
2226
2231
|
__wbg_close_de471367367aa5cb: function() { return handleError(function (arg0) {
|
|
2227
2232
|
arg0.close();
|
|
2228
2233
|
}, arguments); },
|
|
2229
|
-
__wbg_close_f1af935d7d7cec78: function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
2230
|
-
arg0.close(arg1, getStringFromWasm0(arg2, arg3));
|
|
2231
|
-
}, arguments); },
|
|
2232
2234
|
__wbg_code_be6f339819ebb2c4: function(arg0) {
|
|
2233
2235
|
const ret = arg0.code;
|
|
2234
2236
|
return ret;
|
|
@@ -3207,10 +3209,6 @@ function __wbg_get_imports() {
|
|
|
3207
3209
|
const ret = arg0.setCrossChainSwap(arg1);
|
|
3208
3210
|
return ret;
|
|
3209
3211
|
}, arguments); },
|
|
3210
|
-
__wbg_setInterval_2aba203c2a1ea83f: function(arg0, arg1) {
|
|
3211
|
-
const ret = globalThis.setInterval(arg0, arg1);
|
|
3212
|
-
return ret;
|
|
3213
|
-
},
|
|
3214
3212
|
__wbg_setLeaves_3a013e3266762f4b: function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3215
3213
|
const ret = arg0.setLeaves(arg1, arg2, arg3);
|
|
3216
3214
|
return ret;
|
|
@@ -3637,126 +3635,111 @@ function __wbg_get_imports() {
|
|
|
3637
3635
|
return ret;
|
|
3638
3636
|
},
|
|
3639
3637
|
__wbindgen_cast_0000000000000002: function(arg0, arg1) {
|
|
3640
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx:
|
|
3641
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3638
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 397, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3639
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25);
|
|
3642
3640
|
return ret;
|
|
3643
3641
|
},
|
|
3644
3642
|
__wbindgen_cast_0000000000000003: function(arg0, arg1) {
|
|
3645
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx:
|
|
3646
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3643
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx: 397, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3644
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25_2);
|
|
3647
3645
|
return ret;
|
|
3648
3646
|
},
|
|
3649
3647
|
__wbindgen_cast_0000000000000004: function(arg0, arg1) {
|
|
3650
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("
|
|
3651
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3648
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx: 397, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3649
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25_3);
|
|
3652
3650
|
return ret;
|
|
3653
3651
|
},
|
|
3654
3652
|
__wbindgen_cast_0000000000000005: function(arg0, arg1) {
|
|
3655
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("
|
|
3656
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3653
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("SessionStore")], shim_idx: 22, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
3654
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_4);
|
|
3657
3655
|
return ret;
|
|
3658
3656
|
},
|
|
3659
3657
|
__wbindgen_cast_0000000000000006: function(arg0, arg1) {
|
|
3660
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("
|
|
3661
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3658
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("Storage")], shim_idx: 22, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
3659
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_5);
|
|
3662
3660
|
return ret;
|
|
3663
3661
|
},
|
|
3664
3662
|
__wbindgen_cast_0000000000000007: function(arg0, arg1) {
|
|
3665
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("
|
|
3663
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("TokenStore")], shim_idx: 22, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
3666
3664
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_6);
|
|
3667
3665
|
return ret;
|
|
3668
3666
|
},
|
|
3669
3667
|
__wbindgen_cast_0000000000000008: function(arg0, arg1) {
|
|
3670
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("
|
|
3668
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("TreeStore")], shim_idx: 22, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
3671
3669
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_7);
|
|
3672
3670
|
return ret;
|
|
3673
3671
|
},
|
|
3674
3672
|
__wbindgen_cast_0000000000000009: function(arg0, arg1) {
|
|
3675
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [
|
|
3676
|
-
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_8);
|
|
3677
|
-
return ret;
|
|
3678
|
-
},
|
|
3679
|
-
__wbindgen_cast_000000000000000a: function(arg0, arg1) {
|
|
3680
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("TreeStore")], shim_idx: 22, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
|
|
3681
|
-
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_9);
|
|
3682
|
-
return ret;
|
|
3683
|
-
},
|
|
3684
|
-
__wbindgen_cast_000000000000000b: function(arg0, arg1) {
|
|
3685
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 405, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3673
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 402, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3686
3674
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7);
|
|
3687
3675
|
return ret;
|
|
3688
3676
|
},
|
|
3689
|
-
|
|
3690
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 434, ret: Unit, inner_ret: Some(Unit) }, mutable: false }) -> Externref`.
|
|
3691
|
-
const ret = makeClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h0fa3f876e31d2a3e);
|
|
3692
|
-
return ret;
|
|
3693
|
-
},
|
|
3694
|
-
__wbindgen_cast_000000000000000d: function(arg0) {
|
|
3677
|
+
__wbindgen_cast_000000000000000a: function(arg0) {
|
|
3695
3678
|
// Cast intrinsic for `F64 -> Externref`.
|
|
3696
3679
|
const ret = arg0;
|
|
3697
3680
|
return ret;
|
|
3698
3681
|
},
|
|
3699
|
-
|
|
3682
|
+
__wbindgen_cast_000000000000000b: function(arg0) {
|
|
3700
3683
|
// Cast intrinsic for `I64 -> Externref`.
|
|
3701
3684
|
const ret = arg0;
|
|
3702
3685
|
return ret;
|
|
3703
3686
|
},
|
|
3704
|
-
|
|
3687
|
+
__wbindgen_cast_000000000000000c: function(arg0, arg1) {
|
|
3705
3688
|
// Cast intrinsic for `Ref(Slice(U8)) -> NamedExternref("Uint8Array")`.
|
|
3706
3689
|
const ret = getArrayU8FromWasm0(arg0, arg1);
|
|
3707
3690
|
return ret;
|
|
3708
3691
|
},
|
|
3709
|
-
|
|
3692
|
+
__wbindgen_cast_000000000000000d: function(arg0, arg1) {
|
|
3710
3693
|
// Cast intrinsic for `Ref(String) -> Externref`.
|
|
3711
3694
|
const ret = getStringFromWasm0(arg0, arg1);
|
|
3712
3695
|
return ret;
|
|
3713
3696
|
},
|
|
3714
|
-
|
|
3697
|
+
__wbindgen_cast_000000000000000e: function(arg0, arg1) {
|
|
3715
3698
|
// Cast intrinsic for `U128 -> Externref`.
|
|
3716
3699
|
const ret = (BigInt.asUintN(64, arg0) | (BigInt.asUintN(64, arg1) << BigInt(64)));
|
|
3717
3700
|
return ret;
|
|
3718
3701
|
},
|
|
3719
|
-
|
|
3702
|
+
__wbindgen_cast_000000000000000f: function(arg0) {
|
|
3720
3703
|
// Cast intrinsic for `U64 -> Externref`.
|
|
3721
3704
|
const ret = BigInt.asUintN(64, arg0);
|
|
3722
3705
|
return ret;
|
|
3723
3706
|
},
|
|
3724
|
-
|
|
3707
|
+
__wbindgen_cast_0000000000000010: function(arg0, arg1) {
|
|
3725
3708
|
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
3726
3709
|
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
3727
3710
|
// Cast intrinsic for `Vector(NamedExternref("Contact")) -> Externref`.
|
|
3728
3711
|
const ret = v0;
|
|
3729
3712
|
return ret;
|
|
3730
3713
|
},
|
|
3731
|
-
|
|
3714
|
+
__wbindgen_cast_0000000000000011: function(arg0, arg1) {
|
|
3732
3715
|
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
3733
3716
|
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
3734
3717
|
// Cast intrinsic for `Vector(NamedExternref("CrossChainRoutePair")) -> Externref`.
|
|
3735
3718
|
const ret = v0;
|
|
3736
3719
|
return ret;
|
|
3737
3720
|
},
|
|
3738
|
-
|
|
3721
|
+
__wbindgen_cast_0000000000000012: function(arg0, arg1) {
|
|
3739
3722
|
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
3740
3723
|
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
3741
3724
|
// Cast intrinsic for `Vector(NamedExternref("ExternalFrostShareResult")) -> Externref`.
|
|
3742
3725
|
const ret = v0;
|
|
3743
3726
|
return ret;
|
|
3744
3727
|
},
|
|
3745
|
-
|
|
3728
|
+
__wbindgen_cast_0000000000000013: function(arg0, arg1) {
|
|
3746
3729
|
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
3747
3730
|
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
3748
3731
|
// Cast intrinsic for `Vector(NamedExternref("Webhook")) -> Externref`.
|
|
3749
3732
|
const ret = v0;
|
|
3750
3733
|
return ret;
|
|
3751
3734
|
},
|
|
3752
|
-
|
|
3735
|
+
__wbindgen_cast_0000000000000014: function(arg0, arg1) {
|
|
3753
3736
|
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
3754
3737
|
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
3755
3738
|
// Cast intrinsic for `Vector(NamedExternref("string")) -> Externref`.
|
|
3756
3739
|
const ret = v0;
|
|
3757
3740
|
return ret;
|
|
3758
3741
|
},
|
|
3759
|
-
|
|
3742
|
+
__wbindgen_cast_0000000000000015: function(arg0, arg1) {
|
|
3760
3743
|
var v0 = getArrayU8FromWasm0(arg0, arg1).slice();
|
|
3761
3744
|
wasm.__wbindgen_free(arg0, arg1 * 1, 1);
|
|
3762
3745
|
// Cast intrinsic for `Vector(U8) -> Externref`.
|
|
@@ -3783,28 +3766,16 @@ function wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7(arg0, arg
|
|
|
3783
3766
|
wasm.wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7(arg0, arg1);
|
|
3784
3767
|
}
|
|
3785
3768
|
|
|
3786
|
-
function
|
|
3787
|
-
wasm.
|
|
3788
|
-
}
|
|
3789
|
-
|
|
3790
|
-
function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2(arg0, arg1, arg2) {
|
|
3791
|
-
wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2(arg0, arg1, arg2);
|
|
3769
|
+
function wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25(arg0, arg1, arg2) {
|
|
3770
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25(arg0, arg1, arg2);
|
|
3792
3771
|
}
|
|
3793
3772
|
|
|
3794
|
-
function
|
|
3795
|
-
wasm.
|
|
3773
|
+
function wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25_2(arg0, arg1, arg2) {
|
|
3774
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25_2(arg0, arg1, arg2);
|
|
3796
3775
|
}
|
|
3797
3776
|
|
|
3798
|
-
function
|
|
3799
|
-
wasm.
|
|
3800
|
-
}
|
|
3801
|
-
|
|
3802
|
-
function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4(arg0, arg1, arg2) {
|
|
3803
|
-
wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4(arg0, arg1, arg2);
|
|
3804
|
-
}
|
|
3805
|
-
|
|
3806
|
-
function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5(arg0, arg1, arg2) {
|
|
3807
|
-
wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5(arg0, arg1, arg2);
|
|
3777
|
+
function wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25_3(arg0, arg1, arg2) {
|
|
3778
|
+
wasm.wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25_3(arg0, arg1, arg2);
|
|
3808
3779
|
}
|
|
3809
3780
|
|
|
3810
3781
|
function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522(arg0, arg1, arg2) {
|
|
@@ -3814,29 +3785,29 @@ function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522(arg0, arg
|
|
|
3814
3785
|
}
|
|
3815
3786
|
}
|
|
3816
3787
|
|
|
3817
|
-
function
|
|
3818
|
-
const ret = wasm.
|
|
3788
|
+
function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_4(arg0, arg1, arg2) {
|
|
3789
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_4(arg0, arg1, arg2);
|
|
3819
3790
|
if (ret[1]) {
|
|
3820
3791
|
throw takeFromExternrefTable0(ret[0]);
|
|
3821
3792
|
}
|
|
3822
3793
|
}
|
|
3823
3794
|
|
|
3824
|
-
function
|
|
3825
|
-
const ret = wasm.
|
|
3795
|
+
function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_5(arg0, arg1, arg2) {
|
|
3796
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_5(arg0, arg1, arg2);
|
|
3826
3797
|
if (ret[1]) {
|
|
3827
3798
|
throw takeFromExternrefTable0(ret[0]);
|
|
3828
3799
|
}
|
|
3829
3800
|
}
|
|
3830
3801
|
|
|
3831
|
-
function
|
|
3832
|
-
const ret = wasm.
|
|
3802
|
+
function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_6(arg0, arg1, arg2) {
|
|
3803
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_6(arg0, arg1, arg2);
|
|
3833
3804
|
if (ret[1]) {
|
|
3834
3805
|
throw takeFromExternrefTable0(ret[0]);
|
|
3835
3806
|
}
|
|
3836
3807
|
}
|
|
3837
3808
|
|
|
3838
|
-
function
|
|
3839
|
-
const ret = wasm.
|
|
3809
|
+
function wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_7(arg0, arg1, arg2) {
|
|
3810
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_7(arg0, arg1, arg2);
|
|
3840
3811
|
if (ret[1]) {
|
|
3841
3812
|
throw takeFromExternrefTable0(ret[0]);
|
|
3842
3813
|
}
|
|
@@ -4051,31 +4022,6 @@ function isLikeNone(x) {
|
|
|
4051
4022
|
return x === undefined || x === null;
|
|
4052
4023
|
}
|
|
4053
4024
|
|
|
4054
|
-
function makeClosure(arg0, arg1, f) {
|
|
4055
|
-
const state = { a: arg0, b: arg1, cnt: 1 };
|
|
4056
|
-
const real = (...args) => {
|
|
4057
|
-
|
|
4058
|
-
// First up with a closure we increment the internal reference
|
|
4059
|
-
// count. This ensures that the Rust closure environment won't
|
|
4060
|
-
// be deallocated while we're invoking it.
|
|
4061
|
-
state.cnt++;
|
|
4062
|
-
try {
|
|
4063
|
-
return f(state.a, state.b, ...args);
|
|
4064
|
-
} finally {
|
|
4065
|
-
real._wbg_cb_unref();
|
|
4066
|
-
}
|
|
4067
|
-
};
|
|
4068
|
-
real._wbg_cb_unref = () => {
|
|
4069
|
-
if (--state.cnt === 0) {
|
|
4070
|
-
wasm.__wbindgen_destroy_closure(state.a, state.b);
|
|
4071
|
-
state.a = 0;
|
|
4072
|
-
CLOSURE_DTORS.unregister(state);
|
|
4073
|
-
}
|
|
4074
|
-
};
|
|
4075
|
-
CLOSURE_DTORS.register(real, state, state);
|
|
4076
|
-
return real;
|
|
4077
|
-
}
|
|
4078
|
-
|
|
4079
4025
|
function makeMutClosure(arg0, arg1, f) {
|
|
4080
4026
|
const state = { a: arg0, b: arg1, cnt: 1 };
|
|
4081
4027
|
const real = (...args) => {
|
|
Binary file
|
|
@@ -28,6 +28,7 @@ export const breezsdk_buildUnsignedTransferPackage: (a: number, b: any) => any;
|
|
|
28
28
|
export const breezsdk_buyBitcoin: (a: number, b: any) => any;
|
|
29
29
|
export const breezsdk_checkLightningAddressAvailable: (a: number, b: any) => any;
|
|
30
30
|
export const breezsdk_checkMessage: (a: number, b: any) => any;
|
|
31
|
+
export const breezsdk_checkUnilateralExit: (a: number, b: any) => any;
|
|
31
32
|
export const breezsdk_claimDeposit: (a: number, b: any) => any;
|
|
32
33
|
export const breezsdk_claimHtlcPayment: (a: number, b: any) => any;
|
|
33
34
|
export const breezsdk_claimLightningAddressTransfer: (a: number, b: any) => any;
|
|
@@ -189,18 +190,15 @@ export const __wbg_signingonlyexternalsigners_free: (a: number, b: number) => vo
|
|
|
189
190
|
export const signingonlyexternalsigners_breezSigner: (a: number) => number;
|
|
190
191
|
export const signingonlyexternalsigners_sparkSigner: (a: number) => number;
|
|
191
192
|
export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522: (a: number, b: number, c: any) => [number, number];
|
|
193
|
+
export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_4: (a: number, b: number, c: any) => [number, number];
|
|
194
|
+
export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_5: (a: number, b: number, c: any) => [number, number];
|
|
192
195
|
export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_6: (a: number, b: number, c: any) => [number, number];
|
|
193
196
|
export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_7: (a: number, b: number, c: any) => [number, number];
|
|
194
|
-
export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_8: (a: number, b: number, c: any) => [number, number];
|
|
195
|
-
export const wasm_bindgen__convert__closures_____invoke__h62bc116e0c266522_9: (a: number, b: number, c: any) => [number, number];
|
|
196
197
|
export const wasm_bindgen__convert__closures_____invoke__h41057d61edf43a32: (a: number, b: number, c: any, d: any) => void;
|
|
197
|
-
export const
|
|
198
|
-
export const
|
|
199
|
-
export const
|
|
200
|
-
export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4: (a: number, b: number, c: any) => void;
|
|
201
|
-
export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5: (a: number, b: number, c: any) => void;
|
|
198
|
+
export const wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25: (a: number, b: number, c: any) => void;
|
|
199
|
+
export const wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25_2: (a: number, b: number, c: any) => void;
|
|
200
|
+
export const wasm_bindgen__convert__closures_____invoke__h3b28fbbc8b451a25_3: (a: number, b: number, c: any) => void;
|
|
202
201
|
export const wasm_bindgen__convert__closures_____invoke__h484cd36e13f37bd7: (a: number, b: number) => void;
|
|
203
|
-
export const wasm_bindgen__convert__closures_____invoke__h0fa3f876e31d2a3e: (a: number, b: number) => void;
|
|
204
202
|
export const __wbindgen_malloc: (a: number, b: number) => number;
|
|
205
203
|
export const __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
206
204
|
export const __wbindgen_free: (a: number, b: number, c: number) => void;
|