@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.
|
|
@@ -116,6 +116,22 @@ export class BreezSdk {
|
|
|
116
116
|
const ret = wasm.breezsdk_authorizeLightningAddressTransfer(this.__wbg_ptr, request);
|
|
117
117
|
return ret;
|
|
118
118
|
}
|
|
119
|
+
/**
|
|
120
|
+
* @param {BuildUnsignedLnurlPayPackageRequest} request
|
|
121
|
+
* @returns {Promise<UnsignedTransferPackage>}
|
|
122
|
+
*/
|
|
123
|
+
buildUnsignedLnurlPayPackage(request) {
|
|
124
|
+
const ret = wasm.breezsdk_buildUnsignedLnurlPayPackage(this.__wbg_ptr, request);
|
|
125
|
+
return ret;
|
|
126
|
+
}
|
|
127
|
+
/**
|
|
128
|
+
* @param {BuildUnsignedTransferPackageRequest} request
|
|
129
|
+
* @returns {Promise<UnsignedTransferPackage>}
|
|
130
|
+
*/
|
|
131
|
+
buildUnsignedTransferPackage(request) {
|
|
132
|
+
const ret = wasm.breezsdk_buildUnsignedTransferPackage(this.__wbg_ptr, request);
|
|
133
|
+
return ret;
|
|
134
|
+
}
|
|
119
135
|
/**
|
|
120
136
|
* @param {BuyBitcoinRequest} request
|
|
121
137
|
* @returns {Promise<BuyBitcoinResponse>}
|
|
@@ -352,6 +368,22 @@ export class BreezSdk {
|
|
|
352
368
|
const ret = wasm.breezsdk_prepareSendPayment(this.__wbg_ptr, request);
|
|
353
369
|
return ret;
|
|
354
370
|
}
|
|
371
|
+
/**
|
|
372
|
+
* @param {PublishSignedLnurlPayPackageRequest} request
|
|
373
|
+
* @returns {Promise<PublishSignedLnurlPayResponse>}
|
|
374
|
+
*/
|
|
375
|
+
publishSignedLnurlPayPackage(request) {
|
|
376
|
+
const ret = wasm.breezsdk_publishSignedLnurlPayPackage(this.__wbg_ptr, request);
|
|
377
|
+
return ret;
|
|
378
|
+
}
|
|
379
|
+
/**
|
|
380
|
+
* @param {PublishSignedTransferPackageRequest} request
|
|
381
|
+
* @returns {Promise<PublishSignedTransferPackageResponse>}
|
|
382
|
+
*/
|
|
383
|
+
publishSignedTransferPackage(request) {
|
|
384
|
+
const ret = wasm.breezsdk_publishSignedTransferPackage(this.__wbg_ptr, request);
|
|
385
|
+
return ret;
|
|
386
|
+
}
|
|
355
387
|
/**
|
|
356
388
|
* @param {ReceivePaymentRequest} request
|
|
357
389
|
* @returns {Promise<ReceivePaymentResponse>}
|
|
@@ -459,6 +491,54 @@ export class BreezSdk {
|
|
|
459
491
|
}
|
|
460
492
|
if (Symbol.dispose) BreezSdk.prototype[Symbol.dispose] = BreezSdk.prototype.free;
|
|
461
493
|
|
|
494
|
+
/**
|
|
495
|
+
* A JS handle to a backend's own session store (from `defaultSessionStore`),
|
|
496
|
+
* exposing the same `getSession` / `setSession` interface. Wrap it in a JS
|
|
497
|
+
* `SessionStore` decorator and pass that to `SdkBuilder.withSessionStore` to
|
|
498
|
+
* transform tokens while keeping the backend's persistence: for example
|
|
499
|
+
* at-rest encryption, which the SDK does not apply itself.
|
|
500
|
+
*/
|
|
501
|
+
export class DefaultSessionStore {
|
|
502
|
+
static __wrap(ptr) {
|
|
503
|
+
const obj = Object.create(DefaultSessionStore.prototype);
|
|
504
|
+
obj.__wbg_ptr = ptr;
|
|
505
|
+
DefaultSessionStoreFinalization.register(obj, obj.__wbg_ptr, obj);
|
|
506
|
+
return obj;
|
|
507
|
+
}
|
|
508
|
+
__destroy_into_raw() {
|
|
509
|
+
const ptr = this.__wbg_ptr;
|
|
510
|
+
this.__wbg_ptr = 0;
|
|
511
|
+
DefaultSessionStoreFinalization.unregister(this);
|
|
512
|
+
return ptr;
|
|
513
|
+
}
|
|
514
|
+
free() {
|
|
515
|
+
const ptr = this.__destroy_into_raw();
|
|
516
|
+
wasm.__wbg_defaultsessionstore_free(ptr, 0);
|
|
517
|
+
}
|
|
518
|
+
/**
|
|
519
|
+
* @param {string} service_identity_key
|
|
520
|
+
* @returns {Promise<Session>}
|
|
521
|
+
*/
|
|
522
|
+
getSession(service_identity_key) {
|
|
523
|
+
const ptr0 = passStringToWasm0(service_identity_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
524
|
+
const len0 = WASM_VECTOR_LEN;
|
|
525
|
+
const ret = wasm.defaultsessionstore_getSession(this.__wbg_ptr, ptr0, len0);
|
|
526
|
+
return ret;
|
|
527
|
+
}
|
|
528
|
+
/**
|
|
529
|
+
* @param {string} service_identity_key
|
|
530
|
+
* @param {Session} session
|
|
531
|
+
* @returns {Promise<void>}
|
|
532
|
+
*/
|
|
533
|
+
setSession(service_identity_key, session) {
|
|
534
|
+
const ptr0 = passStringToWasm0(service_identity_key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
535
|
+
const len0 = WASM_VECTOR_LEN;
|
|
536
|
+
const ret = wasm.defaultsessionstore_setSession(this.__wbg_ptr, ptr0, len0, session);
|
|
537
|
+
return ret;
|
|
538
|
+
}
|
|
539
|
+
}
|
|
540
|
+
if (Symbol.dispose) DefaultSessionStore.prototype[Symbol.dispose] = DefaultSessionStore.prototype.free;
|
|
541
|
+
|
|
462
542
|
/**
|
|
463
543
|
* A Rust-backed [`ExternalBreezSigner`] surfaced to JS as a signer object that
|
|
464
544
|
* can be passed to `connectWithSigner` or `SdkBuilder.newWithSigner`. Produced
|
|
@@ -1219,6 +1299,19 @@ export class SdkBuilder {
|
|
|
1219
1299
|
const ret = wasm.sdkbuilder_withRestChainService(ptr, ptr0, len0, api_type, isLikeNone(credentials) ? 0 : addToExternrefTable0(credentials));
|
|
1220
1300
|
return SdkBuilder.__wrap(ret);
|
|
1221
1301
|
}
|
|
1302
|
+
/**
|
|
1303
|
+
* Overrides the session store used to cache auth tokens, replacing the one
|
|
1304
|
+
* the backend provides. Pass any `SessionStore`: for example one that wraps
|
|
1305
|
+
* the backend's own store from `defaultSessionStore` to add at-rest
|
|
1306
|
+
* encryption, which the SDK does not apply itself.
|
|
1307
|
+
* @param {SessionStore} session_store
|
|
1308
|
+
* @returns {SdkBuilder}
|
|
1309
|
+
*/
|
|
1310
|
+
withSessionStore(session_store) {
|
|
1311
|
+
const ptr = this.__destroy_into_raw();
|
|
1312
|
+
const ret = wasm.sdkbuilder_withSessionStore(ptr, session_store);
|
|
1313
|
+
return SdkBuilder.__wrap(ret);
|
|
1314
|
+
}
|
|
1222
1315
|
/**
|
|
1223
1316
|
* Threads a shared [`WasmSdkContext`] into the builder.
|
|
1224
1317
|
*
|
|
@@ -1570,6 +1663,24 @@ export function defaultServerConfig(network) {
|
|
|
1570
1663
|
return ret;
|
|
1571
1664
|
}
|
|
1572
1665
|
|
|
1666
|
+
/**
|
|
1667
|
+
* The session store the `config`'s backend provides for `identity` (the wallet
|
|
1668
|
+
* identity public key, hex), as a handle to wrap in a `SessionStore` decorator
|
|
1669
|
+
* and pass to `SdkBuilder.withSessionStore`, keeping the backend's persistence.
|
|
1670
|
+
* A typical use is at-rest encryption, which the SDK does not apply itself.
|
|
1671
|
+
* @param {WasmStorageConfig} config
|
|
1672
|
+
* @param {Network} network
|
|
1673
|
+
* @param {string} identity
|
|
1674
|
+
* @returns {Promise<DefaultSessionStore>}
|
|
1675
|
+
*/
|
|
1676
|
+
export function defaultSessionStore(config, network, identity) {
|
|
1677
|
+
_assertClass(config, WasmStorageConfig);
|
|
1678
|
+
const ptr0 = passStringToWasm0(identity, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
1679
|
+
const len0 = WASM_VECTOR_LEN;
|
|
1680
|
+
const ret = wasm.defaultSessionStore(config.__wbg_ptr, network, ptr0, len0);
|
|
1681
|
+
return ret;
|
|
1682
|
+
}
|
|
1683
|
+
|
|
1573
1684
|
/**
|
|
1574
1685
|
* File-based storage rooted at `storageDir` — IndexedDB in the browser,
|
|
1575
1686
|
* SQLite under Node.js.
|
|
@@ -2009,6 +2120,10 @@ function __wbg_get_imports() {
|
|
|
2009
2120
|
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2010
2121
|
}
|
|
2011
2122
|
}, arguments); },
|
|
2123
|
+
__wbg_defaultsessionstore_new: function(arg0) {
|
|
2124
|
+
const ret = DefaultSessionStore.__wrap(arg0);
|
|
2125
|
+
return ret;
|
|
2126
|
+
},
|
|
2012
2127
|
__wbg_deleteCachedItem_b8fbe3ebea21ed7e: function() { return handleError(function (arg0, arg1, arg2) {
|
|
2013
2128
|
let deferred0_0;
|
|
2014
2129
|
let deferred0_1;
|
|
@@ -2354,6 +2469,10 @@ function __wbg_get_imports() {
|
|
|
2354
2469
|
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
2355
2470
|
}
|
|
2356
2471
|
}, arguments); },
|
|
2472
|
+
__wbg_getVerifiedLeafKeys_12405bb5f39ffb61: function() { return handleError(function (arg0) {
|
|
2473
|
+
const ret = arg0.getVerifiedLeafKeys();
|
|
2474
|
+
return ret;
|
|
2475
|
+
}, arguments); },
|
|
2357
2476
|
__wbg_get_41476db20fef99a8: function() { return handleError(function (arg0, arg1) {
|
|
2358
2477
|
const ret = Reflect.get(arg0, arg1);
|
|
2359
2478
|
return ret;
|
|
@@ -2799,6 +2918,23 @@ function __wbg_get_imports() {
|
|
|
2799
2918
|
const ret = module.require;
|
|
2800
2919
|
return ret;
|
|
2801
2920
|
}, arguments); },
|
|
2921
|
+
__wbg_reserveTokenOutputsByOutpoints_a18be5f9fb4ab30a: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {
|
|
2922
|
+
let deferred0_0;
|
|
2923
|
+
let deferred0_1;
|
|
2924
|
+
let deferred1_0;
|
|
2925
|
+
let deferred1_1;
|
|
2926
|
+
try {
|
|
2927
|
+
deferred0_0 = arg1;
|
|
2928
|
+
deferred0_1 = arg2;
|
|
2929
|
+
deferred1_0 = arg4;
|
|
2930
|
+
deferred1_1 = arg5;
|
|
2931
|
+
const ret = arg0.reserveTokenOutputsByOutpoints(getStringFromWasm0(arg1, arg2), arg3, getStringFromWasm0(arg4, arg5));
|
|
2932
|
+
return ret;
|
|
2933
|
+
} finally {
|
|
2934
|
+
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
2935
|
+
wasm.__wbindgen_free(deferred1_0, deferred1_1, 1);
|
|
2936
|
+
}
|
|
2937
|
+
}, arguments); },
|
|
2802
2938
|
__wbg_reserveTokenOutputs_233990fbd0ce963a: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) {
|
|
2803
2939
|
let deferred0_0;
|
|
2804
2940
|
let deferred0_1;
|
|
@@ -2827,6 +2963,18 @@ function __wbg_get_imports() {
|
|
|
2827
2963
|
const ret = SdkBuilder.__wrap(arg0);
|
|
2828
2964
|
return ret;
|
|
2829
2965
|
},
|
|
2966
|
+
__wbg_selectTokenOutputs_450f20621013b14d: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {
|
|
2967
|
+
let deferred0_0;
|
|
2968
|
+
let deferred0_1;
|
|
2969
|
+
try {
|
|
2970
|
+
deferred0_0 = arg1;
|
|
2971
|
+
deferred0_1 = arg2;
|
|
2972
|
+
const ret = arg0.selectTokenOutputs(getStringFromWasm0(arg1, arg2), arg3, arg4, arg5);
|
|
2973
|
+
return ret;
|
|
2974
|
+
} finally {
|
|
2975
|
+
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
2976
|
+
}
|
|
2977
|
+
}, arguments); },
|
|
2830
2978
|
__wbg_send_0edb796d05cd3239: function() { return handleError(function (arg0, arg1, arg2) {
|
|
2831
2979
|
arg0.send(getStringFromWasm0(arg1, arg2));
|
|
2832
2980
|
}, arguments); },
|
|
@@ -3168,6 +3316,18 @@ function __wbg_get_imports() {
|
|
|
3168
3316
|
const ret = arg0.toString();
|
|
3169
3317
|
return ret;
|
|
3170
3318
|
},
|
|
3319
|
+
__wbg_tryReserveLeavesByIds_a6433e824993a82f: function() { return handleError(function (arg0, arg1, arg2, arg3) {
|
|
3320
|
+
let deferred0_0;
|
|
3321
|
+
let deferred0_1;
|
|
3322
|
+
try {
|
|
3323
|
+
deferred0_0 = arg2;
|
|
3324
|
+
deferred0_1 = arg3;
|
|
3325
|
+
const ret = arg0.tryReserveLeavesByIds(arg1, getStringFromWasm0(arg2, arg3));
|
|
3326
|
+
return ret;
|
|
3327
|
+
} finally {
|
|
3328
|
+
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3329
|
+
}
|
|
3330
|
+
}, arguments); },
|
|
3171
3331
|
__wbg_tryReserveLeaves_d2cd87cbc2a886d2: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
3172
3332
|
let deferred0_0;
|
|
3173
3333
|
let deferred0_1;
|
|
@@ -3180,6 +3340,10 @@ function __wbg_get_imports() {
|
|
|
3180
3340
|
wasm.__wbindgen_free(deferred0_0, deferred0_1, 1);
|
|
3181
3341
|
}
|
|
3182
3342
|
}, arguments); },
|
|
3343
|
+
__wbg_trySelectLeaves_ff1aeb7ffc5e4e57: function() { return handleError(function (arg0, arg1) {
|
|
3344
|
+
const ret = arg0.trySelectLeaves(arg1);
|
|
3345
|
+
return ret;
|
|
3346
|
+
}, arguments); },
|
|
3183
3347
|
__wbg_updateDeposit_efb96cf6e6fbe7b7: function() { return handleError(function (arg0, arg1, arg2, arg3, arg4) {
|
|
3184
3348
|
let deferred0_0;
|
|
3185
3349
|
let deferred0_1;
|
|
@@ -3244,61 +3408,61 @@ function __wbg_get_imports() {
|
|
|
3244
3408
|
},
|
|
3245
3409
|
__wbindgen_cast_0000000000000001: function(arg0, arg1) {
|
|
3246
3410
|
// 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`.
|
|
3247
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3411
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575);
|
|
3248
3412
|
return ret;
|
|
3249
3413
|
},
|
|
3250
3414
|
__wbindgen_cast_0000000000000002: function(arg0, arg1) {
|
|
3251
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx:
|
|
3415
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3252
3416
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2);
|
|
3253
3417
|
return ret;
|
|
3254
3418
|
},
|
|
3255
3419
|
__wbindgen_cast_0000000000000003: function(arg0, arg1) {
|
|
3256
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx:
|
|
3420
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("CloseEvent")], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3257
3421
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_2);
|
|
3258
3422
|
return ret;
|
|
3259
3423
|
},
|
|
3260
3424
|
__wbindgen_cast_0000000000000004: function(arg0, arg1) {
|
|
3261
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("ErrorEvent")], shim_idx:
|
|
3425
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("ErrorEvent")], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3262
3426
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_3);
|
|
3263
3427
|
return ret;
|
|
3264
3428
|
},
|
|
3265
3429
|
__wbindgen_cast_0000000000000005: function(arg0, arg1) {
|
|
3266
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("Event")], shim_idx:
|
|
3430
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("Event")], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3267
3431
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_4);
|
|
3268
3432
|
return ret;
|
|
3269
3433
|
},
|
|
3270
3434
|
__wbindgen_cast_0000000000000006: function(arg0, arg1) {
|
|
3271
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx:
|
|
3435
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [NamedExternref("MessageEvent")], shim_idx: 230, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3272
3436
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5);
|
|
3273
3437
|
return ret;
|
|
3274
3438
|
},
|
|
3275
3439
|
__wbindgen_cast_0000000000000007: function(arg0, arg1) {
|
|
3276
3440
|
// 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`.
|
|
3277
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3441
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575_6);
|
|
3278
3442
|
return ret;
|
|
3279
3443
|
},
|
|
3280
3444
|
__wbindgen_cast_0000000000000008: function(arg0, arg1) {
|
|
3281
3445
|
// 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`.
|
|
3282
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3446
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575_7);
|
|
3283
3447
|
return ret;
|
|
3284
3448
|
},
|
|
3285
3449
|
__wbindgen_cast_0000000000000009: function(arg0, arg1) {
|
|
3286
3450
|
// 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`.
|
|
3287
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3451
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575_8);
|
|
3288
3452
|
return ret;
|
|
3289
3453
|
},
|
|
3290
3454
|
__wbindgen_cast_000000000000000a: function(arg0, arg1) {
|
|
3291
3455
|
// 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`.
|
|
3292
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
3456
|
+
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h21f6855640435575_9);
|
|
3293
3457
|
return ret;
|
|
3294
3458
|
},
|
|
3295
3459
|
__wbindgen_cast_000000000000000b: function(arg0, arg1) {
|
|
3296
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx:
|
|
3460
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 392, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
|
|
3297
3461
|
const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h1d6669a7b693932a);
|
|
3298
3462
|
return ret;
|
|
3299
3463
|
},
|
|
3300
3464
|
__wbindgen_cast_000000000000000c: function(arg0, arg1) {
|
|
3301
|
-
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx:
|
|
3465
|
+
// Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 421, ret: Unit, inner_ret: Some(Unit) }, mutable: false }) -> Externref`.
|
|
3302
3466
|
const ret = makeClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h0fa3f876e31d2a3e);
|
|
3303
3467
|
return ret;
|
|
3304
3468
|
},
|
|
@@ -3418,36 +3582,36 @@ function wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5(arg0, a
|
|
|
3418
3582
|
wasm.wasm_bindgen__convert__closures_____invoke__h3120db8c4a8a92b2_5(arg0, arg1, arg2);
|
|
3419
3583
|
}
|
|
3420
3584
|
|
|
3421
|
-
function
|
|
3422
|
-
const ret = wasm.
|
|
3585
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575(arg0, arg1, arg2) {
|
|
3586
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575(arg0, arg1, arg2);
|
|
3423
3587
|
if (ret[1]) {
|
|
3424
3588
|
throw takeFromExternrefTable0(ret[0]);
|
|
3425
3589
|
}
|
|
3426
3590
|
}
|
|
3427
3591
|
|
|
3428
|
-
function
|
|
3429
|
-
const ret = wasm.
|
|
3592
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575_6(arg0, arg1, arg2) {
|
|
3593
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575_6(arg0, arg1, arg2);
|
|
3430
3594
|
if (ret[1]) {
|
|
3431
3595
|
throw takeFromExternrefTable0(ret[0]);
|
|
3432
3596
|
}
|
|
3433
3597
|
}
|
|
3434
3598
|
|
|
3435
|
-
function
|
|
3436
|
-
const ret = wasm.
|
|
3599
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575_7(arg0, arg1, arg2) {
|
|
3600
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575_7(arg0, arg1, arg2);
|
|
3437
3601
|
if (ret[1]) {
|
|
3438
3602
|
throw takeFromExternrefTable0(ret[0]);
|
|
3439
3603
|
}
|
|
3440
3604
|
}
|
|
3441
3605
|
|
|
3442
|
-
function
|
|
3443
|
-
const ret = wasm.
|
|
3606
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575_8(arg0, arg1, arg2) {
|
|
3607
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575_8(arg0, arg1, arg2);
|
|
3444
3608
|
if (ret[1]) {
|
|
3445
3609
|
throw takeFromExternrefTable0(ret[0]);
|
|
3446
3610
|
}
|
|
3447
3611
|
}
|
|
3448
3612
|
|
|
3449
|
-
function
|
|
3450
|
-
const ret = wasm.
|
|
3613
|
+
function wasm_bindgen__convert__closures_____invoke__h21f6855640435575_9(arg0, arg1, arg2) {
|
|
3614
|
+
const ret = wasm.wasm_bindgen__convert__closures_____invoke__h21f6855640435575_9(arg0, arg1, arg2);
|
|
3451
3615
|
if (ret[1]) {
|
|
3452
3616
|
throw takeFromExternrefTable0(ret[0]);
|
|
3453
3617
|
}
|
|
@@ -3483,6 +3647,9 @@ const BitcoinChainServiceHandleFinalization = (typeof FinalizationRegistry === '
|
|
|
3483
3647
|
const BreezSdkFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3484
3648
|
? { register: () => {}, unregister: () => {} }
|
|
3485
3649
|
: new FinalizationRegistry(ptr => wasm.__wbg_breezsdk_free(ptr, 1));
|
|
3650
|
+
const DefaultSessionStoreFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3651
|
+
? { register: () => {}, unregister: () => {} }
|
|
3652
|
+
: new FinalizationRegistry(ptr => wasm.__wbg_defaultsessionstore_free(ptr, 1));
|
|
3486
3653
|
const ExternalBreezSignerHandleFinalization = (typeof FinalizationRegistry === 'undefined')
|
|
3487
3654
|
? { register: () => {}, unregister: () => {} }
|
|
3488
3655
|
: 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;
|