bitmask-core 0.7.6-beta.1 → 0.7.6-beta.2
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/bitmask_core.d.ts +80 -80
- package/bitmask_core.js +211 -211
- package/bitmask_core_bg.wasm +0 -0
- package/bitmask_core_bg.wasm.d.ts +14 -14
- package/package.json +1 -1
package/bitmask_core.d.ts
CHANGED
|
@@ -1,31 +1,6 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
/**
|
|
4
|
-
* @returns {Promise<any>}
|
|
5
|
-
*/
|
|
6
|
-
export function get_network(): Promise<any>;
|
|
7
|
-
/**
|
|
8
|
-
* @param {string} network_str
|
|
9
|
-
* @returns {Promise<any>}
|
|
10
|
-
*/
|
|
11
|
-
export function switch_network(network_str: string): Promise<any>;
|
|
12
|
-
/**
|
|
13
|
-
* @param {string} key
|
|
14
|
-
* @returns {Promise<any>}
|
|
15
|
-
*/
|
|
16
|
-
export function get_env(key: string): Promise<any>;
|
|
17
|
-
/**
|
|
18
|
-
* @param {string} key
|
|
19
|
-
* @param {string} value
|
|
20
|
-
* @returns {Promise<any>}
|
|
21
|
-
*/
|
|
22
|
-
export function set_env(key: string, value: string): Promise<any>;
|
|
23
|
-
/**
|
|
24
|
-
* @param {number} ms
|
|
25
|
-
* @returns {Promise<any>}
|
|
26
|
-
*/
|
|
27
|
-
export function sleep(ms: number): Promise<any>;
|
|
28
|
-
/**
|
|
29
4
|
* @param {string} password
|
|
30
5
|
* @returns {string}
|
|
31
6
|
*/
|
|
@@ -136,6 +111,47 @@ export function psbt_sign_and_publish_file(request: any): Promise<any>;
|
|
|
136
111
|
*/
|
|
137
112
|
export function psbt_publish_file(request: any): Promise<any>;
|
|
138
113
|
/**
|
|
114
|
+
* @param {string} secret_key
|
|
115
|
+
* @param {string} name
|
|
116
|
+
* @param {Uint8Array} data
|
|
117
|
+
* @param {boolean} force
|
|
118
|
+
* @param {Uint8Array | undefined} [metadata]
|
|
119
|
+
* @returns {Promise<any>}
|
|
120
|
+
*/
|
|
121
|
+
export function store(secret_key: string, name: string, data: Uint8Array, force: boolean, metadata?: Uint8Array): Promise<any>;
|
|
122
|
+
/**
|
|
123
|
+
* @param {string} secret_key
|
|
124
|
+
* @param {string} name
|
|
125
|
+
* @returns {Promise<any>}
|
|
126
|
+
*/
|
|
127
|
+
export function retrieve(secret_key: string, name: string): Promise<any>;
|
|
128
|
+
/**
|
|
129
|
+
* @param {string} secret_key
|
|
130
|
+
* @param {string} name
|
|
131
|
+
* @returns {Promise<any>}
|
|
132
|
+
*/
|
|
133
|
+
export function retrieve_metadata(secret_key: string, name: string): Promise<any>;
|
|
134
|
+
/**
|
|
135
|
+
* @param {Uint8Array} bytes
|
|
136
|
+
* @returns {string}
|
|
137
|
+
*/
|
|
138
|
+
export function encode_hex(bytes: Uint8Array): string;
|
|
139
|
+
/**
|
|
140
|
+
* @param {Uint8Array} bytes
|
|
141
|
+
* @returns {string}
|
|
142
|
+
*/
|
|
143
|
+
export function encode_base64(bytes: Uint8Array): string;
|
|
144
|
+
/**
|
|
145
|
+
* @param {string} string
|
|
146
|
+
* @returns {Uint8Array}
|
|
147
|
+
*/
|
|
148
|
+
export function decode_hex(string: string): Uint8Array;
|
|
149
|
+
/**
|
|
150
|
+
* @param {string} string
|
|
151
|
+
* @returns {Uint8Array}
|
|
152
|
+
*/
|
|
153
|
+
export function decode_base64(string: string): Uint8Array;
|
|
154
|
+
/**
|
|
139
155
|
* @param {string} username
|
|
140
156
|
* @param {string} password
|
|
141
157
|
* @returns {Promise<any>}
|
|
@@ -189,47 +205,6 @@ export function swap_btc_ln(token: string, ln_address?: string): Promise<any>;
|
|
|
189
205
|
*/
|
|
190
206
|
export function swap_ln_btc(address: string, amount: bigint, token: string): Promise<any>;
|
|
191
207
|
/**
|
|
192
|
-
* @param {string} secret_key
|
|
193
|
-
* @param {string} name
|
|
194
|
-
* @param {Uint8Array} data
|
|
195
|
-
* @param {boolean} force
|
|
196
|
-
* @param {Uint8Array | undefined} [metadata]
|
|
197
|
-
* @returns {Promise<any>}
|
|
198
|
-
*/
|
|
199
|
-
export function store(secret_key: string, name: string, data: Uint8Array, force: boolean, metadata?: Uint8Array): Promise<any>;
|
|
200
|
-
/**
|
|
201
|
-
* @param {string} secret_key
|
|
202
|
-
* @param {string} name
|
|
203
|
-
* @returns {Promise<any>}
|
|
204
|
-
*/
|
|
205
|
-
export function retrieve(secret_key: string, name: string): Promise<any>;
|
|
206
|
-
/**
|
|
207
|
-
* @param {string} secret_key
|
|
208
|
-
* @param {string} name
|
|
209
|
-
* @returns {Promise<any>}
|
|
210
|
-
*/
|
|
211
|
-
export function retrieve_metadata(secret_key: string, name: string): Promise<any>;
|
|
212
|
-
/**
|
|
213
|
-
* @param {Uint8Array} bytes
|
|
214
|
-
* @returns {string}
|
|
215
|
-
*/
|
|
216
|
-
export function encode_hex(bytes: Uint8Array): string;
|
|
217
|
-
/**
|
|
218
|
-
* @param {Uint8Array} bytes
|
|
219
|
-
* @returns {string}
|
|
220
|
-
*/
|
|
221
|
-
export function encode_base64(bytes: Uint8Array): string;
|
|
222
|
-
/**
|
|
223
|
-
* @param {string} string
|
|
224
|
-
* @returns {Uint8Array}
|
|
225
|
-
*/
|
|
226
|
-
export function decode_hex(string: string): Uint8Array;
|
|
227
|
-
/**
|
|
228
|
-
* @param {string} string
|
|
229
|
-
* @returns {Uint8Array}
|
|
230
|
-
*/
|
|
231
|
-
export function decode_base64(string: string): Uint8Array;
|
|
232
|
-
/**
|
|
233
208
|
* @param {string} pubkey
|
|
234
209
|
* @param {string} token
|
|
235
210
|
* @returns {Promise<any>}
|
|
@@ -269,6 +244,31 @@ export function parse_contract_amount_precision(amount: string, precision: numbe
|
|
|
269
244
|
*/
|
|
270
245
|
export function version(): any;
|
|
271
246
|
/**
|
|
247
|
+
* @returns {Promise<any>}
|
|
248
|
+
*/
|
|
249
|
+
export function get_network(): Promise<any>;
|
|
250
|
+
/**
|
|
251
|
+
* @param {string} network_str
|
|
252
|
+
* @returns {Promise<any>}
|
|
253
|
+
*/
|
|
254
|
+
export function switch_network(network_str: string): Promise<any>;
|
|
255
|
+
/**
|
|
256
|
+
* @param {string} key
|
|
257
|
+
* @returns {Promise<any>}
|
|
258
|
+
*/
|
|
259
|
+
export function get_env(key: string): Promise<any>;
|
|
260
|
+
/**
|
|
261
|
+
* @param {string} key
|
|
262
|
+
* @param {string} value
|
|
263
|
+
* @returns {Promise<any>}
|
|
264
|
+
*/
|
|
265
|
+
export function set_env(key: string, value: string): Promise<any>;
|
|
266
|
+
/**
|
|
267
|
+
* @param {number} ms
|
|
268
|
+
* @returns {Promise<any>}
|
|
269
|
+
*/
|
|
270
|
+
export function sleep(ms: number): Promise<any>;
|
|
271
|
+
/**
|
|
272
272
|
* @param {string} nostr_hex_sk
|
|
273
273
|
* @param {boolean} hidden
|
|
274
274
|
* @returns {Promise<any>}
|
|
@@ -525,11 +525,6 @@ export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembl
|
|
|
525
525
|
|
|
526
526
|
export interface InitOutput {
|
|
527
527
|
readonly memory: WebAssembly.Memory;
|
|
528
|
-
readonly get_network: () => number;
|
|
529
|
-
readonly switch_network: (a: number, b: number) => number;
|
|
530
|
-
readonly get_env: (a: number, b: number) => number;
|
|
531
|
-
readonly set_env: (a: number, b: number, c: number, d: number) => number;
|
|
532
|
-
readonly sleep: (a: number) => number;
|
|
533
528
|
readonly hash_password: (a: number, b: number, c: number) => void;
|
|
534
529
|
readonly new_mnemonic: (a: number, b: number) => number;
|
|
535
530
|
readonly save_mnemonic: (a: number, b: number, c: number, d: number) => number;
|
|
@@ -547,6 +542,13 @@ export interface InitOutput {
|
|
|
547
542
|
readonly bump_fee: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number) => number;
|
|
548
543
|
readonly psbt_sign_and_publish_file: (a: number) => number;
|
|
549
544
|
readonly psbt_publish_file: (a: number) => number;
|
|
545
|
+
readonly store: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number) => number;
|
|
546
|
+
readonly retrieve: (a: number, b: number, c: number, d: number) => number;
|
|
547
|
+
readonly retrieve_metadata: (a: number, b: number, c: number, d: number) => number;
|
|
548
|
+
readonly encode_hex: (a: number, b: number, c: number) => void;
|
|
549
|
+
readonly encode_base64: (a: number, b: number, c: number) => void;
|
|
550
|
+
readonly decode_hex: (a: number, b: number, c: number) => void;
|
|
551
|
+
readonly decode_base64: (a: number, b: number, c: number) => void;
|
|
550
552
|
readonly create_wallet: (a: number, b: number, c: number, d: number) => number;
|
|
551
553
|
readonly auth: (a: number, b: number, c: number, d: number) => number;
|
|
552
554
|
readonly ln_create_invoice: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
@@ -556,13 +558,6 @@ export interface InitOutput {
|
|
|
556
558
|
readonly check_payment: (a: number, b: number) => number;
|
|
557
559
|
readonly swap_btc_ln: (a: number, b: number, c: number, d: number) => number;
|
|
558
560
|
readonly swap_ln_btc: (a: number, b: number, c: number, d: number, e: number) => number;
|
|
559
|
-
readonly store: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number) => number;
|
|
560
|
-
readonly retrieve: (a: number, b: number, c: number, d: number) => number;
|
|
561
|
-
readonly retrieve_metadata: (a: number, b: number, c: number, d: number) => number;
|
|
562
|
-
readonly encode_hex: (a: number, b: number, c: number) => void;
|
|
563
|
-
readonly encode_base64: (a: number, b: number, c: number) => void;
|
|
564
|
-
readonly decode_hex: (a: number, b: number, c: number) => void;
|
|
565
|
-
readonly decode_base64: (a: number, b: number, c: number) => void;
|
|
566
561
|
readonly new_nostr_pubkey: (a: number, b: number, c: number, d: number) => number;
|
|
567
562
|
readonly update_nostr_pubkey: (a: number, b: number, c: number, d: number) => number;
|
|
568
563
|
readonly convert_contract_amount_raw: (a: number, b: number, c: number, d: number) => void;
|
|
@@ -570,6 +565,11 @@ export interface InitOutput {
|
|
|
570
565
|
readonly parse_contract_amount: (a: number, b: number) => number;
|
|
571
566
|
readonly parse_contract_amount_precision: (a: number, b: number, c: number, d: number) => void;
|
|
572
567
|
readonly version: () => number;
|
|
568
|
+
readonly get_network: () => number;
|
|
569
|
+
readonly switch_network: (a: number, b: number) => number;
|
|
570
|
+
readonly get_env: (a: number, b: number) => number;
|
|
571
|
+
readonly set_env: (a: number, b: number, c: number, d: number) => number;
|
|
572
|
+
readonly sleep: (a: number) => number;
|
|
573
573
|
readonly list_contracts: (a: number, b: number, c: number) => number;
|
|
574
574
|
readonly get_contract: (a: number, b: number, c: number, d: number) => number;
|
|
575
575
|
readonly import_contract: (a: number, b: number, c: number, d: number) => number;
|
|
@@ -633,11 +633,11 @@ export interface InitOutput {
|
|
|
633
633
|
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
634
634
|
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
635
635
|
readonly __wbindgen_export_2: WebAssembly.Table;
|
|
636
|
-
readonly
|
|
636
|
+
readonly _dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__haa7e522923c6e229: (a: number, b: number, c: number) => void;
|
|
637
637
|
readonly __wbindgen_add_to_stack_pointer: (a: number) => number;
|
|
638
638
|
readonly __wbindgen_free: (a: number, b: number, c: number) => void;
|
|
639
639
|
readonly __wbindgen_exn_store: (a: number) => void;
|
|
640
|
-
readonly
|
|
640
|
+
readonly wasm_bindgen__convert__closures__invoke2_mut__ha34478490d8c61d2: (a: number, b: number, c: number, d: number) => void;
|
|
641
641
|
}
|
|
642
642
|
|
|
643
643
|
export type SyncInitInput = BufferSource | WebAssembly.Module;
|
package/bitmask_core.js
CHANGED
|
@@ -223,60 +223,7 @@ function makeMutClosure(arg0, arg1, dtor, f) {
|
|
|
223
223
|
return real;
|
|
224
224
|
}
|
|
225
225
|
function __wbg_adapter_50(arg0, arg1, arg2) {
|
|
226
|
-
wasm.
|
|
227
|
-
}
|
|
228
|
-
|
|
229
|
-
/**
|
|
230
|
-
* @returns {Promise<any>}
|
|
231
|
-
*/
|
|
232
|
-
export function get_network() {
|
|
233
|
-
const ret = wasm.get_network();
|
|
234
|
-
return takeObject(ret);
|
|
235
|
-
}
|
|
236
|
-
|
|
237
|
-
/**
|
|
238
|
-
* @param {string} network_str
|
|
239
|
-
* @returns {Promise<any>}
|
|
240
|
-
*/
|
|
241
|
-
export function switch_network(network_str) {
|
|
242
|
-
const ptr0 = passStringToWasm0(network_str, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
243
|
-
const len0 = WASM_VECTOR_LEN;
|
|
244
|
-
const ret = wasm.switch_network(ptr0, len0);
|
|
245
|
-
return takeObject(ret);
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
/**
|
|
249
|
-
* @param {string} key
|
|
250
|
-
* @returns {Promise<any>}
|
|
251
|
-
*/
|
|
252
|
-
export function get_env(key) {
|
|
253
|
-
const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
254
|
-
const len0 = WASM_VECTOR_LEN;
|
|
255
|
-
const ret = wasm.get_env(ptr0, len0);
|
|
256
|
-
return takeObject(ret);
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
/**
|
|
260
|
-
* @param {string} key
|
|
261
|
-
* @param {string} value
|
|
262
|
-
* @returns {Promise<any>}
|
|
263
|
-
*/
|
|
264
|
-
export function set_env(key, value) {
|
|
265
|
-
const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
266
|
-
const len0 = WASM_VECTOR_LEN;
|
|
267
|
-
const ptr1 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
268
|
-
const len1 = WASM_VECTOR_LEN;
|
|
269
|
-
const ret = wasm.set_env(ptr0, len0, ptr1, len1);
|
|
270
|
-
return takeObject(ret);
|
|
271
|
-
}
|
|
272
|
-
|
|
273
|
-
/**
|
|
274
|
-
* @param {number} ms
|
|
275
|
-
* @returns {Promise<any>}
|
|
276
|
-
*/
|
|
277
|
-
export function sleep(ms) {
|
|
278
|
-
const ret = wasm.sleep(ms);
|
|
279
|
-
return takeObject(ret);
|
|
226
|
+
wasm._dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__haa7e522923c6e229(arg0, arg1, addHeapObject(arg2));
|
|
280
227
|
}
|
|
281
228
|
|
|
282
229
|
/**
|
|
@@ -533,125 +480,6 @@ export function psbt_publish_file(request) {
|
|
|
533
480
|
return takeObject(ret);
|
|
534
481
|
}
|
|
535
482
|
|
|
536
|
-
/**
|
|
537
|
-
* @param {string} username
|
|
538
|
-
* @param {string} password
|
|
539
|
-
* @returns {Promise<any>}
|
|
540
|
-
*/
|
|
541
|
-
export function create_wallet(username, password) {
|
|
542
|
-
const ptr0 = passStringToWasm0(username, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
543
|
-
const len0 = WASM_VECTOR_LEN;
|
|
544
|
-
const ptr1 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
545
|
-
const len1 = WASM_VECTOR_LEN;
|
|
546
|
-
const ret = wasm.create_wallet(ptr0, len0, ptr1, len1);
|
|
547
|
-
return takeObject(ret);
|
|
548
|
-
}
|
|
549
|
-
|
|
550
|
-
/**
|
|
551
|
-
* @param {string} username
|
|
552
|
-
* @param {string} password
|
|
553
|
-
* @returns {Promise<any>}
|
|
554
|
-
*/
|
|
555
|
-
export function auth(username, password) {
|
|
556
|
-
const ptr0 = passStringToWasm0(username, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
557
|
-
const len0 = WASM_VECTOR_LEN;
|
|
558
|
-
const ptr1 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
559
|
-
const len1 = WASM_VECTOR_LEN;
|
|
560
|
-
const ret = wasm.auth(ptr0, len0, ptr1, len1);
|
|
561
|
-
return takeObject(ret);
|
|
562
|
-
}
|
|
563
|
-
|
|
564
|
-
/**
|
|
565
|
-
* @param {string} description
|
|
566
|
-
* @param {number} amount
|
|
567
|
-
* @param {string} token
|
|
568
|
-
* @returns {Promise<any>}
|
|
569
|
-
*/
|
|
570
|
-
export function ln_create_invoice(description, amount, token) {
|
|
571
|
-
const ptr0 = passStringToWasm0(description, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
572
|
-
const len0 = WASM_VECTOR_LEN;
|
|
573
|
-
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
574
|
-
const len1 = WASM_VECTOR_LEN;
|
|
575
|
-
const ret = wasm.ln_create_invoice(ptr0, len0, amount, ptr1, len1);
|
|
576
|
-
return takeObject(ret);
|
|
577
|
-
}
|
|
578
|
-
|
|
579
|
-
/**
|
|
580
|
-
* @param {string} token
|
|
581
|
-
* @returns {Promise<any>}
|
|
582
|
-
*/
|
|
583
|
-
export function get_balance(token) {
|
|
584
|
-
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
585
|
-
const len0 = WASM_VECTOR_LEN;
|
|
586
|
-
const ret = wasm.get_balance(ptr0, len0);
|
|
587
|
-
return takeObject(ret);
|
|
588
|
-
}
|
|
589
|
-
|
|
590
|
-
/**
|
|
591
|
-
* @param {string} token
|
|
592
|
-
* @returns {Promise<any>}
|
|
593
|
-
*/
|
|
594
|
-
export function get_txs(token) {
|
|
595
|
-
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
596
|
-
const len0 = WASM_VECTOR_LEN;
|
|
597
|
-
const ret = wasm.get_txs(ptr0, len0);
|
|
598
|
-
return takeObject(ret);
|
|
599
|
-
}
|
|
600
|
-
|
|
601
|
-
/**
|
|
602
|
-
* @param {string} payment_request
|
|
603
|
-
* @param {string} token
|
|
604
|
-
* @returns {Promise<any>}
|
|
605
|
-
*/
|
|
606
|
-
export function pay_invoice(payment_request, token) {
|
|
607
|
-
const ptr0 = passStringToWasm0(payment_request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
608
|
-
const len0 = WASM_VECTOR_LEN;
|
|
609
|
-
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
610
|
-
const len1 = WASM_VECTOR_LEN;
|
|
611
|
-
const ret = wasm.pay_invoice(ptr0, len0, ptr1, len1);
|
|
612
|
-
return takeObject(ret);
|
|
613
|
-
}
|
|
614
|
-
|
|
615
|
-
/**
|
|
616
|
-
* @param {string} payment_hash
|
|
617
|
-
* @returns {Promise<any>}
|
|
618
|
-
*/
|
|
619
|
-
export function check_payment(payment_hash) {
|
|
620
|
-
const ptr0 = passStringToWasm0(payment_hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
621
|
-
const len0 = WASM_VECTOR_LEN;
|
|
622
|
-
const ret = wasm.check_payment(ptr0, len0);
|
|
623
|
-
return takeObject(ret);
|
|
624
|
-
}
|
|
625
|
-
|
|
626
|
-
/**
|
|
627
|
-
* @param {string} token
|
|
628
|
-
* @param {string | undefined} [ln_address]
|
|
629
|
-
* @returns {Promise<any>}
|
|
630
|
-
*/
|
|
631
|
-
export function swap_btc_ln(token, ln_address) {
|
|
632
|
-
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
633
|
-
const len0 = WASM_VECTOR_LEN;
|
|
634
|
-
var ptr1 = isLikeNone(ln_address) ? 0 : passStringToWasm0(ln_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
635
|
-
var len1 = WASM_VECTOR_LEN;
|
|
636
|
-
const ret = wasm.swap_btc_ln(ptr0, len0, ptr1, len1);
|
|
637
|
-
return takeObject(ret);
|
|
638
|
-
}
|
|
639
|
-
|
|
640
|
-
/**
|
|
641
|
-
* @param {string} address
|
|
642
|
-
* @param {bigint} amount
|
|
643
|
-
* @param {string} token
|
|
644
|
-
* @returns {Promise<any>}
|
|
645
|
-
*/
|
|
646
|
-
export function swap_ln_btc(address, amount, token) {
|
|
647
|
-
const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
648
|
-
const len0 = WASM_VECTOR_LEN;
|
|
649
|
-
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
650
|
-
const len1 = WASM_VECTOR_LEN;
|
|
651
|
-
const ret = wasm.swap_ln_btc(ptr0, len0, amount, ptr1, len1);
|
|
652
|
-
return takeObject(ret);
|
|
653
|
-
}
|
|
654
|
-
|
|
655
483
|
function passArray8ToWasm0(arg, malloc) {
|
|
656
484
|
const ptr = malloc(arg.length * 1, 1) >>> 0;
|
|
657
485
|
getUint8Memory0().set(arg, ptr / 1);
|
|
@@ -807,6 +635,125 @@ export function decode_base64(string) {
|
|
|
807
635
|
}
|
|
808
636
|
}
|
|
809
637
|
|
|
638
|
+
/**
|
|
639
|
+
* @param {string} username
|
|
640
|
+
* @param {string} password
|
|
641
|
+
* @returns {Promise<any>}
|
|
642
|
+
*/
|
|
643
|
+
export function create_wallet(username, password) {
|
|
644
|
+
const ptr0 = passStringToWasm0(username, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
645
|
+
const len0 = WASM_VECTOR_LEN;
|
|
646
|
+
const ptr1 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
647
|
+
const len1 = WASM_VECTOR_LEN;
|
|
648
|
+
const ret = wasm.create_wallet(ptr0, len0, ptr1, len1);
|
|
649
|
+
return takeObject(ret);
|
|
650
|
+
}
|
|
651
|
+
|
|
652
|
+
/**
|
|
653
|
+
* @param {string} username
|
|
654
|
+
* @param {string} password
|
|
655
|
+
* @returns {Promise<any>}
|
|
656
|
+
*/
|
|
657
|
+
export function auth(username, password) {
|
|
658
|
+
const ptr0 = passStringToWasm0(username, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
659
|
+
const len0 = WASM_VECTOR_LEN;
|
|
660
|
+
const ptr1 = passStringToWasm0(password, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
661
|
+
const len1 = WASM_VECTOR_LEN;
|
|
662
|
+
const ret = wasm.auth(ptr0, len0, ptr1, len1);
|
|
663
|
+
return takeObject(ret);
|
|
664
|
+
}
|
|
665
|
+
|
|
666
|
+
/**
|
|
667
|
+
* @param {string} description
|
|
668
|
+
* @param {number} amount
|
|
669
|
+
* @param {string} token
|
|
670
|
+
* @returns {Promise<any>}
|
|
671
|
+
*/
|
|
672
|
+
export function ln_create_invoice(description, amount, token) {
|
|
673
|
+
const ptr0 = passStringToWasm0(description, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
674
|
+
const len0 = WASM_VECTOR_LEN;
|
|
675
|
+
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
676
|
+
const len1 = WASM_VECTOR_LEN;
|
|
677
|
+
const ret = wasm.ln_create_invoice(ptr0, len0, amount, ptr1, len1);
|
|
678
|
+
return takeObject(ret);
|
|
679
|
+
}
|
|
680
|
+
|
|
681
|
+
/**
|
|
682
|
+
* @param {string} token
|
|
683
|
+
* @returns {Promise<any>}
|
|
684
|
+
*/
|
|
685
|
+
export function get_balance(token) {
|
|
686
|
+
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
687
|
+
const len0 = WASM_VECTOR_LEN;
|
|
688
|
+
const ret = wasm.get_balance(ptr0, len0);
|
|
689
|
+
return takeObject(ret);
|
|
690
|
+
}
|
|
691
|
+
|
|
692
|
+
/**
|
|
693
|
+
* @param {string} token
|
|
694
|
+
* @returns {Promise<any>}
|
|
695
|
+
*/
|
|
696
|
+
export function get_txs(token) {
|
|
697
|
+
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
698
|
+
const len0 = WASM_VECTOR_LEN;
|
|
699
|
+
const ret = wasm.get_txs(ptr0, len0);
|
|
700
|
+
return takeObject(ret);
|
|
701
|
+
}
|
|
702
|
+
|
|
703
|
+
/**
|
|
704
|
+
* @param {string} payment_request
|
|
705
|
+
* @param {string} token
|
|
706
|
+
* @returns {Promise<any>}
|
|
707
|
+
*/
|
|
708
|
+
export function pay_invoice(payment_request, token) {
|
|
709
|
+
const ptr0 = passStringToWasm0(payment_request, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
710
|
+
const len0 = WASM_VECTOR_LEN;
|
|
711
|
+
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
712
|
+
const len1 = WASM_VECTOR_LEN;
|
|
713
|
+
const ret = wasm.pay_invoice(ptr0, len0, ptr1, len1);
|
|
714
|
+
return takeObject(ret);
|
|
715
|
+
}
|
|
716
|
+
|
|
717
|
+
/**
|
|
718
|
+
* @param {string} payment_hash
|
|
719
|
+
* @returns {Promise<any>}
|
|
720
|
+
*/
|
|
721
|
+
export function check_payment(payment_hash) {
|
|
722
|
+
const ptr0 = passStringToWasm0(payment_hash, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
723
|
+
const len0 = WASM_VECTOR_LEN;
|
|
724
|
+
const ret = wasm.check_payment(ptr0, len0);
|
|
725
|
+
return takeObject(ret);
|
|
726
|
+
}
|
|
727
|
+
|
|
728
|
+
/**
|
|
729
|
+
* @param {string} token
|
|
730
|
+
* @param {string | undefined} [ln_address]
|
|
731
|
+
* @returns {Promise<any>}
|
|
732
|
+
*/
|
|
733
|
+
export function swap_btc_ln(token, ln_address) {
|
|
734
|
+
const ptr0 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
735
|
+
const len0 = WASM_VECTOR_LEN;
|
|
736
|
+
var ptr1 = isLikeNone(ln_address) ? 0 : passStringToWasm0(ln_address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
737
|
+
var len1 = WASM_VECTOR_LEN;
|
|
738
|
+
const ret = wasm.swap_btc_ln(ptr0, len0, ptr1, len1);
|
|
739
|
+
return takeObject(ret);
|
|
740
|
+
}
|
|
741
|
+
|
|
742
|
+
/**
|
|
743
|
+
* @param {string} address
|
|
744
|
+
* @param {bigint} amount
|
|
745
|
+
* @param {string} token
|
|
746
|
+
* @returns {Promise<any>}
|
|
747
|
+
*/
|
|
748
|
+
export function swap_ln_btc(address, amount, token) {
|
|
749
|
+
const ptr0 = passStringToWasm0(address, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
750
|
+
const len0 = WASM_VECTOR_LEN;
|
|
751
|
+
const ptr1 = passStringToWasm0(token, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
752
|
+
const len1 = WASM_VECTOR_LEN;
|
|
753
|
+
const ret = wasm.swap_ln_btc(ptr0, len0, amount, ptr1, len1);
|
|
754
|
+
return takeObject(ret);
|
|
755
|
+
}
|
|
756
|
+
|
|
810
757
|
/**
|
|
811
758
|
* @param {string} pubkey
|
|
812
759
|
* @param {string} token
|
|
@@ -924,6 +871,59 @@ export function version() {
|
|
|
924
871
|
return takeObject(ret);
|
|
925
872
|
}
|
|
926
873
|
|
|
874
|
+
/**
|
|
875
|
+
* @returns {Promise<any>}
|
|
876
|
+
*/
|
|
877
|
+
export function get_network() {
|
|
878
|
+
const ret = wasm.get_network();
|
|
879
|
+
return takeObject(ret);
|
|
880
|
+
}
|
|
881
|
+
|
|
882
|
+
/**
|
|
883
|
+
* @param {string} network_str
|
|
884
|
+
* @returns {Promise<any>}
|
|
885
|
+
*/
|
|
886
|
+
export function switch_network(network_str) {
|
|
887
|
+
const ptr0 = passStringToWasm0(network_str, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
888
|
+
const len0 = WASM_VECTOR_LEN;
|
|
889
|
+
const ret = wasm.switch_network(ptr0, len0);
|
|
890
|
+
return takeObject(ret);
|
|
891
|
+
}
|
|
892
|
+
|
|
893
|
+
/**
|
|
894
|
+
* @param {string} key
|
|
895
|
+
* @returns {Promise<any>}
|
|
896
|
+
*/
|
|
897
|
+
export function get_env(key) {
|
|
898
|
+
const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
899
|
+
const len0 = WASM_VECTOR_LEN;
|
|
900
|
+
const ret = wasm.get_env(ptr0, len0);
|
|
901
|
+
return takeObject(ret);
|
|
902
|
+
}
|
|
903
|
+
|
|
904
|
+
/**
|
|
905
|
+
* @param {string} key
|
|
906
|
+
* @param {string} value
|
|
907
|
+
* @returns {Promise<any>}
|
|
908
|
+
*/
|
|
909
|
+
export function set_env(key, value) {
|
|
910
|
+
const ptr0 = passStringToWasm0(key, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
911
|
+
const len0 = WASM_VECTOR_LEN;
|
|
912
|
+
const ptr1 = passStringToWasm0(value, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
913
|
+
const len1 = WASM_VECTOR_LEN;
|
|
914
|
+
const ret = wasm.set_env(ptr0, len0, ptr1, len1);
|
|
915
|
+
return takeObject(ret);
|
|
916
|
+
}
|
|
917
|
+
|
|
918
|
+
/**
|
|
919
|
+
* @param {number} ms
|
|
920
|
+
* @returns {Promise<any>}
|
|
921
|
+
*/
|
|
922
|
+
export function sleep(ms) {
|
|
923
|
+
const ret = wasm.sleep(ms);
|
|
924
|
+
return takeObject(ret);
|
|
925
|
+
}
|
|
926
|
+
|
|
927
927
|
/**
|
|
928
928
|
* @param {string} nostr_hex_sk
|
|
929
929
|
* @param {boolean} hidden
|
|
@@ -1482,7 +1482,7 @@ function handleError(f, args) {
|
|
|
1482
1482
|
}
|
|
1483
1483
|
}
|
|
1484
1484
|
function __wbg_adapter_288(arg0, arg1, arg2, arg3) {
|
|
1485
|
-
wasm.
|
|
1485
|
+
wasm.wasm_bindgen__convert__closures__invoke2_mut__ha34478490d8c61d2(arg0, arg1, addHeapObject(arg2), addHeapObject(arg3));
|
|
1486
1486
|
}
|
|
1487
1487
|
|
|
1488
1488
|
async function __wbg_load(module, imports) {
|
|
@@ -1526,6 +1526,10 @@ function __wbg_get_imports() {
|
|
|
1526
1526
|
const ret = getStringFromWasm0(arg0, arg1);
|
|
1527
1527
|
return addHeapObject(ret);
|
|
1528
1528
|
};
|
|
1529
|
+
imports.wbg.__wbindgen_object_clone_ref = function(arg0) {
|
|
1530
|
+
const ret = getObject(arg0);
|
|
1531
|
+
return addHeapObject(ret);
|
|
1532
|
+
};
|
|
1529
1533
|
imports.wbg.__wbindgen_number_new = function(arg0) {
|
|
1530
1534
|
const ret = arg0;
|
|
1531
1535
|
return addHeapObject(ret);
|
|
@@ -1538,14 +1542,19 @@ function __wbg_get_imports() {
|
|
|
1538
1542
|
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
1539
1543
|
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
1540
1544
|
};
|
|
1541
|
-
imports.wbg.__wbindgen_object_clone_ref = function(arg0) {
|
|
1542
|
-
const ret = getObject(arg0);
|
|
1543
|
-
return addHeapObject(ret);
|
|
1544
|
-
};
|
|
1545
1545
|
imports.wbg.__wbindgen_is_undefined = function(arg0) {
|
|
1546
1546
|
const ret = getObject(arg0) === undefined;
|
|
1547
1547
|
return ret;
|
|
1548
1548
|
};
|
|
1549
|
+
imports.wbg.__wbindgen_error_new = function(arg0, arg1) {
|
|
1550
|
+
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
1551
|
+
return addHeapObject(ret);
|
|
1552
|
+
};
|
|
1553
|
+
imports.wbg.__wbindgen_boolean_get = function(arg0) {
|
|
1554
|
+
const v = getObject(arg0);
|
|
1555
|
+
const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
|
|
1556
|
+
return ret;
|
|
1557
|
+
};
|
|
1549
1558
|
imports.wbg.__wbindgen_is_string = function(arg0) {
|
|
1550
1559
|
const ret = typeof(getObject(arg0)) === 'string';
|
|
1551
1560
|
return ret;
|
|
@@ -1562,10 +1571,6 @@ function __wbg_get_imports() {
|
|
|
1562
1571
|
const ret = getObject(arg0) === getObject(arg1);
|
|
1563
1572
|
return ret;
|
|
1564
1573
|
};
|
|
1565
|
-
imports.wbg.__wbindgen_error_new = function(arg0, arg1) {
|
|
1566
|
-
const ret = new Error(getStringFromWasm0(arg0, arg1));
|
|
1567
|
-
return addHeapObject(ret);
|
|
1568
|
-
};
|
|
1569
1574
|
imports.wbg.__wbindgen_is_object = function(arg0) {
|
|
1570
1575
|
const val = getObject(arg0);
|
|
1571
1576
|
const ret = typeof(val) === 'object' && val !== null;
|
|
@@ -1581,11 +1586,6 @@ function __wbg_get_imports() {
|
|
|
1581
1586
|
getFloat64Memory0()[arg0 / 8 + 1] = isLikeNone(ret) ? 0 : ret;
|
|
1582
1587
|
getInt32Memory0()[arg0 / 4 + 0] = !isLikeNone(ret);
|
|
1583
1588
|
};
|
|
1584
|
-
imports.wbg.__wbindgen_boolean_get = function(arg0) {
|
|
1585
|
-
const v = getObject(arg0);
|
|
1586
|
-
const ret = typeof(v) === 'boolean' ? (v ? 1 : 0) : 2;
|
|
1587
|
-
return ret;
|
|
1588
|
-
};
|
|
1589
1589
|
imports.wbg.__wbindgen_bigint_from_u64 = function(arg0) {
|
|
1590
1590
|
const ret = BigInt.asUintN(64, arg0);
|
|
1591
1591
|
return addHeapObject(ret);
|
|
@@ -1629,10 +1629,6 @@ function __wbg_get_imports() {
|
|
|
1629
1629
|
const ret = +getObject(arg0);
|
|
1630
1630
|
return ret;
|
|
1631
1631
|
};
|
|
1632
|
-
imports.wbg.__wbg_getwithrefkey_4a92a5eca60879b9 = function(arg0, arg1) {
|
|
1633
|
-
const ret = getObject(arg0)[getObject(arg1)];
|
|
1634
|
-
return addHeapObject(ret);
|
|
1635
|
-
};
|
|
1636
1632
|
imports.wbg.__wbg_String_389b54bd9d25375f = function(arg0, arg1) {
|
|
1637
1633
|
const ret = String(getObject(arg1));
|
|
1638
1634
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
@@ -1640,6 +1636,10 @@ function __wbg_get_imports() {
|
|
|
1640
1636
|
getInt32Memory0()[arg0 / 4 + 1] = len1;
|
|
1641
1637
|
getInt32Memory0()[arg0 / 4 + 0] = ptr1;
|
|
1642
1638
|
};
|
|
1639
|
+
imports.wbg.__wbg_getwithrefkey_4a92a5eca60879b9 = function(arg0, arg1) {
|
|
1640
|
+
const ret = getObject(arg0)[getObject(arg1)];
|
|
1641
|
+
return addHeapObject(ret);
|
|
1642
|
+
};
|
|
1643
1643
|
imports.wbg.__wbg_debug_f586ed09a35f6497 = function(arg0, arg1) {
|
|
1644
1644
|
var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
|
|
1645
1645
|
wasm.__wbindgen_free(arg0, arg1 * 4, 4);
|
|
@@ -1673,9 +1673,6 @@ function __wbg_get_imports() {
|
|
|
1673
1673
|
const ret = fetch(getObject(arg0));
|
|
1674
1674
|
return addHeapObject(ret);
|
|
1675
1675
|
};
|
|
1676
|
-
imports.wbg.__wbg_queueMicrotask_118eeb525d584d9a = function(arg0) {
|
|
1677
|
-
queueMicrotask(getObject(arg0));
|
|
1678
|
-
};
|
|
1679
1676
|
imports.wbg.__wbg_queueMicrotask_26a89c14c53809c0 = function(arg0) {
|
|
1680
1677
|
const ret = getObject(arg0).queueMicrotask;
|
|
1681
1678
|
return addHeapObject(ret);
|
|
@@ -1684,6 +1681,9 @@ function __wbg_get_imports() {
|
|
|
1684
1681
|
const ret = typeof(getObject(arg0)) === 'function';
|
|
1685
1682
|
return ret;
|
|
1686
1683
|
};
|
|
1684
|
+
imports.wbg.__wbg_queueMicrotask_118eeb525d584d9a = function(arg0) {
|
|
1685
|
+
queueMicrotask(getObject(arg0));
|
|
1686
|
+
};
|
|
1687
1687
|
imports.wbg.__wbg_instanceof_Window_99dc9805eaa2614b = function(arg0) {
|
|
1688
1688
|
let result;
|
|
1689
1689
|
try {
|
|
@@ -1716,6 +1716,10 @@ function __wbg_get_imports() {
|
|
|
1716
1716
|
const ret = getObject(arg0).fetch(getObject(arg1));
|
|
1717
1717
|
return addHeapObject(ret);
|
|
1718
1718
|
};
|
|
1719
|
+
imports.wbg.__wbg_new_26bb7e688dfc365c = function() { return handleError(function () {
|
|
1720
|
+
const ret = new URLSearchParams();
|
|
1721
|
+
return addHeapObject(ret);
|
|
1722
|
+
}, arguments) };
|
|
1719
1723
|
imports.wbg.__wbg_new_3ff7ff424b10235d = function() { return handleError(function () {
|
|
1720
1724
|
const ret = new FormData();
|
|
1721
1725
|
return addHeapObject(ret);
|
|
@@ -1726,10 +1730,6 @@ function __wbg_get_imports() {
|
|
|
1726
1730
|
imports.wbg.__wbg_append_7de46912be63ad86 = function() { return handleError(function (arg0, arg1, arg2, arg3, arg4, arg5) {
|
|
1727
1731
|
getObject(arg0).append(getStringFromWasm0(arg1, arg2), getObject(arg3), getStringFromWasm0(arg4, arg5));
|
|
1728
1732
|
}, arguments) };
|
|
1729
|
-
imports.wbg.__wbg_new_26bb7e688dfc365c = function() { return handleError(function () {
|
|
1730
|
-
const ret = new URLSearchParams();
|
|
1731
|
-
return addHeapObject(ret);
|
|
1732
|
-
}, arguments) };
|
|
1733
1733
|
imports.wbg.__wbg_url_70f3179afe0eccd6 = function(arg0, arg1) {
|
|
1734
1734
|
const ret = getObject(arg1).url;
|
|
1735
1735
|
const ptr1 = passStringToWasm0(ret, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
|
|
@@ -1745,17 +1745,10 @@ function __wbg_get_imports() {
|
|
|
1745
1745
|
const ret = new Request(getStringFromWasm0(arg0, arg1), getObject(arg2));
|
|
1746
1746
|
return addHeapObject(ret);
|
|
1747
1747
|
}, arguments) };
|
|
1748
|
-
imports.wbg.
|
|
1749
|
-
const ret = getObject(arg0)
|
|
1750
|
-
return addHeapObject(ret);
|
|
1751
|
-
};
|
|
1752
|
-
imports.wbg.__wbg_new_fa36281638875de8 = function() { return handleError(function () {
|
|
1753
|
-
const ret = new AbortController();
|
|
1748
|
+
imports.wbg.__wbg_newwithu8arraysequenceandoptions_d0ee7f095b8bf8eb = function() { return handleError(function (arg0, arg1) {
|
|
1749
|
+
const ret = new Blob(getObject(arg0), getObject(arg1));
|
|
1754
1750
|
return addHeapObject(ret);
|
|
1755
1751
|
}, arguments) };
|
|
1756
|
-
imports.wbg.__wbg_abort_7792bf3f664d7bb3 = function(arg0) {
|
|
1757
|
-
getObject(arg0).abort();
|
|
1758
|
-
};
|
|
1759
1752
|
imports.wbg.__wbg_instanceof_Response_0d25bb8436a9cefe = function(arg0) {
|
|
1760
1753
|
let result;
|
|
1761
1754
|
try {
|
|
@@ -1789,10 +1782,17 @@ function __wbg_get_imports() {
|
|
|
1789
1782
|
const ret = getObject(arg0).text();
|
|
1790
1783
|
return addHeapObject(ret);
|
|
1791
1784
|
}, arguments) };
|
|
1792
|
-
imports.wbg.
|
|
1793
|
-
const ret =
|
|
1785
|
+
imports.wbg.__wbg_signal_7876560d9d0f914c = function(arg0) {
|
|
1786
|
+
const ret = getObject(arg0).signal;
|
|
1787
|
+
return addHeapObject(ret);
|
|
1788
|
+
};
|
|
1789
|
+
imports.wbg.__wbg_new_fa36281638875de8 = function() { return handleError(function () {
|
|
1790
|
+
const ret = new AbortController();
|
|
1794
1791
|
return addHeapObject(ret);
|
|
1795
1792
|
}, arguments) };
|
|
1793
|
+
imports.wbg.__wbg_abort_7792bf3f664d7bb3 = function(arg0) {
|
|
1794
|
+
getObject(arg0).abort();
|
|
1795
|
+
};
|
|
1796
1796
|
imports.wbg.__wbg_new_a979e9eedc5e81a3 = function() { return handleError(function () {
|
|
1797
1797
|
const ret = new Headers();
|
|
1798
1798
|
return addHeapObject(ret);
|
|
@@ -2086,8 +2086,8 @@ function __wbg_get_imports() {
|
|
|
2086
2086
|
const ret = wasm.memory;
|
|
2087
2087
|
return addHeapObject(ret);
|
|
2088
2088
|
};
|
|
2089
|
-
imports.wbg.
|
|
2090
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
2089
|
+
imports.wbg.__wbindgen_closure_wrapper16996 = function(arg0, arg1, arg2) {
|
|
2090
|
+
const ret = makeMutClosure(arg0, arg1, 3801, __wbg_adapter_50);
|
|
2091
2091
|
return addHeapObject(ret);
|
|
2092
2092
|
};
|
|
2093
2093
|
|
package/bitmask_core_bg.wasm
CHANGED
|
Binary file
|
|
@@ -1,11 +1,6 @@
|
|
|
1
1
|
/* tslint:disable */
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
export const memory: WebAssembly.Memory;
|
|
4
|
-
export function get_network(): number;
|
|
5
|
-
export function switch_network(a: number, b: number): number;
|
|
6
|
-
export function get_env(a: number, b: number): number;
|
|
7
|
-
export function set_env(a: number, b: number, c: number, d: number): number;
|
|
8
|
-
export function sleep(a: number): number;
|
|
9
4
|
export function hash_password(a: number, b: number, c: number): void;
|
|
10
5
|
export function new_mnemonic(a: number, b: number): number;
|
|
11
6
|
export function save_mnemonic(a: number, b: number, c: number, d: number): number;
|
|
@@ -23,6 +18,13 @@ export function drain_wallet(a: number, b: number, c: number, d: number, e: numb
|
|
|
23
18
|
export function bump_fee(a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number): number;
|
|
24
19
|
export function psbt_sign_and_publish_file(a: number): number;
|
|
25
20
|
export function psbt_publish_file(a: number): number;
|
|
21
|
+
export function store(a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number): number;
|
|
22
|
+
export function retrieve(a: number, b: number, c: number, d: number): number;
|
|
23
|
+
export function retrieve_metadata(a: number, b: number, c: number, d: number): number;
|
|
24
|
+
export function encode_hex(a: number, b: number, c: number): void;
|
|
25
|
+
export function encode_base64(a: number, b: number, c: number): void;
|
|
26
|
+
export function decode_hex(a: number, b: number, c: number): void;
|
|
27
|
+
export function decode_base64(a: number, b: number, c: number): void;
|
|
26
28
|
export function create_wallet(a: number, b: number, c: number, d: number): number;
|
|
27
29
|
export function auth(a: number, b: number, c: number, d: number): number;
|
|
28
30
|
export function ln_create_invoice(a: number, b: number, c: number, d: number, e: number): number;
|
|
@@ -32,13 +34,6 @@ export function pay_invoice(a: number, b: number, c: number, d: number): number;
|
|
|
32
34
|
export function check_payment(a: number, b: number): number;
|
|
33
35
|
export function swap_btc_ln(a: number, b: number, c: number, d: number): number;
|
|
34
36
|
export function swap_ln_btc(a: number, b: number, c: number, d: number, e: number): number;
|
|
35
|
-
export function store(a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number): number;
|
|
36
|
-
export function retrieve(a: number, b: number, c: number, d: number): number;
|
|
37
|
-
export function retrieve_metadata(a: number, b: number, c: number, d: number): number;
|
|
38
|
-
export function encode_hex(a: number, b: number, c: number): void;
|
|
39
|
-
export function encode_base64(a: number, b: number, c: number): void;
|
|
40
|
-
export function decode_hex(a: number, b: number, c: number): void;
|
|
41
|
-
export function decode_base64(a: number, b: number, c: number): void;
|
|
42
37
|
export function new_nostr_pubkey(a: number, b: number, c: number, d: number): number;
|
|
43
38
|
export function update_nostr_pubkey(a: number, b: number, c: number, d: number): number;
|
|
44
39
|
export function convert_contract_amount_raw(a: number, b: number, c: number, d: number): void;
|
|
@@ -46,6 +41,11 @@ export function convert_contract_amount_string(a: number, b: number, c: number):
|
|
|
46
41
|
export function parse_contract_amount(a: number, b: number): number;
|
|
47
42
|
export function parse_contract_amount_precision(a: number, b: number, c: number, d: number): void;
|
|
48
43
|
export function version(): number;
|
|
44
|
+
export function get_network(): number;
|
|
45
|
+
export function switch_network(a: number, b: number): number;
|
|
46
|
+
export function get_env(a: number, b: number): number;
|
|
47
|
+
export function set_env(a: number, b: number, c: number, d: number): number;
|
|
48
|
+
export function sleep(a: number): number;
|
|
49
49
|
export function list_contracts(a: number, b: number, c: number): number;
|
|
50
50
|
export function get_contract(a: number, b: number, c: number, d: number): number;
|
|
51
51
|
export function import_contract(a: number, b: number, c: number, d: number): number;
|
|
@@ -109,8 +109,8 @@ export function rustsecp256k1_v0_6_1_default_error_callback_fn(a: number, b: num
|
|
|
109
109
|
export function __wbindgen_malloc(a: number, b: number): number;
|
|
110
110
|
export function __wbindgen_realloc(a: number, b: number, c: number, d: number): number;
|
|
111
111
|
export const __wbindgen_export_2: WebAssembly.Table;
|
|
112
|
-
export function
|
|
112
|
+
export function _dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__haa7e522923c6e229(a: number, b: number, c: number): void;
|
|
113
113
|
export function __wbindgen_add_to_stack_pointer(a: number): number;
|
|
114
114
|
export function __wbindgen_free(a: number, b: number, c: number): void;
|
|
115
115
|
export function __wbindgen_exn_store(a: number): void;
|
|
116
|
-
export function
|
|
116
|
+
export function wasm_bindgen__convert__closures__invoke2_mut__ha34478490d8c61d2(a: number, b: number, c: number, d: number): void;
|