@breeztech/breez-sdk-spark 0.18.0 → 0.19.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 +96 -0
- package/bundler/breez_sdk_spark_wasm.js +1 -1
- package/bundler/breez_sdk_spark_wasm_bg.js +189 -22
- package/bundler/breez_sdk_spark_wasm_bg.wasm +0 -0
- package/bundler/breez_sdk_spark_wasm_bg.wasm.d.ts +15 -6
- package/deno/breez_sdk_spark_wasm.d.ts +96 -0
- package/deno/breez_sdk_spark_wasm.js +189 -22
- package/deno/breez_sdk_spark_wasm_bg.wasm +0 -0
- package/deno/breez_sdk_spark_wasm_bg.wasm.d.ts +15 -6
- package/nodejs/breez_sdk_spark_wasm.d.ts +96 -0
- package/nodejs/breez_sdk_spark_wasm.js +191 -22
- package/nodejs/breez_sdk_spark_wasm_bg.wasm +0 -0
- package/nodejs/breez_sdk_spark_wasm_bg.wasm.d.ts +15 -6
- package/nodejs/index.mjs +2 -0
- package/nodejs/mysql-token-store/index.cjs +212 -70
- package/nodejs/mysql-tree-store/index.cjs +158 -26
- package/nodejs/postgres-token-store/index.cjs +207 -69
- package/nodejs/postgres-tree-store/index.cjs +157 -31
- package/package.json +1 -1
- package/ssr/index.js +12 -0
- package/web/breez_sdk_spark_wasm.d.ts +111 -6
- package/web/breez_sdk_spark_wasm.js +189 -22
- package/web/breez_sdk_spark_wasm_bg.wasm +0 -0
- package/web/breez_sdk_spark_wasm_bg.wasm.d.ts +15 -6
|
@@ -39,16 +39,24 @@ type ReserveResult =
|
|
|
39
39
|
| { type: 'insufficientFunds' }
|
|
40
40
|
| { type: 'waitForPending'; needed: number; available: number; pending: number };
|
|
41
41
|
|
|
42
|
+
type LeafSelection =
|
|
43
|
+
| { type: 'exact'; leaves: TreeNode[] }
|
|
44
|
+
| { type: 'swapNeeded'; leaves: TreeNode[] }
|
|
45
|
+
| { type: 'insufficientFunds' };
|
|
46
|
+
|
|
42
47
|
export interface TreeStore {
|
|
43
48
|
addLeaves: (leaves: TreeNode[]) => Promise<void>;
|
|
44
49
|
getLeaves: () => Promise<Leaves>;
|
|
45
50
|
getAvailableBalance: () => Promise<bigint>;
|
|
51
|
+
getVerifiedLeafKeys: () => Promise<[string, string, string][]>;
|
|
46
52
|
setLeaves: (leaves: TreeNode[], missingLeaves: TreeNode[], refreshStartedAtMs: number) => Promise<void>;
|
|
47
53
|
cancelReservation: (id: string, leavesToKeep: TreeNode[]) => Promise<void>;
|
|
48
54
|
finalizeReservation: (id: string, newLeaves: TreeNode[] | null) => Promise<void>;
|
|
49
55
|
tryReserveLeaves: (targetAmounts: TargetAmounts | null, exactOnly: boolean, purpose: string) => Promise<ReserveResult>;
|
|
50
56
|
now: () => Promise<number>;
|
|
51
57
|
updateReservation: (reservationId: string, reservedLeaves: TreeNode[], changeLeaves: TreeNode[]) => Promise<LeavesReservation>;
|
|
58
|
+
tryReserveLeavesByIds: (leafIds: string[], purpose: string) => Promise<LeavesReservation>;
|
|
59
|
+
trySelectLeaves: (targetAmounts: TargetAmounts | null) => Promise<LeafSelection>;
|
|
52
60
|
}
|
|
53
61
|
|
|
54
62
|
|
|
@@ -123,6 +131,17 @@ export interface TokenStore {
|
|
|
123
131
|
preferredOutputs: WasmTokenOutputWithPrevOut[] | null,
|
|
124
132
|
selectionStrategy: string | null
|
|
125
133
|
) => Promise<WasmTokenOutputsReservation>;
|
|
134
|
+
selectTokenOutputs: (
|
|
135
|
+
tokenIdentifier: string,
|
|
136
|
+
target: WasmReservationTarget,
|
|
137
|
+
preferredOutputs: WasmTokenOutputWithPrevOut[] | null,
|
|
138
|
+
selectionStrategy: string | null
|
|
139
|
+
) => Promise<WasmTokenOutputs>;
|
|
140
|
+
reserveTokenOutputsByOutpoints: (
|
|
141
|
+
tokenIdentifier: string,
|
|
142
|
+
outpoints: { prevTxHash: string; prevTxVout: number }[],
|
|
143
|
+
purpose: string
|
|
144
|
+
) => Promise<WasmTokenOutputsReservation>;
|
|
126
145
|
cancelReservation: (id: string) => Promise<void>;
|
|
127
146
|
finalizeReservation: (id: string) => Promise<void>;
|
|
128
147
|
now: () => Promise<number>;
|
|
@@ -536,6 +555,15 @@ export interface Bolt12OfferDetails {
|
|
|
536
555
|
signingPubkey?: string;
|
|
537
556
|
}
|
|
538
557
|
|
|
558
|
+
export interface BuildUnsignedLnurlPayPackageRequest {
|
|
559
|
+
prepareResponse: PrepareLnurlPayResponse;
|
|
560
|
+
}
|
|
561
|
+
|
|
562
|
+
export interface BuildUnsignedTransferPackageRequest {
|
|
563
|
+
prepareResponse: PrepareSendPaymentResponse;
|
|
564
|
+
options?: BuildTransferPackageOptions;
|
|
565
|
+
}
|
|
566
|
+
|
|
539
567
|
export interface BurnIssuerTokenRequest {
|
|
540
568
|
amount: bigint;
|
|
541
569
|
}
|
|
@@ -1078,6 +1106,12 @@ export interface LnurlInfo {
|
|
|
1078
1106
|
bech32: string;
|
|
1079
1107
|
}
|
|
1080
1108
|
|
|
1109
|
+
export interface LnurlPayContext {
|
|
1110
|
+
payRequest: LnurlPayRequestDetails;
|
|
1111
|
+
comment?: string;
|
|
1112
|
+
successAction?: SuccessAction;
|
|
1113
|
+
}
|
|
1114
|
+
|
|
1081
1115
|
export interface LnurlPayInfo {
|
|
1082
1116
|
lnAddress?: string;
|
|
1083
1117
|
comment?: string;
|
|
@@ -1267,6 +1301,14 @@ export interface PublicKeyBytes {
|
|
|
1267
1301
|
bytes: number[];
|
|
1268
1302
|
}
|
|
1269
1303
|
|
|
1304
|
+
export interface PublishSignedLnurlPayPackageRequest {
|
|
1305
|
+
signedPackage: SignedTransferPackage;
|
|
1306
|
+
}
|
|
1307
|
+
|
|
1308
|
+
export interface PublishSignedTransferPackageRequest {
|
|
1309
|
+
signedPackage: SignedTransferPackage;
|
|
1310
|
+
}
|
|
1311
|
+
|
|
1270
1312
|
export interface Rate {
|
|
1271
1313
|
coin: string;
|
|
1272
1314
|
value: number;
|
|
@@ -1408,6 +1450,11 @@ export interface SignMessageResponse {
|
|
|
1408
1450
|
signature: string;
|
|
1409
1451
|
}
|
|
1410
1452
|
|
|
1453
|
+
export interface SignedTransferPackage {
|
|
1454
|
+
unsigned: UnsignedTransferPackage;
|
|
1455
|
+
signature: TransferSignature;
|
|
1456
|
+
}
|
|
1457
|
+
|
|
1411
1458
|
export interface SilentPaymentAddressDetails {
|
|
1412
1459
|
address: string;
|
|
1413
1460
|
network: BitcoinNetwork;
|
|
@@ -1428,6 +1475,7 @@ export interface SparkConfig {
|
|
|
1428
1475
|
sspConfig: SparkSspConfig;
|
|
1429
1476
|
expectedWithdrawBondSats: number;
|
|
1430
1477
|
expectedWithdrawRelativeBlockLocktime: number;
|
|
1478
|
+
maxTokenTransactionInputs?: number;
|
|
1431
1479
|
}
|
|
1432
1480
|
|
|
1433
1481
|
export interface SparkHtlcDetails {
|
|
@@ -1597,7 +1645,9 @@ export interface TurnkeyConfig {
|
|
|
1597
1645
|
walletId: string;
|
|
1598
1646
|
network: Network;
|
|
1599
1647
|
accountNumber?: number;
|
|
1648
|
+
identityPublicKey?: string;
|
|
1600
1649
|
retry?: TurnkeyRetryConfig;
|
|
1650
|
+
maxRps?: number;
|
|
1601
1651
|
}
|
|
1602
1652
|
|
|
1603
1653
|
export interface TurnkeyRetryConfig {
|
|
@@ -1680,6 +1730,8 @@ export type AutoOptimizationEvent = { type: "started"; totalRounds: number } | {
|
|
|
1680
1730
|
|
|
1681
1731
|
export type BitcoinNetwork = "bitcoin" | "testnet3" | "testnet4" | "signet" | "regtest";
|
|
1682
1732
|
|
|
1733
|
+
export type BuildTransferPackageOptions = { type: "bitcoinAddress"; confirmationSpeed: OnchainConfirmationSpeed } | { type: "bolt11Invoice"; preferSpark: boolean; completionTimeoutSecs?: number };
|
|
1734
|
+
|
|
1683
1735
|
export type BuyBitcoinRequest = { type: "moonpay"; lockedAmountSat?: number; redirectUrl?: string } | { type: "cashApp"; amountSats: number };
|
|
1684
1736
|
|
|
1685
1737
|
export type ChainApiType = "esplora" | "mempoolSpace";
|
|
@@ -1748,6 +1800,10 @@ export type PaymentType = "send" | "receive";
|
|
|
1748
1800
|
|
|
1749
1801
|
export type ProvisionalPaymentDetails = { type: "bitcoin"; withdrawalAddress: string } | { type: "lightning"; invoice: string } | { type: "spark"; payRequest: string } | { type: "token"; tokenId: string; payRequest: string };
|
|
1750
1802
|
|
|
1803
|
+
export type PublishSignedLnurlPayResponse = { type: "swapCompleted" } | { type: "paymentSent"; response: LnurlPayResponse };
|
|
1804
|
+
|
|
1805
|
+
export type PublishSignedTransferPackageResponse = { type: "swapCompleted" } | { type: "paymentSent"; payment: Payment };
|
|
1806
|
+
|
|
1751
1807
|
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 };
|
|
1752
1808
|
|
|
1753
1809
|
export type SdkEvent = { type: "synced" } | { type: "unclaimedDeposits"; unclaimedDeposits: DepositInfo[] } | { type: "claimedDeposits"; claimedDeposits: DepositInfo[] } | { type: "paymentSucceeded"; payment: Payment } | { type: "paymentPending"; payment: Payment } | { type: "paymentFailed"; payment: Payment } | { type: "autoOptimization"; optimizationEvent: AutoOptimizationEvent } | { type: "lightningAddressChanged"; lightningAddress?: LightningAddressInfo } | { type: "newDeposits"; newDeposits: DepositInfo[] };
|
|
@@ -1776,6 +1832,12 @@ export type SuccessActionProcessed = { type: "aes"; result: AesSuccessActionData
|
|
|
1776
1832
|
|
|
1777
1833
|
export type TokenTransactionType = "transfer" | "mint" | "burn";
|
|
1778
1834
|
|
|
1835
|
+
export type TransferSignature = { type: "transfer"; signed: ExternalPreparedTransfer } | { type: "token"; signed: ExternalPreparedTokenTransaction };
|
|
1836
|
+
|
|
1837
|
+
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 };
|
|
1838
|
+
|
|
1839
|
+
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 };
|
|
1840
|
+
|
|
1779
1841
|
export type UpdateDepositPayload = { type: "claimError"; error: DepositClaimError } | { type: "refund"; refundTxid: string; refundTx: string };
|
|
1780
1842
|
|
|
1781
1843
|
export type WebhookEventType = { type: "lightningReceiveFinished" } | { type: "lightningSendFinished" } | { type: "coopExitFinished" } | { type: "staticDepositFinished" } | ({ type: "unknown" } & string);
|
|
@@ -1807,6 +1869,8 @@ export class BreezSdk {
|
|
|
1807
1869
|
addContact(request: AddContactRequest): Promise<Contact>;
|
|
1808
1870
|
addEventListener(listener: EventListener): Promise<string>;
|
|
1809
1871
|
authorizeLightningAddressTransfer(request: AuthorizeTransferRequest): Promise<TransferAuthorization>;
|
|
1872
|
+
buildUnsignedLnurlPayPackage(request: BuildUnsignedLnurlPayPackageRequest): Promise<UnsignedTransferPackage>;
|
|
1873
|
+
buildUnsignedTransferPackage(request: BuildUnsignedTransferPackageRequest): Promise<UnsignedTransferPackage>;
|
|
1810
1874
|
buyBitcoin(request: BuyBitcoinRequest): Promise<BuyBitcoinResponse>;
|
|
1811
1875
|
checkLightningAddressAvailable(request: CheckLightningAddressRequest): Promise<boolean>;
|
|
1812
1876
|
checkMessage(request: CheckMessageRequest): Promise<CheckMessageResponse>;
|
|
@@ -1837,6 +1901,8 @@ export class BreezSdk {
|
|
|
1837
1901
|
parse(input: string): Promise<InputType>;
|
|
1838
1902
|
prepareLnurlPay(request: PrepareLnurlPayRequest): Promise<PrepareLnurlPayResponse>;
|
|
1839
1903
|
prepareSendPayment(request: PrepareSendPaymentRequest): Promise<PrepareSendPaymentResponse>;
|
|
1904
|
+
publishSignedLnurlPayPackage(request: PublishSignedLnurlPayPackageRequest): Promise<PublishSignedLnurlPayResponse>;
|
|
1905
|
+
publishSignedTransferPackage(request: PublishSignedTransferPackageRequest): Promise<PublishSignedTransferPackageResponse>;
|
|
1840
1906
|
receivePayment(request: ReceivePaymentRequest): Promise<ReceivePaymentResponse>;
|
|
1841
1907
|
recommendedFees(): Promise<RecommendedFees>;
|
|
1842
1908
|
refundDeposit(request: RefundDepositRequest): Promise<RefundDepositResponse>;
|
|
@@ -1852,6 +1918,21 @@ export class BreezSdk {
|
|
|
1852
1918
|
updateUserSettings(request: UpdateUserSettingsRequest): Promise<void>;
|
|
1853
1919
|
}
|
|
1854
1920
|
|
|
1921
|
+
/**
|
|
1922
|
+
* A JS handle to a backend's own session store (from `defaultSessionStore`),
|
|
1923
|
+
* exposing the same `getSession` / `setSession` interface. Wrap it in a JS
|
|
1924
|
+
* `SessionStore` decorator and pass that to `SdkBuilder.withSessionStore` to
|
|
1925
|
+
* transform tokens while keeping the backend's persistence: for example
|
|
1926
|
+
* at-rest encryption, which the SDK does not apply itself.
|
|
1927
|
+
*/
|
|
1928
|
+
export class DefaultSessionStore {
|
|
1929
|
+
private constructor();
|
|
1930
|
+
free(): void;
|
|
1931
|
+
[Symbol.dispose](): void;
|
|
1932
|
+
getSession(service_identity_key: string): Promise<Session>;
|
|
1933
|
+
setSession(service_identity_key: string, session: Session): Promise<void>;
|
|
1934
|
+
}
|
|
1935
|
+
|
|
1855
1936
|
/**
|
|
1856
1937
|
* A Rust-backed [`ExternalBreezSigner`] surfaced to JS as a signer object that
|
|
1857
1938
|
* can be passed to `connectWithSigner` or `SdkBuilder.newWithSigner`. Produced
|
|
@@ -2051,6 +2132,13 @@ export class SdkBuilder {
|
|
|
2051
2132
|
*/
|
|
2052
2133
|
withPostgresBackend(config: PostgresStorageConfig): SdkBuilder;
|
|
2053
2134
|
withRestChainService(url: string, api_type: ChainApiType, credentials?: Credentials | null): SdkBuilder;
|
|
2135
|
+
/**
|
|
2136
|
+
* Overrides the session store used to cache auth tokens, replacing the one
|
|
2137
|
+
* the backend provides. Pass any `SessionStore`: for example one that wraps
|
|
2138
|
+
* the backend's own store from `defaultSessionStore` to add at-rest
|
|
2139
|
+
* encryption, which the SDK does not apply itself.
|
|
2140
|
+
*/
|
|
2141
|
+
withSessionStore(session_store: SessionStore): SdkBuilder;
|
|
2054
2142
|
/**
|
|
2055
2143
|
* Threads a shared [`WasmSdkContext`] into the builder.
|
|
2056
2144
|
*
|
|
@@ -2185,6 +2273,14 @@ export function defaultPostgresStorageConfig(connection_string: string): Postgre
|
|
|
2185
2273
|
|
|
2186
2274
|
export function defaultServerConfig(network: Network): Config;
|
|
2187
2275
|
|
|
2276
|
+
/**
|
|
2277
|
+
* The session store the `config`'s backend provides for `identity` (the wallet
|
|
2278
|
+
* identity public key, hex), as a handle to wrap in a `SessionStore` decorator
|
|
2279
|
+
* and pass to `SdkBuilder.withSessionStore`, keeping the backend's persistence.
|
|
2280
|
+
* A typical use is at-rest encryption, which the SDK does not apply itself.
|
|
2281
|
+
*/
|
|
2282
|
+
export function defaultSessionStore(config: WasmStorageConfig, network: Network, identity: string): Promise<DefaultSessionStore>;
|
|
2283
|
+
|
|
2188
2284
|
/**
|
|
2189
2285
|
* File-based storage rooted at `storageDir` — IndexedDB in the browser,
|
|
2190
2286
|
* SQLite under Node.js.
|
|
@@ -117,6 +117,22 @@ class BreezSdk {
|
|
|
117
117
|
const ret = wasm.breezsdk_authorizeLightningAddressTransfer(this.__wbg_ptr, request);
|
|
118
118
|
return ret;
|
|
119
119
|
}
|
|
120
|
+
/**
|
|
121
|
+
* @param {BuildUnsignedLnurlPayPackageRequest} request
|
|
122
|
+
* @returns {Promise<UnsignedTransferPackage>}
|
|
123
|
+
*/
|
|
124
|
+
buildUnsignedLnurlPayPackage(request) {
|
|
125
|
+
const ret = wasm.breezsdk_buildUnsignedLnurlPayPackage(this.__wbg_ptr, request);
|
|
126
|
+
return ret;
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* @param {BuildUnsignedTransferPackageRequest} request
|
|
130
|
+
* @returns {Promise<UnsignedTransferPackage>}
|
|
131
|
+
*/
|
|
132
|
+
buildUnsignedTransferPackage(request) {
|
|
133
|
+
const ret = wasm.breezsdk_buildUnsignedTransferPackage(this.__wbg_ptr, request);
|
|
134
|
+
return ret;
|
|
135
|
+
}
|
|
120
136
|
/**
|
|
121
137
|
* @param {BuyBitcoinRequest} request
|
|
122
138
|
* @returns {Promise<BuyBitcoinResponse>}
|
|
@@ -353,6 +369,22 @@ class BreezSdk {
|
|
|
353
369
|
const ret = wasm.breezsdk_prepareSendPayment(this.__wbg_ptr, request);
|
|
354
370
|
return ret;
|
|
355
371
|
}
|
|
372
|
+
/**
|
|
373
|
+
* @param {PublishSignedLnurlPayPackageRequest} request
|
|
374
|
+
* @returns {Promise<PublishSignedLnurlPayResponse>}
|
|
375
|
+
*/
|
|
376
|
+
publishSignedLnurlPayPackage(request) {
|
|
377
|
+
const ret = wasm.breezsdk_publishSignedLnurlPayPackage(this.__wbg_ptr, request);
|
|
378
|
+
return ret;
|
|
379
|
+
}
|
|
380
|
+
/**
|
|
381
|
+
* @param {PublishSignedTransferPackageRequest} request
|
|
382
|
+
* @returns {Promise<PublishSignedTransferPackageResponse>}
|
|
383
|
+
*/
|
|
384
|
+
publishSignedTransferPackage(request) {
|
|
385
|
+
const ret = wasm.breezsdk_publishSignedTransferPackage(this.__wbg_ptr, request);
|
|
386
|
+
return ret;
|
|
387
|
+
}
|
|
356
388
|
/**
|
|
357
389
|
* @param {ReceivePaymentRequest} request
|
|
358
390
|
* @returns {Promise<ReceivePaymentResponse>}
|
|
@@ -461,6 +493,55 @@ class BreezSdk {
|
|
|
461
493
|
if (Symbol.dispose) BreezSdk.prototype[Symbol.dispose] = BreezSdk.prototype.free;
|
|
462
494
|
exports.BreezSdk = BreezSdk;
|
|
463
495
|
|
|
496
|
+
/**
|
|
497
|
+
* A JS handle to a backend's own session store (from `defaultSessionStore`),
|
|
498
|
+
* exposing the same `getSession` / `setSession` interface. Wrap it in a JS
|
|
499
|
+
* `SessionStore` decorator and pass that to `SdkBuilder.withSessionStore` to
|
|
500
|
+
* transform tokens while keeping the backend's persistence: for example
|
|
501
|
+
* at-rest encryption, which the SDK does not apply itself.
|
|
502
|
+
*/
|
|
503
|
+
class DefaultSessionStore {
|
|
504
|
+
static __wrap(ptr) {
|
|
505
|
+
const obj = Object.create(DefaultSessionStore.prototype);
|
|
506
|
+
obj.__wbg_ptr = ptr;
|
|
507
|
+
DefaultSessionStoreFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
508
|
+
return obj;
|
|
509
|
+
}
|
|
510
|
+
__destroy_into_raw() {
|
|
511
|
+
const ptr = this.__wbg_ptr;
|
|
512
|
+
this.__wbg_ptr = 0;
|
|
513
|
+
DefaultSessionStoreFinalization.unregister(this);
|
|
514
|
+
return ptr;
|
|
515
|
+
}
|
|
516
|
+
free() {
|
|
517
|
+
const ptr = this.__destroy_into_raw();
|
|
518
|
+
wasm.__wbg_defaultsessionstore_free(ptr, 0);
|
|
519
|
+
}
|
|
520
|
+
/**
|
|
521
|
+
* @param {string} service_identity_key
|
|
522
|
+
* @returns {Promise<Session>}
|
|
523
|
+
*/
|
|
524
|
+
getSession(service_identity_key) {
|
|
525
|
+
const ptr0 = passStringToWasm0(service_identity_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
526
|
+
const len0 = WASM_VECTOR_LEN;
|
|
527
|
+
const ret = wasm.defaultsessionstore_getSession(this.__wbg_ptr, ptr0, len0);
|
|
528
|
+
return ret;
|
|
529
|
+
}
|
|
530
|
+
/**
|
|
531
|
+
* @param {string} service_identity_key
|
|
532
|
+
* @param {Session} session
|
|
533
|
+
* @returns {Promise<void>}
|
|
534
|
+
*/
|
|
535
|
+
setSession(service_identity_key, session) {
|
|
536
|
+
const ptr0 = passStringToWasm0(service_identity_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
537
|
+
const len0 = WASM_VECTOR_LEN;
|
|
538
|
+
const ret = wasm.defaultsessionstore_setSession(this.__wbg_ptr, ptr0, len0, session);
|
|
539
|
+
return ret;
|
|
540
|
+
}
|
|
541
|
+
}
|
|
542
|
+
if (Symbol.dispose) DefaultSessionStore.prototype[Symbol.dispose] = DefaultSessionStore.prototype.free;
|
|
543
|
+
exports.DefaultSessionStore = DefaultSessionStore;
|
|
544
|
+
|
|
464
545
|
/**
|
|
465
546
|
* A Rust-backed [`ExternalBreezSigner`] surfaced to JS as a signer object that
|
|
466
547
|
* can be passed to `connectWithSigner` or `SdkBuilder.newWithSigner`. Produced
|
|
@@ -1230,6 +1311,19 @@ class SdkBuilder {
|
|
|
1230
1311
|
const ret = wasm.sdkbuilder_withRestChainService(ptr, ptr0, len0, api_type, isLikeNone(credentials) ? 0 : addToExternrefTable0(credentials));
|
|
1231
1312
|
return SdkBuilder.__wrap(ret);
|
|
1232
1313
|
}
|
|
1314
|
+
/**
|
|
1315
|
+
* Overrides the session store used to cache auth tokens, replacing the one
|
|
1316
|
+
* the backend provides. Pass any `SessionStore`: for example one that wraps
|
|
1317
|
+
* the backend's own store from `defaultSessionStore` to add at-rest
|
|
1318
|
+
* encryption, which the SDK does not apply itself.
|
|
1319
|
+
* @param {SessionStore} session_store
|
|
1320
|
+
* @returns {SdkBuilder}
|
|
1321
|
+
*/
|
|
1322
|
+
withSessionStore(session_store) {
|
|
1323
|
+
const ptr = this.__destroy_into_raw();
|
|
1324
|
+
const ret = wasm.sdkbuilder_withSessionStore(ptr, session_store);
|
|
1325
|
+
return SdkBuilder.__wrap(ret);
|
|
1326
|
+
}
|
|
1233
1327
|
/**
|
|
1234
1328
|
* Threads a shared [`WasmSdkContext`] into the builder.
|
|
1235
1329
|
*
|
|
@@ -1596,6 +1690,25 @@ function defaultServerConfig(network) {
|
|
|
1596
1690
|
}
|
|
1597
1691
|
exports.defaultServerConfig = defaultServerConfig;
|
|
1598
1692
|
|
|
1693
|
+
/**
|
|
1694
|
+
* The session store the `config`'s backend provides for `identity` (the wallet
|
|
1695
|
+
* identity public key, hex), as a handle to wrap in a `SessionStore` decorator
|
|
1696
|
+
* and pass to `SdkBuilder.withSessionStore`, keeping the backend's persistence.
|
|
1697
|
+
* A typical use is at-rest encryption, which the SDK does not apply itself.
|
|
1698
|
+
* @param {WasmStorageConfig} config
|
|
1699
|
+
* @param {Network} network
|
|
1700
|
+
* @param {string} identity
|
|
1701
|
+
* @returns {Promise<DefaultSessionStore>}
|
|
1702
|
+
*/
|
|
1703
|
+
function defaultSessionStore(config, network, identity) {
|
|
1704
|
+
_assertClass(config, WasmStorageConfig);
|
|
1705
|
+
const ptr0 = passStringToWasm0(identity, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1706
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1707
|
+
const ret = wasm.defaultSessionStore(config.__wbg_ptr, network, ptr0, len0);
|
|
1708
|
+
return ret;
|
|
1709
|
+
}
|
|
1710
|
+
exports.defaultSessionStore = defaultSessionStore;
|
|
1711
|
+
|
|
1599
1712
|
/**
|
|
1600
1713
|
* File-based storage rooted at `storageDir` — IndexedDB in the browser,
|
|
1601
1714
|
* SQLite under Node.js.
|
|
@@ -2044,6 +2157,10 @@ function __wbg_get_imports() {
|
|
|
2044
2157
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2045
2158
|
}
|
|
2046
2159
|
}, arguments); },
|
|
2160
|
+
__wbg_defaultsessionstore_new: function(arg0) {
|
|
2161
|
+
const ret = DefaultSessionStore.__wrap(arg0);
|
|
2162
|
+
return ret;
|
|
2163
|
+
},
|
|
2047
2164
|
__wbg_deleteCachedItem_b8fbe3ebea21ed7e: function() { return handleError(function (arg0, arg1, arg2) {
|
|
2048
2165
|
let deferred0_0;
|
|
2049
2166
|
let deferred0_1;
|
|
@@ -2389,6 +2506,10 @@ function __wbg_get_imports() {
|
|
|
2389
2506
|
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
2390
2507
|
}
|
|
2391
2508
|
}, arguments); },
|
|
2509
|
+
__wbg_getVerifiedLeafKeys_12405bb5f39ffb61: function() { return handleError(function (arg0) {
|
|
2510
|
+
const ret = arg0.getVerifiedLeafKeys();
|
|
2511
|
+
return ret;
|
|
2512
|
+
}, arguments); },
|
|
2392
2513
|
__wbg_get_41476db20fef99a8: function() { return handleError(function (arg0, arg1) {
|
|
2393
2514
|
const ret = Reflect.get(arg0, arg1);
|
|
2394
2515
|
return ret;
|
|
@@ -2834,6 +2955,23 @@ function __wbg_get_imports() {
|
|
|
2834
2955
|
const ret = module.require;
|
|
2835
2956
|
return ret;
|
|
2836
2957
|
}, arguments); },
|
|
2958
|
+
__wbg_reserveTokenOutputsByOutpoints_a18be5f9fb4ab30a: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {
|
|
2959
|
+
let deferred0_0;
|
|
2960
|
+
let deferred0_1;
|
|
2961
|
+
let deferred1_0;
|
|
2962
|
+
let deferred1_1;
|
|
2963
|
+
try {
|
|
2964
|
+
deferred0_0 = arg1;
|
|
2965
|
+
deferred0_1 = arg2;
|
|
2966
|
+
deferred1_0 = arg4;
|
|
2967
|
+
deferred1_1 = arg5;
|
|
2968
|
+
const ret = arg0.reserveTokenOutputsByOutpoints(getStringFromWasm0(arg1, arg2), arg3, getStringFromWasm0(arg4, arg5));
|
|
2969
|
+
return ret;
|
|
2970
|
+
} finally {
|
|
2971
|
+
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
2972
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2973
|
+
}
|
|
2974
|
+
}, arguments); },
|
|
2837
2975
|
__wbg_reserveTokenOutputs_233990fbd0ce963a: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) {
|
|
2838
2976
|
let deferred0_0;
|
|
2839
2977
|
let deferred0_1;
|
|
@@ -2862,6 +3000,18 @@ function __wbg_get_imports() {
|
|
|
2862
3000
|
const ret = SdkBuilder.__wrap(arg0);
|
|
2863
3001
|
return ret;
|
|
2864
3002
|
},
|
|
3003
|
+
__wbg_selectTokenOutputs_450f20621013b14d: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {
|
|
3004
|
+
let deferred0_0;
|
|
3005
|
+
let deferred0_1;
|
|
3006
|
+
try {
|
|
3007
|
+
deferred0_0 = arg1;
|
|
3008
|
+
deferred0_1 = arg2;
|
|
3009
|
+
const ret = arg0.selectTokenOutputs(getStringFromWasm0(arg1, arg2), arg3, arg4, arg5);
|
|
3010
|
+
return ret;
|
|
3011
|
+
} finally {
|
|
3012
|
+
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3013
|
+
}
|
|
3014
|
+
}, arguments); },
|
|
2865
3015
|
__wbg_send_0edb796d05cd3239: function() { return handleError(function (arg0, arg1, arg2) {
|
|
2866
3016
|
arg0.send(getStringFromWasm0(arg1, arg2));
|
|
2867
3017
|
}, arguments); },
|
|
@@ -3203,6 +3353,18 @@ function __wbg_get_imports() {
|
|
|
3203
3353
|
const ret = arg0.toString();
|
|
3204
3354
|
return ret;
|
|
3205
3355
|
},
|
|
3356
|
+
__wbg_tryReserveLeavesByIds_a6433e824993a82f: function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3357
|
+
let deferred0_0;
|
|
3358
|
+
let deferred0_1;
|
|
3359
|
+
try {
|
|
3360
|
+
deferred0_0 = arg2;
|
|
3361
|
+
deferred0_1 = arg3;
|
|
3362
|
+
const ret = arg0.tryReserveLeavesByIds(arg1, getStringFromWasm0(arg2, arg3));
|
|
3363
|
+
return ret;
|
|
3364
|
+
} finally {
|
|
3365
|
+
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3366
|
+
}
|
|
3367
|
+
}, arguments); },
|
|
3206
3368
|
__wbg_tryReserveLeaves_d2cd87cbc2a886d2: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
3207
3369
|
let deferred0_0;
|
|
3208
3370
|
let deferred0_1;
|
|
@@ -3215,6 +3377,10 @@ function __wbg_get_imports() {
|
|
|
3215
3377
|
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3216
3378
|
}
|
|
3217
3379
|
}, arguments); },
|
|
3380
|
+
__wbg_trySelectLeaves_ff1aeb7ffc5e4e57: function() { return handleError(function (arg0, arg1) {
|
|
3381
|
+
const ret = arg0.trySelectLeaves(arg1);
|
|
3382
|
+
return ret;
|
|
3383
|
+
}, arguments); },
|
|
3218
3384
|
__wbg_updateDeposit_efb96cf6e6fbe7b7: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
3219
3385
|
let deferred0_0;
|
|
3220
3386
|
let deferred0_1;
|
|
@@ -3279,61 +3445,61 @@ function __wbg_get_imports() {
|
|
|
3279
3445
|
},
|
|
3280
3446
|
__wbindgen_cast_0000000000000001: function(arg0, arg1) {
|
|
3281
3447
|
// 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`.
|
|
3282
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3448
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575);
|
|
3283
3449
|
return ret;
|
|
3284
3450
|
},
|
|
3285
3451
|
__wbindgen_cast_0000000000000002: function(arg0, arg1) {
|
|
3286
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx:
|
|
3452
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3287
3453
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2);
|
|
3288
3454
|
return ret;
|
|
3289
3455
|
},
|
|
3290
3456
|
__wbindgen_cast_0000000000000003: function(arg0, arg1) {
|
|
3291
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx:
|
|
3457
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3292
3458
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_2);
|
|
3293
3459
|
return ret;
|
|
3294
3460
|
},
|
|
3295
3461
|
__wbindgen_cast_0000000000000004: function(arg0, arg1) {
|
|
3296
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("ErrorEvent")], shim_idx:
|
|
3462
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("ErrorEvent")], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3297
3463
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_3);
|
|
3298
3464
|
return ret;
|
|
3299
3465
|
},
|
|
3300
3466
|
__wbindgen_cast_0000000000000005: function(arg0, arg1) {
|
|
3301
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("Event")], shim_idx:
|
|
3467
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("Event")], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3302
3468
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4);
|
|
3303
3469
|
return ret;
|
|
3304
3470
|
},
|
|
3305
3471
|
__wbindgen_cast_0000000000000006: function(arg0, arg1) {
|
|
3306
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx:
|
|
3472
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3307
3473
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5);
|
|
3308
3474
|
return ret;
|
|
3309
3475
|
},
|
|
3310
3476
|
__wbindgen_cast_0000000000000007: function(arg0, arg1) {
|
|
3311
3477
|
// 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`.
|
|
3312
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3478
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575_6);
|
|
3313
3479
|
return ret;
|
|
3314
3480
|
},
|
|
3315
3481
|
__wbindgen_cast_0000000000000008: function(arg0, arg1) {
|
|
3316
3482
|
// 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`.
|
|
3317
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3483
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575_7);
|
|
3318
3484
|
return ret;
|
|
3319
3485
|
},
|
|
3320
3486
|
__wbindgen_cast_0000000000000009: function(arg0, arg1) {
|
|
3321
3487
|
// 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`.
|
|
3322
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3488
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575_8);
|
|
3323
3489
|
return ret;
|
|
3324
3490
|
},
|
|
3325
3491
|
__wbindgen_cast_000000000000000a: function(arg0, arg1) {
|
|
3326
3492
|
// 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`.
|
|
3327
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3493
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575_9);
|
|
3328
3494
|
return ret;
|
|
3329
3495
|
},
|
|
3330
3496
|
__wbindgen_cast_000000000000000b: function(arg0, arg1) {
|
|
3331
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx:
|
|
3497
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 392, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3332
3498
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h1d6669a7b693932a);
|
|
3333
3499
|
return ret;
|
|
3334
3500
|
},
|
|
3335
3501
|
__wbindgen_cast_000000000000000c: function(arg0, arg1) {
|
|
3336
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx:
|
|
3502
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 421, ret: Unit, inner_ret: Some(Unit) }, mutable: false }) -> Externref`.
|
|
3337
3503
|
const ret = makeClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h0fa3f876e31d2a3e);
|
|
3338
3504
|
return ret;
|
|
3339
3505
|
},
|
|
@@ -3453,36 +3619,36 @@ function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5(arg0, a
|
|
|
3453
3619
|
wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5(arg0, arg1, arg2);
|
|
3454
3620
|
}
|
|
3455
3621
|
|
|
3456
|
-
function
|
|
3457
|
-
const ret = wasm.
|
|
3622
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575(arg0, arg1, arg2) {
|
|
3623
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575(arg0, arg1, arg2);
|
|
3458
3624
|
if (ret[1]) {
|
|
3459
3625
|
throw takeFromExternrefTable0(ret[0]);
|
|
3460
3626
|
}
|
|
3461
3627
|
}
|
|
3462
3628
|
|
|
3463
|
-
function
|
|
3464
|
-
const ret = wasm.
|
|
3629
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575_6(arg0, arg1, arg2) {
|
|
3630
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575_6(arg0, arg1, arg2);
|
|
3465
3631
|
if (ret[1]) {
|
|
3466
3632
|
throw takeFromExternrefTable0(ret[0]);
|
|
3467
3633
|
}
|
|
3468
3634
|
}
|
|
3469
3635
|
|
|
3470
|
-
function
|
|
3471
|
-
const ret = wasm.
|
|
3636
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575_7(arg0, arg1, arg2) {
|
|
3637
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575_7(arg0, arg1, arg2);
|
|
3472
3638
|
if (ret[1]) {
|
|
3473
3639
|
throw takeFromExternrefTable0(ret[0]);
|
|
3474
3640
|
}
|
|
3475
3641
|
}
|
|
3476
3642
|
|
|
3477
|
-
function
|
|
3478
|
-
const ret = wasm.
|
|
3643
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575_8(arg0, arg1, arg2) {
|
|
3644
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575_8(arg0, arg1, arg2);
|
|
3479
3645
|
if (ret[1]) {
|
|
3480
3646
|
throw takeFromExternrefTable0(ret[0]);
|
|
3481
3647
|
}
|
|
3482
3648
|
}
|
|
3483
3649
|
|
|
3484
|
-
function
|
|
3485
|
-
const ret = wasm.
|
|
3650
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575_9(arg0, arg1, arg2) {
|
|
3651
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575_9(arg0, arg1, arg2);
|
|
3486
3652
|
if (ret[1]) {
|
|
3487
3653
|
throw takeFromExternrefTable0(ret[0]);
|
|
3488
3654
|
}
|
|
@@ -3518,6 +3684,9 @@ const BitcoinChainServiceHandleFinalization = (typeof FinalizationRegistry === '
|
|
|
3518
3684
|
const BreezSdkFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3519
3685
|
? { register: () => {}, unregister: () => {} }
|
|
3520
3686
|
: new FinalizationRegistry(ptr => wasm.__wbg_breezsdk_free(ptr, 1));
|
|
3687
|
+
const DefaultSessionStoreFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3688
|
+
? { register: () => {}, unregister: () => {} }
|
|
3689
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_defaultsessionstore_free(ptr, 1));
|
|
3521
3690
|
const ExternalBreezSignerHandleFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3522
3691
|
? { register: () => {}, unregister: () => {} }
|
|
3523
3692
|
: new FinalizationRegistry(ptr => wasm.__wbg_externalbreezsignerhandle_free(ptr, 1));
|
|
Binary file
|
|
@@ -18,6 +18,8 @@ export const bitcoinchainservicehandle_recommendedFees: (a: number) => any;
|
|
|
18
18
|
export const breezsdk_addContact: (a: number, b: any) => any;
|
|
19
19
|
export const breezsdk_addEventListener: (a: number, b: any) => any;
|
|
20
20
|
export const breezsdk_authorizeLightningAddressTransfer: (a: number, b: any) => any;
|
|
21
|
+
export const breezsdk_buildUnsignedLnurlPayPackage: (a: number, b: any) => any;
|
|
22
|
+
export const breezsdk_buildUnsignedTransferPackage: (a: number, b: any) => any;
|
|
21
23
|
export const breezsdk_buyBitcoin: (a: number, b: any) => any;
|
|
22
24
|
export const breezsdk_checkLightningAddressAvailable: (a: number, b: any) => any;
|
|
23
25
|
export const breezsdk_checkMessage: (a: number, b: any) => any;
|
|
@@ -48,6 +50,8 @@ export const breezsdk_optimizeLeaves: (a: number, b: any) => any;
|
|
|
48
50
|
export const breezsdk_parse: (a: number, b: number, c: number) => any;
|
|
49
51
|
export const breezsdk_prepareLnurlPay: (a: number, b: any) => any;
|
|
50
52
|
export const breezsdk_prepareSendPayment: (a: number, b: any) => any;
|
|
53
|
+
export const breezsdk_publishSignedLnurlPayPackage: (a: number, b: any) => any;
|
|
54
|
+
export const breezsdk_publishSignedTransferPackage: (a: number, b: any) => any;
|
|
51
55
|
export const breezsdk_receivePayment: (a: number, b: any) => any;
|
|
52
56
|
export const breezsdk_recommendedFees: (a: number) => any;
|
|
53
57
|
export const breezsdk_refundDeposit: (a: number, b: any) => any;
|
|
@@ -71,7 +75,10 @@ export const defaultExternalSigners: (a: number, b: number, c: number, d: number
|
|
|
71
75
|
export const defaultMysqlStorageConfig: (a: number, b: number) => any;
|
|
72
76
|
export const defaultPostgresStorageConfig: (a: number, b: number) => any;
|
|
73
77
|
export const defaultServerConfig: (a: any) => any;
|
|
78
|
+
export const defaultSessionStore: (a: number, b: any, c: number, d: number) => any;
|
|
74
79
|
export const defaultStorage: (a: number, b: number) => number;
|
|
80
|
+
export const defaultsessionstore_getSession: (a: number, b: number, c: number) => any;
|
|
81
|
+
export const defaultsessionstore_setSession: (a: number, b: number, c: number, d: any) => any;
|
|
75
82
|
export const externalbreezsignerhandle_decryptEcies: (a: number, b: number, c: number, d: number, e: number) => any;
|
|
76
83
|
export const externalbreezsignerhandle_derivePublicKey: (a: number, b: number, c: number) => any;
|
|
77
84
|
export const externalbreezsignerhandle_encryptEcies: (a: number, b: number, c: number, d: number, e: number) => any;
|
|
@@ -126,6 +133,7 @@ export const sdkbuilder_withMysqlBackend: (a: number, b: any) => [number, number
|
|
|
126
133
|
export const sdkbuilder_withPaymentObserver: (a: number, b: any) => number;
|
|
127
134
|
export const sdkbuilder_withPostgresBackend: (a: number, b: any) => [number, number, number];
|
|
128
135
|
export const sdkbuilder_withRestChainService: (a: number, b: number, c: number, d: any, e: number) => number;
|
|
136
|
+
export const sdkbuilder_withSessionStore: (a: number, b: any) => number;
|
|
129
137
|
export const sdkbuilder_withSharedContext: (a: number, b: number) => number;
|
|
130
138
|
export const sdkbuilder_withStorage: (a: number, b: any) => number;
|
|
131
139
|
export const sdkbuilder_withStorageBackend: (a: number, b: number) => number;
|
|
@@ -156,16 +164,17 @@ export const intounderlyingsink_write: (a: number, b: any) => any;
|
|
|
156
164
|
export const intounderlyingsource_cancel: (a: number) => void;
|
|
157
165
|
export const intounderlyingsource_pull: (a: number, b: any) => any;
|
|
158
166
|
export const __wbg_externalbreezsignerhandle_free: (a: number, b: number) => void;
|
|
159
|
-
export const
|
|
167
|
+
export const __wbg_defaultsessionstore_free: (a: number, b: number) => void;
|
|
160
168
|
export const __wbg_externalsigningsignerhandle_free: (a: number, b: number) => void;
|
|
169
|
+
export const __wbg_externalsparksignerhandle_free: (a: number, b: number) => void;
|
|
161
170
|
export const __wbg_signingonlyexternalsigners_free: (a: number, b: number) => void;
|
|
162
171
|
export const signingonlyexternalsigners_breezSigner: (a: number) => number;
|
|
163
172
|
export const signingonlyexternalsigners_sparkSigner: (a: number) => number;
|
|
164
|
-
export const
|
|
165
|
-
export const
|
|
166
|
-
export const
|
|
167
|
-
export const
|
|
168
|
-
export const
|
|
173
|
+
export const wasm_bindgen__convert__closures_____invoke__h21f6855640435575: (a: number, b: number, c: any) => [number, number];
|
|
174
|
+
export const wasm_bindgen__convert__closures_____invoke__h21f6855640435575_6: (a: number, b: number, c: any) => [number, number];
|
|
175
|
+
export const wasm_bindgen__convert__closures_____invoke__h21f6855640435575_7: (a: number, b: number, c: any) => [number, number];
|
|
176
|
+
export const wasm_bindgen__convert__closures_____invoke__h21f6855640435575_8: (a: number, b: number, c: any) => [number, number];
|
|
177
|
+
export const wasm_bindgen__convert__closures_____invoke__h21f6855640435575_9: (a: number, b: number, c: any) => [number, number];
|
|
169
178
|
export const wasm_bindgen__convert__closures_____invoke__h41057d61edf43a32: (a: number, b: number, c: any, d: any) => void;
|
|
170
179
|
export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2: (a: number, b: number, c: any) => void;
|
|
171
180
|
export const wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_2: (a: number, b: number, c: any) => void;
|