-
Notifications
You must be signed in to change notification settings - Fork 71
/
index.ts
551 lines (530 loc) · 26.1 KB
/
index.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
'use strict'
// --------------------------------- IMPORTS ----------------------------------
// See the full model specification: https://woodser.github.io/monero-java/monero-spec.pdf
// import common models
import GenUtils from "./src/main/ts/common/GenUtils";
import Filter from "./src/main/ts/common/Filter";
import MoneroError from "./src/main/ts/common/MoneroError";
import HttpClient from "./src/main/ts/common/HttpClient";
import LibraryUtils from "./src/main/ts/common/LibraryUtils";
import MoneroRpcConnection from "./src/main/ts/common/MoneroRpcConnection";
import MoneroRpcError from "./src/main/ts/common/MoneroRpcError";
import SslOptions from "./src/main/ts/common/SslOptions";
import TaskLooper from "./src/main/ts/common/TaskLooper";
// import daemon models
import ConnectionType from "./src/main/ts/daemon/model/ConnectionType";
import MoneroAltChain from "./src/main/ts/daemon/model/MoneroAltChain";
import MoneroBan from "./src/main/ts/daemon/model/MoneroBan";
import MoneroBlockHeader from "./src/main/ts/daemon/model/MoneroBlockHeader";
import MoneroBlock from "./src/main/ts/daemon/model/MoneroBlock";
import MoneroBlockTemplate from "./src/main/ts/daemon/model/MoneroBlockTemplate";
import MoneroConnectionSpan from "./src/main/ts/daemon/model/MoneroConnectionSpan";
import MoneroDaemonConfig from "./src/main/ts/daemon/model/MoneroDaemonConfig";
import MoneroDaemonInfo from "./src/main/ts/daemon/model/MoneroDaemonInfo";
import MoneroDaemonListener from "./src/main/ts/daemon/model/MoneroDaemonListener";
import MoneroDaemonSyncInfo from "./src/main/ts/daemon/model/MoneroDaemonSyncInfo";
import MoneroDaemonUpdateCheckResult from "./src/main/ts/daemon/model/MoneroDaemonUpdateCheckResult";
import MoneroDaemonUpdateDownloadResult from "./src/main/ts/daemon/model/MoneroDaemonUpdateDownloadResult";
import MoneroFeeEstimate from "./src/main/ts/daemon/model/MoneroFeeEstimate";
import MoneroHardForkInfo from "./src/main/ts/daemon/model/MoneroHardForkInfo";
import MoneroKeyImage from "./src/main/ts/daemon/model/MoneroKeyImage";
import MoneroKeyImageSpentStatus from "./src/main/ts/daemon/model/MoneroKeyImageSpentStatus";
import MoneroMinerTxSum from "./src/main/ts/daemon/model/MoneroMinerTxSum";
import MoneroMiningStatus from "./src/main/ts/daemon/model/MoneroMiningStatus";
import MoneroNetworkType from "./src/main/ts/daemon/model/MoneroNetworkType";
import MoneroOutput from "./src/main/ts/daemon/model/MoneroOutput";
import MoneroOutputHistogramEntry from "./src/main/ts/daemon/model/MoneroOutputHistogramEntry";
import MoneroSubmitTxResult from "./src/main/ts/daemon/model/MoneroSubmitTxResult";
import MoneroTx from "./src/main/ts/daemon/model/MoneroTx";
import MoneroTxPoolStats from "./src/main/ts/daemon/model/MoneroTxPoolStats";
import MoneroVersion from "./src/main/ts/daemon/model/MoneroVersion";
import MoneroPeer from "./src/main/ts/daemon/model/MoneroPeer";
import MoneroPruneResult from "./src/main/ts/daemon/model/MoneroPruneResult";
// import wallet models
import MoneroAccount from "./src/main/ts/wallet/model/MoneroAccount";
import MoneroAccountTag from "./src/main/ts/wallet/model/MoneroAccountTag";
import MoneroAddressBookEntry from "./src/main/ts/wallet/model/MoneroAddressBookEntry";
import MoneroCheck from "./src/main/ts/wallet/model/MoneroCheck";
import MoneroCheckReserve from "./src/main/ts/wallet/model/MoneroCheckReserve";
import MoneroCheckTx from "./src/main/ts/wallet/model/MoneroCheckTx";
import MoneroDestination from "./src/main/ts/wallet/model/MoneroDestination";
import MoneroIntegratedAddress from "./src/main/ts/wallet/model/MoneroIntegratedAddress";
import MoneroKeyImageImportResult from "./src/main/ts/wallet/model/MoneroKeyImageImportResult";
import MoneroMultisigInfo from "./src/main/ts/wallet/model/MoneroMultisigInfo";
import MoneroMultisigInitResult from "./src/main/ts/wallet/model/MoneroMultisigInitResult";
import MoneroMultisigSignResult from "./src/main/ts/wallet/model/MoneroMultisigSignResult";
import MoneroOutputWallet from "./src/main/ts/wallet/model/MoneroOutputWallet";
import MoneroOutputQuery from "./src/main/ts/wallet/model/MoneroOutputQuery";
import MoneroTxPriority from "./src/main/ts/wallet/model/MoneroTxPriority";
import MoneroTxConfig from "./src/main/ts/wallet/model/MoneroTxConfig";
import MoneroSubaddress from "./src/main/ts/wallet/model/MoneroSubaddress";
import MoneroSyncResult from "./src/main/ts/wallet/model/MoneroSyncResult";
import MoneroTransfer from "./src/main/ts/wallet/model/MoneroTransfer";
import MoneroIncomingTransfer from "./src/main/ts/wallet/model/MoneroIncomingTransfer";
import MoneroOutgoingTransfer from "./src/main/ts/wallet/model/MoneroOutgoingTransfer";
import MoneroTransferQuery from "./src/main/ts/wallet/model/MoneroTransferQuery";
import MoneroTxSet from "./src/main/ts/wallet/model/MoneroTxSet";
import MoneroTxWallet from "./src/main/ts/wallet/model/MoneroTxWallet";
import MoneroTxQuery from "./src/main/ts/wallet/model/MoneroTxQuery";
import MoneroWalletListener from "./src/main/ts/wallet/model/MoneroWalletListener";
import MoneroWalletConfig from "./src/main/ts/wallet/model/MoneroWalletConfig";
import MoneroMessageSignatureType from "./src/main/ts/wallet/model/MoneroMessageSignatureType";
import MoneroMessageSignatureResult from "./src/main/ts/wallet/model/MoneroMessageSignatureResult";
// import connection manager
import MoneroConnectionManager from "./src/main/ts/common/MoneroConnectionManager";
import MoneroConnectionManagerListener from "./src/main/ts/common/MoneroConnectionManagerListener";
// import daemon, wallet, and util classes
import MoneroDaemon from "./src/main/ts/daemon/MoneroDaemon";
import MoneroWallet from "./src/main/ts/wallet/MoneroWallet";
import MoneroDaemonRpc from "./src/main/ts/daemon/MoneroDaemonRpc";
import MoneroWalletRpc from "./src/main/ts/wallet/MoneroWalletRpc";
import { MoneroWalletKeys } from "./src/main/ts/wallet/MoneroWalletKeys";
import MoneroWalletFull from "./src/main/ts/wallet/MoneroWalletFull";
import MoneroUtils from "./src/main/ts/common/MoneroUtils";
import ThreadPool from "./src/main/ts/common/ThreadPool";
// ---------------------------- GLOBAL FUNCTIONS ------------------------------
/**
* <p>Get the version of the monero-ts library.<p>
*
* @return {string} the version of this monero-ts library
*/
function getVersion() {
return MoneroUtils.getVersion();
}
/**
* <p>Create a client connected to monerod.<p>
*
* <p>Examples:<p>
*
* <code>
* let daemon = await moneroTs.connectToDaemonRpc("http://localhost:38081");<br>
* </code><br>
* <br>
* <code>
* let daemon = await moneroTs.connectToDaemonRpc({<br>
* uri: "http://localhost:38081",<br>
* username: "superuser",<br>
* password: "abctesting123"<br>
* });
* </code><br>
* <br>
* <code>
* // start monerod as an internal process<br>
* let daemon = await moneroTs.connectToDaemonRpc({<br>
* cmd: ["path/to/monerod", ...params...],<br>
* });
* </code>
*
* @param {string|Partial<MoneroRpcConnection>|Partial<MoneroDaemonConfig>|string[]} uriOrConfig - uri or rpc connection or config or terminal parameters to connect to monerod
* @param {string} [username] - username to authenticate with monerod
* @param {string} [password] - password to authenticate with monerod
* @return {Promise<MoneroDaemonRpc>} the daemon RPC client
*/
function connectToDaemonRpc(uriOrConfig: string | Partial<MoneroRpcConnection> | Partial<MoneroDaemonConfig> | string[], username?: string, password?: string): Promise<MoneroDaemonRpc> {
return MoneroDaemonRpc.connectToDaemonRpc(uriOrConfig, username, password);
}
/**
* <p>Create a client connected to monero-wallet-rpc.</p>
*
* <p>Examples:</p>
*
* <code>
* let walletRpc = await moneroTs.connectToWalletRpc({<br>
* uri: "http://localhost:38081",<br>
* username: "superuser",<br>
* password: "abctesting123",<br>
* rejectUnauthorized: false // e.g. local development<br>
* });<br>
* </code><br>
* <br>
* <code>
* // connect to monero-wallet-rpc running as internal process<br>
* let walletRpc = await moneroTs.connectToWalletRpc({cmd: [<br>
* "/path/to/monero-wallet-rpc",<br>
* "--stagenet",<br>
* "--daemon-address", "http://localhost:38081",<br>
* "--daemon-login", "superuser:abctesting123",<br>
* "--rpc-bind-port", "38085",<br>
* "--rpc-login", "rpc_user:abc123",<br>
* "--wallet-dir", "/path/to/wallets", // defaults to monero-wallet-rpc directory<br>
* "--rpc-access-control-origins", "http://localhost:8080"<br>
* ]});
* </code>
*
* @param {string|Partial<MoneroRpcConnection>|Partial<MoneroWalletConfig>|string[]} uriOrConfig - uri or rpc connection or config or terminal parameters to connect to monero-wallet-rpc
* @param {string} [username] - username to authenticate with monero-wallet-rpc
* @param {string} [password] - password to authenticate with monero-wallet-rpc
* @return {Promise<MoneroWalletRpc>} the wallet RPC client
*/
function connectToWalletRpc(uriOrConfig: string | Partial<MoneroRpcConnection> | Partial<MoneroWalletConfig> | string[], username?: string, password?: string): Promise<MoneroWalletRpc> {
return MoneroWalletRpc.connectToWalletRpc(uriOrConfig, username, password);
}
/**
* <p>Create a Monero wallet using client-side WebAssembly bindings to monero-project's wallet2 in C++.<p>
*
* <p>Example:</p>
*
* <code>
* const wallet = await moneroTs.createWalletFull({<br>
* path: "./test_wallets/wallet1", // leave blank for in-memory wallet<br>
* password: "supersecretpassword",<br>
* networkType: moneroTs.MoneroNetworkType.STAGENET,<br>
* seed: "coexist igloo pamphlet lagoon...",<br>
* restoreHeight: 1543218,<br>
* server: "http://localhost:38081"<br>
* });
* </code><br>
* <br>
* <code>
* const wallet = await moneroTs.createWalletFull({<br>
* path: "./test_wallets/wallet1", // leave blank for in-memory wallet<br>
* password: "supersecretpassword",<br>
* networkType: moneroTs.MoneroNetworkType.STAGENET,<br>
* seed: "coexist igloo pamphlet lagoon...",<br>
* restoreHeight: 1543218,<br>
* proxyToWorker: false, // override default<br>
* server: {<br>
* uri: "http://localhost:38081",<br>
* username: "daemon_user",<br>
* password: "daemon_password_123"<br>
* }<br>
* });
* </code>
*
* @param {Partial<MoneroWalletConfig>} config - MoneroWalletConfig or equivalent config object
* @param {string} [config.path] - path of the wallet to create (optional, in-memory wallet if not given)
* @param {string} [config.password] - password of the wallet to create
* @param {MoneroNetworkType|string} [config.networkType] - network type of the wallet to create (one of "mainnet", "testnet", "stagenet" or MoneroNetworkType.MAINNET|TESTNET|STAGENET)
* @param {string} [config.seed] - seed of the wallet to create (optional, random wallet created if neither seed nor keys given)
* @param {string} [config.seedOffset] - the offset used to derive a new seed from the given seed to recover a secret wallet from the seed phrase
* @param {boolean} [config.isMultisig] - restore multisig wallet from seed
* @param {string} [config.primaryAddress] - primary address of the wallet to create (only provide if restoring from keys)
* @param {string} [config.privateViewKey] - private view key of the wallet to create (optional)
* @param {string} [config.privateSpendKey] - private spend key of the wallet to create (optional)
* @param {number} [config.restoreHeight] - block height to start scanning from (defaults to 0 unless generating random wallet)
* @param {string} [config.language] - language of the wallet's seed phrase (defaults to "English" or auto-detected)
* @param {number} [config.accountLookahead] - number of accounts to scan (optional)
* @param {number} [config.subaddressLookahead] - number of subaddresses to scan per account (optional)
* @param {string|Partial<MoneroRpcConnection>} [config.server] - connection to monero daemon (optional)
* @param {MoneroConnectionManager} [config.connectionManager] - manage connections to monerod (optional)
* @param {boolean} [config.rejectUnauthorized] - reject self-signed server certificates if true (defaults to true)
* @param {boolean} [config.proxyToWorker] - proxies wallet operations to a worker in order to not block the main thread (default true)
* @param {any} [config.fs] - file system compatible with Node.js `fs.promises` API (defaults to disk or in-memory FS if browser)
* @return {Promise<MoneroWalletFull>} the created wallet
*/
function createWalletFull(config: Partial<MoneroWalletConfig>): Promise<MoneroWalletFull> {
return MoneroWalletFull.createWallet(new MoneroWalletConfig(config));
}
/**
* <p>Open an existing Monero wallet using client-side WebAssembly bindings to monero-project's wallet2 in C++.<p>
*
* <p>Example:<p>
*
* <code>
* const wallet = await moneroTs.openWalletFull({<br>
* path: "./wallets/wallet1",<br>
* password: "supersecretpassword",<br>
* networkType: moneroTs.MoneroNetworkType.STAGENET,<br>
* server: { // daemon configuration<br>
* uri: "http://localhost:38081",<br>
* username: "superuser",<br>
* password: "abctesting123"<br>
* }<br>
* });
* </code>
*
* @param {Partial<MoneroWalletConfig>} config - config to open a full wallet
* @param {string} [config.path] - path of the wallet to open (optional if 'keysData' provided)
* @param {string} [config.password] - password of the wallet to open
* @param {string|number} [config.networkType] - network type of the wallet to open (one of "mainnet", "testnet", "stagenet" or MoneroNetworkType.MAINNET|TESTNET|STAGENET)
* @param {string|MoneroRpcConnection} [config.server] - uri or connection to monero daemon (optional)
* @param {Uint8Array} [config.keysData] - wallet keys data to open (optional if path provided)
* @param {Uint8Array} [config.cacheData] - wallet cache data to open (optional)
* @param {boolean} [config.proxyToWorker] - proxies wallet operations to a worker in order to not block the main thread (default true)
* @param {any} [config.fs] - file system compatible with Node.js `fs.promises` API (defaults to disk or in-memory FS if browser)
* @return {Promise<MoneroWalletFull>} the opened wallet
*/
function openWalletFull(config: Partial<MoneroWalletConfig>): Promise<MoneroWalletFull> {
return MoneroWalletFull.openWallet(new MoneroWalletConfig(config));
}
/**
* <p>Create a wallet using WebAssembly bindings to monero-project.</p>
*
* <p>Example:</p>
*
* <code>
* const wallet = await moneroTs.createWalletKeys({<br>
* password: "abc123",<br>
* networkType: moneroTs.MoneroNetworkType.STAGENET,<br>
* seed: "coexist igloo pamphlet lagoon..."<br>
* });
* </code>
*
* @param {Partial<MoneroWalletConfig>} config - MoneroWalletConfig or equivalent config object
* @param {string|number} config.networkType - network type of the wallet to create (one of "mainnet", "testnet", "stagenet" or MoneroNetworkType.MAINNET|TESTNET|STAGENET)
* @param {string} [config.seed] - seed of the wallet to create (optional, random wallet created if neither seed nor keys given)
* @param {string} [config.seedOffset] - the offset used to derive a new seed from the given seed to recover a secret wallet from the seed phrase
* @param {string} [config.primaryAddress] - primary address of the wallet to create (only provide if restoring from keys)
* @param {string} [config.privateViewKey] - private view key of the wallet to create (optional)
* @param {string} [config.privateSpendKey] - private spend key of the wallet to create (optional)
* @param {string} [config.language] - language of the wallet's seed (defaults to "English" or auto-detected)
* @return {Promise<MoneroWalletKeys>} the created wallet
*/
function createWalletKeys(config: Partial<MoneroWalletConfig>): Promise<MoneroWalletKeys> {
return MoneroWalletKeys.createWallet(new MoneroWalletConfig(config));
}
// --------------------------------- EXPORTS ----------------------------------
export {
// types
GenUtils,
Filter,
MoneroError,
HttpClient,
LibraryUtils,
MoneroRpcConnection,
MoneroRpcError,
SslOptions,
TaskLooper,
ConnectionType,
MoneroAltChain,
MoneroBan,
MoneroBlockHeader,
MoneroBlock,
MoneroBlockTemplate,
MoneroConnectionSpan,
MoneroDaemonConfig,
MoneroDaemonInfo,
MoneroDaemonListener,
MoneroDaemonSyncInfo,
MoneroDaemonUpdateCheckResult,
MoneroDaemonUpdateDownloadResult,
MoneroFeeEstimate,
MoneroHardForkInfo,
MoneroKeyImage,
MoneroKeyImageSpentStatus,
MoneroMinerTxSum,
MoneroMiningStatus,
MoneroNetworkType,
MoneroOutput,
MoneroOutputHistogramEntry,
MoneroSubmitTxResult,
MoneroTx,
MoneroTxPoolStats,
MoneroVersion,
MoneroPeer,
MoneroPruneResult,
MoneroAccount,
MoneroAccountTag,
MoneroAddressBookEntry,
MoneroCheck,
MoneroCheckReserve,
MoneroCheckTx,
MoneroDestination,
MoneroIntegratedAddress,
MoneroKeyImageImportResult,
MoneroMultisigInfo,
MoneroMultisigInitResult,
MoneroMultisigSignResult,
MoneroOutputWallet,
MoneroOutputQuery,
MoneroTxPriority,
MoneroTxConfig,
MoneroSubaddress,
MoneroSyncResult,
MoneroTransfer,
MoneroIncomingTransfer,
MoneroOutgoingTransfer,
MoneroTransferQuery,
MoneroTxSet,
MoneroTxWallet,
MoneroTxQuery,
MoneroWalletListener,
MoneroWalletConfig,
MoneroMessageSignatureType,
MoneroMessageSignatureResult,
MoneroConnectionManagerListener,
MoneroConnectionManager,
MoneroDaemon,
MoneroWallet,
MoneroDaemonRpc,
MoneroWalletRpc,
MoneroWalletKeys,
MoneroWalletFull,
MoneroUtils,
ThreadPool,
// global functions
getVersion,
connectToDaemonRpc,
connectToWalletRpc,
createWalletFull,
openWalletFull,
createWalletKeys
};
// export default object with aggregate of all exports
const moneroTs = {
GenUtils,
Filter,
MoneroError,
HttpClient,
LibraryUtils,
MoneroRpcConnection,
MoneroRpcError,
SslOptions,
TaskLooper,
ConnectionType,
MoneroAltChain,
MoneroBan,
MoneroBlockHeader,
MoneroBlock,
MoneroBlockTemplate,
MoneroConnectionSpan,
MoneroDaemonConfig,
MoneroDaemonInfo,
MoneroDaemonListener,
MoneroDaemonSyncInfo,
MoneroDaemonUpdateCheckResult,
MoneroDaemonUpdateDownloadResult,
MoneroFeeEstimate,
MoneroHardForkInfo,
MoneroKeyImage,
MoneroKeyImageSpentStatus,
MoneroMinerTxSum,
MoneroMiningStatus,
MoneroNetworkType,
MoneroOutput,
MoneroOutputHistogramEntry,
MoneroSubmitTxResult,
MoneroTx,
MoneroTxPoolStats,
MoneroVersion,
MoneroPeer,
MoneroPruneResult,
MoneroAccount,
MoneroAccountTag,
MoneroAddressBookEntry,
MoneroCheck,
MoneroCheckReserve,
MoneroCheckTx,
MoneroDestination,
MoneroIntegratedAddress,
MoneroKeyImageImportResult,
MoneroMultisigInfo,
MoneroMultisigInitResult,
MoneroMultisigSignResult,
MoneroOutputWallet,
MoneroOutputQuery,
MoneroTxPriority,
MoneroTxConfig,
MoneroSubaddress,
MoneroSyncResult,
MoneroTransfer,
MoneroIncomingTransfer,
MoneroOutgoingTransfer,
MoneroTransferQuery,
MoneroTxSet,
MoneroTxWallet,
MoneroTxQuery,
MoneroWalletListener,
MoneroWalletConfig,
MoneroMessageSignatureType,
MoneroMessageSignatureResult,
MoneroConnectionManagerListener,
MoneroConnectionManager,
MoneroDaemon,
MoneroWallet,
MoneroDaemonRpc,
MoneroWalletRpc,
MoneroWalletKeys,
MoneroWalletFull,
MoneroUtils,
ThreadPool,
// global functions
getVersion,
connectToDaemonRpc,
connectToWalletRpc,
createWalletFull,
openWalletFull,
createWalletKeys
}
export default moneroTs;
// augment global scope with same namespace as default export
declare global {
namespace moneroTs {
type GenUtils = InstanceType<typeof import("./index").GenUtils>;
type Filter = InstanceType<typeof import("./index").Filter>;
type MoneroError = InstanceType<typeof import("./index").MoneroError>;
type HttpClient = InstanceType<typeof import("./index").HttpClient>;
type LibraryUtils = InstanceType<typeof import("./index").LibraryUtils>;
type MoneroRpcConnection = InstanceType<typeof import("./index").MoneroRpcConnection>;
type MoneroRpcError = InstanceType<typeof import("./index").MoneroRpcError>;
type SslOptions = InstanceType<typeof import("./index").SslOptions>;
type TaskLooper = InstanceType<typeof import("./index").TaskLooper>;
type ConnectionType = import("./index").ConnectionType; // type alias for enum
type MoneroAltChain = InstanceType<typeof import("./index").MoneroAltChain>;
type MoneroBan = InstanceType<typeof import("./index").MoneroBan>;
type MoneroBlockHeader = InstanceType<typeof import("./index").MoneroBlockHeader>;
type MoneroBlock = InstanceType<typeof import("./index").MoneroBlock>;
type MoneroBlockTemplate = InstanceType<typeof import("./index").MoneroBlockTemplate>;
type MoneroConnectionSpan = InstanceType<typeof import("./index").MoneroConnectionSpan>;
type MoneroDaemonConfig = InstanceType<typeof import("./index").MoneroDaemonConfig>;
type MoneroDaemonInfo = InstanceType<typeof import("./index").MoneroDaemonInfo>;
type MoneroDaemonListener = InstanceType<typeof import("./index").MoneroDaemonListener>;
type MoneroDaemonSyncInfo = InstanceType<typeof import("./index").MoneroDaemonSyncInfo>;
type MoneroDaemonUpdateCheckResult = InstanceType<typeof import("./index").MoneroDaemonUpdateCheckResult>;
type MoneroDaemonUpdateDownloadResult = InstanceType<typeof import("./index").MoneroDaemonUpdateDownloadResult>;
type MoneroFeeEstimate = InstanceType<typeof import("./index").MoneroFeeEstimate>;
type MoneroHardForkInfo = InstanceType<typeof import("./index").MoneroHardForkInfo>;
type MoneroKeyImage = InstanceType<typeof import("./index").MoneroKeyImage>;
type MoneroKeyImageSpentStatus = import("./index").MoneroKeyImageSpentStatus;
type MoneroMinerTxSum = InstanceType<typeof import("./index").MoneroMinerTxSum>;
type MoneroMiningStatus = InstanceType<typeof import("./index").MoneroMiningStatus>;
type MoneroNetworkType = InstanceType<typeof import("./index").MoneroNetworkType>;
type MoneroOutput = InstanceType<typeof import("./index").MoneroOutput>;
type MoneroOutputHistogramEntry = InstanceType<typeof import("./index").MoneroOutputHistogramEntry>;
type MoneroSubmitTxResult = InstanceType<typeof import("./index").MoneroSubmitTxResult>;
type MoneroTx = InstanceType<typeof import("./index").MoneroTx>;
type MoneroTxPoolStats = InstanceType<typeof import("./index").MoneroTxPoolStats>;
type MoneroVersion = InstanceType<typeof import("./index").MoneroVersion>;
type MoneroPeer = InstanceType<typeof import("./index").MoneroPeer>;
type MoneroPruneResult = InstanceType<typeof import("./index").MoneroPruneResult>;
type MoneroAccount = InstanceType<typeof import("./index").MoneroAccount>;
type MoneroAccountTag = InstanceType<typeof import("./index").MoneroAccountTag>;
type MoneroAddressBookEntry = InstanceType<typeof import("./index").MoneroAddressBookEntry>;
type MoneroCheck = InstanceType<typeof import("./index").MoneroCheck>;
type MoneroCheckReserve = InstanceType<typeof import("./index").MoneroCheckReserve>;
type MoneroCheckTx = InstanceType<typeof import("./index").MoneroCheckTx>;
type MoneroDestination = InstanceType<typeof import("./index").MoneroDestination>;
type MoneroIntegratedAddress = InstanceType<typeof import("./index").MoneroIntegratedAddress>;
type MoneroKeyImageImportResult = InstanceType<typeof import("./index").MoneroKeyImageImportResult>;
type MoneroMultisigInfo = InstanceType<typeof import("./index").MoneroMultisigInfo>;
type MoneroMultisigInitResult = InstanceType<typeof import("./index").MoneroMultisigInitResult>;
type MoneroMultisigSignResult = InstanceType<typeof import("./index").MoneroMultisigSignResult>;
type MoneroOutputWallet = InstanceType<typeof import("./index").MoneroOutputWallet>;
type MoneroOutputQuery = InstanceType<typeof import("./index").MoneroOutputQuery>;
type MoneroTxPriority = import("./index").MoneroTxPriority;
type MoneroTxConfig = InstanceType<typeof import("./index").MoneroTxConfig>;
type MoneroSubaddress = InstanceType<typeof import("./index").MoneroSubaddress>;
type MoneroSyncResult = InstanceType<typeof import("./index").MoneroSyncResult>;
type MoneroTransfer = InstanceType<typeof import("./index").MoneroTransfer>;
type MoneroIncomingTransfer = InstanceType<typeof import("./index").MoneroIncomingTransfer>;
type MoneroOutgoingTransfer = InstanceType<typeof import("./index").MoneroOutgoingTransfer>;
type MoneroTransferQuery = InstanceType<typeof import("./index").MoneroTransferQuery>;
type MoneroTxSet = InstanceType<typeof import("./index").MoneroTxSet>;
type MoneroTxWallet = InstanceType<typeof import("./index").MoneroTxWallet>;
type MoneroTxQuery = InstanceType<typeof import("./index").MoneroTxQuery>;
type MoneroWalletListener = InstanceType<typeof import("./index").MoneroWalletListener>;
type MoneroWalletConfig = InstanceType<typeof import("./index").MoneroWalletConfig>;
type MoneroMessageSignatureType = import("./index").MoneroMessageSignatureType;
type MoneroMessageSignatureResult = InstanceType<typeof import("./index").MoneroMessageSignatureResult>;
type MoneroConnectionManagerListener = InstanceType<typeof import("./index").MoneroConnectionManagerListener>;
type MoneroConnectionManager = InstanceType<typeof import("./index").MoneroConnectionManager>;
type MoneroDaemon = InstanceType<typeof import("./index").MoneroDaemon>;
type MoneroWallet = InstanceType<typeof import("./index").MoneroWallet>;
type MoneroDaemonRpc = InstanceType<typeof import("./index").MoneroDaemonRpc>;
type MoneroWalletRpc = InstanceType<typeof import("./index").MoneroWalletRpc>;
type MoneroWalletKeys = InstanceType<typeof import("./index").MoneroWalletKeys>;
type MoneroWalletFull = InstanceType<typeof import("./index").MoneroWalletFull>;
type MoneroUtils = InstanceType<typeof import("./index").MoneroUtils>;
type ThreadPool = InstanceType<typeof import("./index").ThreadPool>;
}
}