@gitmyabi-stg/lusd 1.0.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.
@@ -0,0 +1,997 @@
1
+ import type { Address, PublicClient, WalletClient } from 'viem';
2
+ /**
3
+ * LUSDToken ABI
4
+ *
5
+ * This ABI is typed using viem's type system for full type safety.
6
+ */
7
+ export declare const LUSDTokenAbi: readonly [{
8
+ readonly inputs: readonly [{
9
+ readonly internalType: "address";
10
+ readonly name: "_troveManagerAddress";
11
+ readonly type: "address";
12
+ }, {
13
+ readonly internalType: "address";
14
+ readonly name: "_stabilityPoolAddress";
15
+ readonly type: "address";
16
+ }, {
17
+ readonly internalType: "address";
18
+ readonly name: "_borrowerOperationsAddress";
19
+ readonly type: "address";
20
+ }];
21
+ readonly stateMutability: "nonpayable";
22
+ readonly type: "constructor";
23
+ }, {
24
+ readonly anonymous: false;
25
+ readonly inputs: readonly [{
26
+ readonly indexed: true;
27
+ readonly internalType: "address";
28
+ readonly name: "owner";
29
+ readonly type: "address";
30
+ }, {
31
+ readonly indexed: true;
32
+ readonly internalType: "address";
33
+ readonly name: "spender";
34
+ readonly type: "address";
35
+ }, {
36
+ readonly indexed: false;
37
+ readonly internalType: "uint256";
38
+ readonly name: "value";
39
+ readonly type: "uint256";
40
+ }];
41
+ readonly name: "Approval";
42
+ readonly type: "event";
43
+ }, {
44
+ readonly anonymous: false;
45
+ readonly inputs: readonly [{
46
+ readonly indexed: false;
47
+ readonly internalType: "address";
48
+ readonly name: "_newBorrowerOperationsAddress";
49
+ readonly type: "address";
50
+ }];
51
+ readonly name: "BorrowerOperationsAddressChanged";
52
+ readonly type: "event";
53
+ }, {
54
+ readonly anonymous: false;
55
+ readonly inputs: readonly [{
56
+ readonly indexed: false;
57
+ readonly internalType: "address";
58
+ readonly name: "_user";
59
+ readonly type: "address";
60
+ }, {
61
+ readonly indexed: false;
62
+ readonly internalType: "uint256";
63
+ readonly name: "_amount";
64
+ readonly type: "uint256";
65
+ }];
66
+ readonly name: "LUSDTokenBalanceUpdated";
67
+ readonly type: "event";
68
+ }, {
69
+ readonly anonymous: false;
70
+ readonly inputs: readonly [{
71
+ readonly indexed: false;
72
+ readonly internalType: "address";
73
+ readonly name: "_newStabilityPoolAddress";
74
+ readonly type: "address";
75
+ }];
76
+ readonly name: "StabilityPoolAddressChanged";
77
+ readonly type: "event";
78
+ }, {
79
+ readonly anonymous: false;
80
+ readonly inputs: readonly [{
81
+ readonly indexed: true;
82
+ readonly internalType: "address";
83
+ readonly name: "from";
84
+ readonly type: "address";
85
+ }, {
86
+ readonly indexed: true;
87
+ readonly internalType: "address";
88
+ readonly name: "to";
89
+ readonly type: "address";
90
+ }, {
91
+ readonly indexed: false;
92
+ readonly internalType: "uint256";
93
+ readonly name: "value";
94
+ readonly type: "uint256";
95
+ }];
96
+ readonly name: "Transfer";
97
+ readonly type: "event";
98
+ }, {
99
+ readonly anonymous: false;
100
+ readonly inputs: readonly [{
101
+ readonly indexed: false;
102
+ readonly internalType: "address";
103
+ readonly name: "_troveManagerAddress";
104
+ readonly type: "address";
105
+ }];
106
+ readonly name: "TroveManagerAddressChanged";
107
+ readonly type: "event";
108
+ }, {
109
+ readonly inputs: readonly [{
110
+ readonly internalType: "address";
111
+ readonly name: "owner";
112
+ readonly type: "address";
113
+ }, {
114
+ readonly internalType: "address";
115
+ readonly name: "spender";
116
+ readonly type: "address";
117
+ }];
118
+ readonly name: "allowance";
119
+ readonly outputs: readonly [{
120
+ readonly internalType: "uint256";
121
+ readonly name: "";
122
+ readonly type: "uint256";
123
+ }];
124
+ readonly stateMutability: "view";
125
+ readonly type: "function";
126
+ }, {
127
+ readonly inputs: readonly [{
128
+ readonly internalType: "address";
129
+ readonly name: "spender";
130
+ readonly type: "address";
131
+ }, {
132
+ readonly internalType: "uint256";
133
+ readonly name: "amount";
134
+ readonly type: "uint256";
135
+ }];
136
+ readonly name: "approve";
137
+ readonly outputs: readonly [{
138
+ readonly internalType: "bool";
139
+ readonly name: "";
140
+ readonly type: "bool";
141
+ }];
142
+ readonly stateMutability: "nonpayable";
143
+ readonly type: "function";
144
+ }, {
145
+ readonly inputs: readonly [{
146
+ readonly internalType: "address";
147
+ readonly name: "account";
148
+ readonly type: "address";
149
+ }];
150
+ readonly name: "balanceOf";
151
+ readonly outputs: readonly [{
152
+ readonly internalType: "uint256";
153
+ readonly name: "";
154
+ readonly type: "uint256";
155
+ }];
156
+ readonly stateMutability: "view";
157
+ readonly type: "function";
158
+ }, {
159
+ readonly inputs: readonly [];
160
+ readonly name: "borrowerOperationsAddress";
161
+ readonly outputs: readonly [{
162
+ readonly internalType: "address";
163
+ readonly name: "";
164
+ readonly type: "address";
165
+ }];
166
+ readonly stateMutability: "view";
167
+ readonly type: "function";
168
+ }, {
169
+ readonly inputs: readonly [{
170
+ readonly internalType: "address";
171
+ readonly name: "_account";
172
+ readonly type: "address";
173
+ }, {
174
+ readonly internalType: "uint256";
175
+ readonly name: "_amount";
176
+ readonly type: "uint256";
177
+ }];
178
+ readonly name: "burn";
179
+ readonly outputs: readonly [];
180
+ readonly stateMutability: "nonpayable";
181
+ readonly type: "function";
182
+ }, {
183
+ readonly inputs: readonly [];
184
+ readonly name: "decimals";
185
+ readonly outputs: readonly [{
186
+ readonly internalType: "uint8";
187
+ readonly name: "";
188
+ readonly type: "uint8";
189
+ }];
190
+ readonly stateMutability: "view";
191
+ readonly type: "function";
192
+ }, {
193
+ readonly inputs: readonly [{
194
+ readonly internalType: "address";
195
+ readonly name: "spender";
196
+ readonly type: "address";
197
+ }, {
198
+ readonly internalType: "uint256";
199
+ readonly name: "subtractedValue";
200
+ readonly type: "uint256";
201
+ }];
202
+ readonly name: "decreaseAllowance";
203
+ readonly outputs: readonly [{
204
+ readonly internalType: "bool";
205
+ readonly name: "";
206
+ readonly type: "bool";
207
+ }];
208
+ readonly stateMutability: "nonpayable";
209
+ readonly type: "function";
210
+ }, {
211
+ readonly inputs: readonly [];
212
+ readonly name: "domainSeparator";
213
+ readonly outputs: readonly [{
214
+ readonly internalType: "bytes32";
215
+ readonly name: "";
216
+ readonly type: "bytes32";
217
+ }];
218
+ readonly stateMutability: "view";
219
+ readonly type: "function";
220
+ }, {
221
+ readonly inputs: readonly [{
222
+ readonly internalType: "address";
223
+ readonly name: "spender";
224
+ readonly type: "address";
225
+ }, {
226
+ readonly internalType: "uint256";
227
+ readonly name: "addedValue";
228
+ readonly type: "uint256";
229
+ }];
230
+ readonly name: "increaseAllowance";
231
+ readonly outputs: readonly [{
232
+ readonly internalType: "bool";
233
+ readonly name: "";
234
+ readonly type: "bool";
235
+ }];
236
+ readonly stateMutability: "nonpayable";
237
+ readonly type: "function";
238
+ }, {
239
+ readonly inputs: readonly [{
240
+ readonly internalType: "address";
241
+ readonly name: "_account";
242
+ readonly type: "address";
243
+ }, {
244
+ readonly internalType: "uint256";
245
+ readonly name: "_amount";
246
+ readonly type: "uint256";
247
+ }];
248
+ readonly name: "mint";
249
+ readonly outputs: readonly [];
250
+ readonly stateMutability: "nonpayable";
251
+ readonly type: "function";
252
+ }, {
253
+ readonly inputs: readonly [];
254
+ readonly name: "name";
255
+ readonly outputs: readonly [{
256
+ readonly internalType: "string";
257
+ readonly name: "";
258
+ readonly type: "string";
259
+ }];
260
+ readonly stateMutability: "view";
261
+ readonly type: "function";
262
+ }, {
263
+ readonly inputs: readonly [{
264
+ readonly internalType: "address";
265
+ readonly name: "owner";
266
+ readonly type: "address";
267
+ }];
268
+ readonly name: "nonces";
269
+ readonly outputs: readonly [{
270
+ readonly internalType: "uint256";
271
+ readonly name: "";
272
+ readonly type: "uint256";
273
+ }];
274
+ readonly stateMutability: "view";
275
+ readonly type: "function";
276
+ }, {
277
+ readonly inputs: readonly [{
278
+ readonly internalType: "address";
279
+ readonly name: "owner";
280
+ readonly type: "address";
281
+ }, {
282
+ readonly internalType: "address";
283
+ readonly name: "spender";
284
+ readonly type: "address";
285
+ }, {
286
+ readonly internalType: "uint256";
287
+ readonly name: "amount";
288
+ readonly type: "uint256";
289
+ }, {
290
+ readonly internalType: "uint256";
291
+ readonly name: "deadline";
292
+ readonly type: "uint256";
293
+ }, {
294
+ readonly internalType: "uint8";
295
+ readonly name: "v";
296
+ readonly type: "uint8";
297
+ }, {
298
+ readonly internalType: "bytes32";
299
+ readonly name: "r";
300
+ readonly type: "bytes32";
301
+ }, {
302
+ readonly internalType: "bytes32";
303
+ readonly name: "s";
304
+ readonly type: "bytes32";
305
+ }];
306
+ readonly name: "permit";
307
+ readonly outputs: readonly [];
308
+ readonly stateMutability: "nonpayable";
309
+ readonly type: "function";
310
+ }, {
311
+ readonly inputs: readonly [];
312
+ readonly name: "permitTypeHash";
313
+ readonly outputs: readonly [{
314
+ readonly internalType: "bytes32";
315
+ readonly name: "";
316
+ readonly type: "bytes32";
317
+ }];
318
+ readonly stateMutability: "view";
319
+ readonly type: "function";
320
+ }, {
321
+ readonly inputs: readonly [{
322
+ readonly internalType: "address";
323
+ readonly name: "_poolAddress";
324
+ readonly type: "address";
325
+ }, {
326
+ readonly internalType: "address";
327
+ readonly name: "_receiver";
328
+ readonly type: "address";
329
+ }, {
330
+ readonly internalType: "uint256";
331
+ readonly name: "_amount";
332
+ readonly type: "uint256";
333
+ }];
334
+ readonly name: "returnFromPool";
335
+ readonly outputs: readonly [];
336
+ readonly stateMutability: "nonpayable";
337
+ readonly type: "function";
338
+ }, {
339
+ readonly inputs: readonly [{
340
+ readonly internalType: "address";
341
+ readonly name: "_sender";
342
+ readonly type: "address";
343
+ }, {
344
+ readonly internalType: "address";
345
+ readonly name: "_poolAddress";
346
+ readonly type: "address";
347
+ }, {
348
+ readonly internalType: "uint256";
349
+ readonly name: "_amount";
350
+ readonly type: "uint256";
351
+ }];
352
+ readonly name: "sendToPool";
353
+ readonly outputs: readonly [];
354
+ readonly stateMutability: "nonpayable";
355
+ readonly type: "function";
356
+ }, {
357
+ readonly inputs: readonly [];
358
+ readonly name: "stabilityPoolAddress";
359
+ readonly outputs: readonly [{
360
+ readonly internalType: "address";
361
+ readonly name: "";
362
+ readonly type: "address";
363
+ }];
364
+ readonly stateMutability: "view";
365
+ readonly type: "function";
366
+ }, {
367
+ readonly inputs: readonly [];
368
+ readonly name: "symbol";
369
+ readonly outputs: readonly [{
370
+ readonly internalType: "string";
371
+ readonly name: "";
372
+ readonly type: "string";
373
+ }];
374
+ readonly stateMutability: "view";
375
+ readonly type: "function";
376
+ }, {
377
+ readonly inputs: readonly [];
378
+ readonly name: "totalSupply";
379
+ readonly outputs: readonly [{
380
+ readonly internalType: "uint256";
381
+ readonly name: "";
382
+ readonly type: "uint256";
383
+ }];
384
+ readonly stateMutability: "view";
385
+ readonly type: "function";
386
+ }, {
387
+ readonly inputs: readonly [{
388
+ readonly internalType: "address";
389
+ readonly name: "recipient";
390
+ readonly type: "address";
391
+ }, {
392
+ readonly internalType: "uint256";
393
+ readonly name: "amount";
394
+ readonly type: "uint256";
395
+ }];
396
+ readonly name: "transfer";
397
+ readonly outputs: readonly [{
398
+ readonly internalType: "bool";
399
+ readonly name: "";
400
+ readonly type: "bool";
401
+ }];
402
+ readonly stateMutability: "nonpayable";
403
+ readonly type: "function";
404
+ }, {
405
+ readonly inputs: readonly [{
406
+ readonly internalType: "address";
407
+ readonly name: "sender";
408
+ readonly type: "address";
409
+ }, {
410
+ readonly internalType: "address";
411
+ readonly name: "recipient";
412
+ readonly type: "address";
413
+ }, {
414
+ readonly internalType: "uint256";
415
+ readonly name: "amount";
416
+ readonly type: "uint256";
417
+ }];
418
+ readonly name: "transferFrom";
419
+ readonly outputs: readonly [{
420
+ readonly internalType: "bool";
421
+ readonly name: "";
422
+ readonly type: "bool";
423
+ }];
424
+ readonly stateMutability: "nonpayable";
425
+ readonly type: "function";
426
+ }, {
427
+ readonly inputs: readonly [];
428
+ readonly name: "troveManagerAddress";
429
+ readonly outputs: readonly [{
430
+ readonly internalType: "address";
431
+ readonly name: "";
432
+ readonly type: "address";
433
+ }];
434
+ readonly stateMutability: "view";
435
+ readonly type: "function";
436
+ }, {
437
+ readonly inputs: readonly [];
438
+ readonly name: "version";
439
+ readonly outputs: readonly [{
440
+ readonly internalType: "string";
441
+ readonly name: "";
442
+ readonly type: "string";
443
+ }];
444
+ readonly stateMutability: "view";
445
+ readonly type: "function";
446
+ }];
447
+ /**
448
+ * Type-safe ABI for LUSDToken
449
+ */
450
+ export type LUSDTokenAbi = typeof LUSDTokenAbi;
451
+ /**
452
+ * Contract instance type for LUSDToken
453
+ */
454
+ export type LUSDTokenContract = any;
455
+ /**
456
+ * LUSDToken Contract Class
457
+ *
458
+ * Provides a class-based API similar to TypeChain for interacting with the contract.
459
+ *
460
+ * @example
461
+ * ```typescript
462
+ * import { createPublicClient, createWalletClient, http } from 'viem';
463
+ * import { mainnet } from 'viem/chains';
464
+ * import { LUSDToken } from 'LUSDToken';
465
+ *
466
+ * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
467
+ * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
468
+ *
469
+ * const contract = new LUSDToken('0x...', { publicClient, walletClient });
470
+ *
471
+ * // Read functions
472
+ * const result = await contract.balanceOf('0x...');
473
+ *
474
+ * // Write functions
475
+ * const hash = await contract.transfer('0x...', 1000n);
476
+ *
477
+ * // Simulate transactions (dry-run)
478
+ * const simulation = await contract.simulate.transfer('0x...', 1000n);
479
+ * console.log('Gas estimate:', simulation.request.gas);
480
+ *
481
+ * // Watch events
482
+ * const unwatch = contract.watch.Transfer((event) => {
483
+ * console.log('Transfer event:', event);
484
+ * });
485
+ * ```
486
+ */
487
+ export declare class LUSDToken {
488
+ private contract;
489
+ private contractAddress;
490
+ private publicClient;
491
+ constructor(address: Address, clients: {
492
+ publicClient: PublicClient;
493
+ walletClient?: WalletClient;
494
+ });
495
+ /**
496
+ * Get the contract address
497
+ */
498
+ get address(): Address;
499
+ /**
500
+ * Get the underlying viem contract instance.
501
+ */
502
+ getContract(): LUSDTokenContract;
503
+ /**
504
+ * allowance
505
+ * view
506
+ */
507
+ allowance(owner: `0x${string}`, spender: `0x${string}`): Promise<bigint>;
508
+ /**
509
+ * balanceOf
510
+ * view
511
+ */
512
+ balanceOf(account: `0x${string}`): Promise<bigint>;
513
+ /**
514
+ * borrowerOperationsAddress
515
+ * view
516
+ */
517
+ borrowerOperationsAddress(): Promise<`0x${string}`>;
518
+ /**
519
+ * decimals
520
+ * view
521
+ */
522
+ decimals(): Promise<bigint>;
523
+ /**
524
+ * domainSeparator
525
+ * view
526
+ */
527
+ domainSeparator(): Promise<`0x${string}`>;
528
+ /**
529
+ * name
530
+ * view
531
+ */
532
+ name(): Promise<string>;
533
+ /**
534
+ * nonces
535
+ * view
536
+ */
537
+ nonces(owner: `0x${string}`): Promise<bigint>;
538
+ /**
539
+ * permitTypeHash
540
+ * view
541
+ */
542
+ permitTypeHash(): Promise<`0x${string}`>;
543
+ /**
544
+ * stabilityPoolAddress
545
+ * view
546
+ */
547
+ stabilityPoolAddress(): Promise<`0x${string}`>;
548
+ /**
549
+ * symbol
550
+ * view
551
+ */
552
+ symbol(): Promise<string>;
553
+ /**
554
+ * totalSupply
555
+ * view
556
+ */
557
+ totalSupply(): Promise<bigint>;
558
+ /**
559
+ * troveManagerAddress
560
+ * view
561
+ */
562
+ troveManagerAddress(): Promise<`0x${string}`>;
563
+ /**
564
+ * version
565
+ * view
566
+ */
567
+ version(): Promise<string>;
568
+ /**
569
+ * approve
570
+ * nonpayable
571
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
572
+ */
573
+ approve(spender: `0x${string}`, amount: bigint, options?: {
574
+ accessList?: import('viem').AccessList;
575
+ authorizationList?: import('viem').AuthorizationList;
576
+ chain?: import('viem').Chain | null;
577
+ dataSuffix?: `0x${string}`;
578
+ gas?: bigint;
579
+ gasPrice?: bigint;
580
+ maxFeePerGas?: bigint;
581
+ maxPriorityFeePerGas?: bigint;
582
+ nonce?: number;
583
+ value?: bigint;
584
+ }): Promise<`0x${string}`>;
585
+ /**
586
+ * burn
587
+ * nonpayable
588
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
589
+ */
590
+ burn(_account: `0x${string}`, _amount: bigint, options?: {
591
+ accessList?: import('viem').AccessList;
592
+ authorizationList?: import('viem').AuthorizationList;
593
+ chain?: import('viem').Chain | null;
594
+ dataSuffix?: `0x${string}`;
595
+ gas?: bigint;
596
+ gasPrice?: bigint;
597
+ maxFeePerGas?: bigint;
598
+ maxPriorityFeePerGas?: bigint;
599
+ nonce?: number;
600
+ value?: bigint;
601
+ }): Promise<`0x${string}`>;
602
+ /**
603
+ * decreaseAllowance
604
+ * nonpayable
605
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
606
+ */
607
+ decreaseAllowance(spender: `0x${string}`, subtractedValue: bigint, options?: {
608
+ accessList?: import('viem').AccessList;
609
+ authorizationList?: import('viem').AuthorizationList;
610
+ chain?: import('viem').Chain | null;
611
+ dataSuffix?: `0x${string}`;
612
+ gas?: bigint;
613
+ gasPrice?: bigint;
614
+ maxFeePerGas?: bigint;
615
+ maxPriorityFeePerGas?: bigint;
616
+ nonce?: number;
617
+ value?: bigint;
618
+ }): Promise<`0x${string}`>;
619
+ /**
620
+ * increaseAllowance
621
+ * nonpayable
622
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
623
+ */
624
+ increaseAllowance(spender: `0x${string}`, addedValue: bigint, options?: {
625
+ accessList?: import('viem').AccessList;
626
+ authorizationList?: import('viem').AuthorizationList;
627
+ chain?: import('viem').Chain | null;
628
+ dataSuffix?: `0x${string}`;
629
+ gas?: bigint;
630
+ gasPrice?: bigint;
631
+ maxFeePerGas?: bigint;
632
+ maxPriorityFeePerGas?: bigint;
633
+ nonce?: number;
634
+ value?: bigint;
635
+ }): Promise<`0x${string}`>;
636
+ /**
637
+ * mint
638
+ * nonpayable
639
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
640
+ */
641
+ mint(_account: `0x${string}`, _amount: bigint, options?: {
642
+ accessList?: import('viem').AccessList;
643
+ authorizationList?: import('viem').AuthorizationList;
644
+ chain?: import('viem').Chain | null;
645
+ dataSuffix?: `0x${string}`;
646
+ gas?: bigint;
647
+ gasPrice?: bigint;
648
+ maxFeePerGas?: bigint;
649
+ maxPriorityFeePerGas?: bigint;
650
+ nonce?: number;
651
+ value?: bigint;
652
+ }): Promise<`0x${string}`>;
653
+ /**
654
+ * permit
655
+ * nonpayable
656
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
657
+ */
658
+ permit(owner: `0x${string}`, spender: `0x${string}`, amount: bigint, deadline: bigint, v: bigint, r: `0x${string}`, s: `0x${string}`, options?: {
659
+ accessList?: import('viem').AccessList;
660
+ authorizationList?: import('viem').AuthorizationList;
661
+ chain?: import('viem').Chain | null;
662
+ dataSuffix?: `0x${string}`;
663
+ gas?: bigint;
664
+ gasPrice?: bigint;
665
+ maxFeePerGas?: bigint;
666
+ maxPriorityFeePerGas?: bigint;
667
+ nonce?: number;
668
+ value?: bigint;
669
+ }): Promise<`0x${string}`>;
670
+ /**
671
+ * returnFromPool
672
+ * nonpayable
673
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
674
+ */
675
+ returnFromPool(_poolAddress: `0x${string}`, _receiver: `0x${string}`, _amount: bigint, options?: {
676
+ accessList?: import('viem').AccessList;
677
+ authorizationList?: import('viem').AuthorizationList;
678
+ chain?: import('viem').Chain | null;
679
+ dataSuffix?: `0x${string}`;
680
+ gas?: bigint;
681
+ gasPrice?: bigint;
682
+ maxFeePerGas?: bigint;
683
+ maxPriorityFeePerGas?: bigint;
684
+ nonce?: number;
685
+ value?: bigint;
686
+ }): Promise<`0x${string}`>;
687
+ /**
688
+ * sendToPool
689
+ * nonpayable
690
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
691
+ */
692
+ sendToPool(_sender: `0x${string}`, _poolAddress: `0x${string}`, _amount: bigint, options?: {
693
+ accessList?: import('viem').AccessList;
694
+ authorizationList?: import('viem').AuthorizationList;
695
+ chain?: import('viem').Chain | null;
696
+ dataSuffix?: `0x${string}`;
697
+ gas?: bigint;
698
+ gasPrice?: bigint;
699
+ maxFeePerGas?: bigint;
700
+ maxPriorityFeePerGas?: bigint;
701
+ nonce?: number;
702
+ value?: bigint;
703
+ }): Promise<`0x${string}`>;
704
+ /**
705
+ * transfer
706
+ * nonpayable
707
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
708
+ */
709
+ transfer(recipient: `0x${string}`, amount: bigint, options?: {
710
+ accessList?: import('viem').AccessList;
711
+ authorizationList?: import('viem').AuthorizationList;
712
+ chain?: import('viem').Chain | null;
713
+ dataSuffix?: `0x${string}`;
714
+ gas?: bigint;
715
+ gasPrice?: bigint;
716
+ maxFeePerGas?: bigint;
717
+ maxPriorityFeePerGas?: bigint;
718
+ nonce?: number;
719
+ value?: bigint;
720
+ }): Promise<`0x${string}`>;
721
+ /**
722
+ * transferFrom
723
+ * nonpayable
724
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
725
+ */
726
+ transferFrom(sender: `0x${string}`, recipient: `0x${string}`, amount: bigint, options?: {
727
+ accessList?: import('viem').AccessList;
728
+ authorizationList?: import('viem').AuthorizationList;
729
+ chain?: import('viem').Chain | null;
730
+ dataSuffix?: `0x${string}`;
731
+ gas?: bigint;
732
+ gasPrice?: bigint;
733
+ maxFeePerGas?: bigint;
734
+ maxPriorityFeePerGas?: bigint;
735
+ nonce?: number;
736
+ value?: bigint;
737
+ }): Promise<`0x${string}`>;
738
+ /**
739
+ * Simulate contract write operations (dry-run without sending transaction)
740
+ *
741
+ * @example
742
+ * const result = await contract.simulate.transfer('0x...', 1000n);
743
+ * console.log('Gas estimate:', result.request.gas);
744
+ * console.log('Would succeed:', result.result);
745
+ */
746
+ get simulate(): {
747
+ /**
748
+ * Simulate approve
749
+ * Returns gas estimate and result without sending transaction
750
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
751
+ */
752
+ approve(spender: `0x${string}`, amount: bigint, options?: {
753
+ accessList?: import("viem").AccessList;
754
+ authorizationList?: import("viem").AuthorizationList;
755
+ chain?: import("viem").Chain | null;
756
+ dataSuffix?: `0x${string}`;
757
+ gas?: bigint;
758
+ gasPrice?: bigint;
759
+ maxFeePerGas?: bigint;
760
+ maxPriorityFeePerGas?: bigint;
761
+ nonce?: number;
762
+ value?: bigint;
763
+ }): Promise<boolean>;
764
+ /**
765
+ * Simulate burn
766
+ * Returns gas estimate and result without sending transaction
767
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
768
+ */
769
+ burn(_account: `0x${string}`, _amount: bigint, options?: {
770
+ accessList?: import("viem").AccessList;
771
+ authorizationList?: import("viem").AuthorizationList;
772
+ chain?: import("viem").Chain | null;
773
+ dataSuffix?: `0x${string}`;
774
+ gas?: bigint;
775
+ gasPrice?: bigint;
776
+ maxFeePerGas?: bigint;
777
+ maxPriorityFeePerGas?: bigint;
778
+ nonce?: number;
779
+ value?: bigint;
780
+ }): Promise<void>;
781
+ /**
782
+ * Simulate decreaseAllowance
783
+ * Returns gas estimate and result without sending transaction
784
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
785
+ */
786
+ decreaseAllowance(spender: `0x${string}`, subtractedValue: bigint, options?: {
787
+ accessList?: import("viem").AccessList;
788
+ authorizationList?: import("viem").AuthorizationList;
789
+ chain?: import("viem").Chain | null;
790
+ dataSuffix?: `0x${string}`;
791
+ gas?: bigint;
792
+ gasPrice?: bigint;
793
+ maxFeePerGas?: bigint;
794
+ maxPriorityFeePerGas?: bigint;
795
+ nonce?: number;
796
+ value?: bigint;
797
+ }): Promise<boolean>;
798
+ /**
799
+ * Simulate increaseAllowance
800
+ * Returns gas estimate and result without sending transaction
801
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
802
+ */
803
+ increaseAllowance(spender: `0x${string}`, addedValue: bigint, options?: {
804
+ accessList?: import("viem").AccessList;
805
+ authorizationList?: import("viem").AuthorizationList;
806
+ chain?: import("viem").Chain | null;
807
+ dataSuffix?: `0x${string}`;
808
+ gas?: bigint;
809
+ gasPrice?: bigint;
810
+ maxFeePerGas?: bigint;
811
+ maxPriorityFeePerGas?: bigint;
812
+ nonce?: number;
813
+ value?: bigint;
814
+ }): Promise<boolean>;
815
+ /**
816
+ * Simulate mint
817
+ * Returns gas estimate and result without sending transaction
818
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
819
+ */
820
+ mint(_account: `0x${string}`, _amount: bigint, options?: {
821
+ accessList?: import("viem").AccessList;
822
+ authorizationList?: import("viem").AuthorizationList;
823
+ chain?: import("viem").Chain | null;
824
+ dataSuffix?: `0x${string}`;
825
+ gas?: bigint;
826
+ gasPrice?: bigint;
827
+ maxFeePerGas?: bigint;
828
+ maxPriorityFeePerGas?: bigint;
829
+ nonce?: number;
830
+ value?: bigint;
831
+ }): Promise<void>;
832
+ /**
833
+ * Simulate permit
834
+ * Returns gas estimate and result without sending transaction
835
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
836
+ */
837
+ permit(owner: `0x${string}`, spender: `0x${string}`, amount: bigint, deadline: bigint, v: bigint, r: `0x${string}`, s: `0x${string}`, options?: {
838
+ accessList?: import("viem").AccessList;
839
+ authorizationList?: import("viem").AuthorizationList;
840
+ chain?: import("viem").Chain | null;
841
+ dataSuffix?: `0x${string}`;
842
+ gas?: bigint;
843
+ gasPrice?: bigint;
844
+ maxFeePerGas?: bigint;
845
+ maxPriorityFeePerGas?: bigint;
846
+ nonce?: number;
847
+ value?: bigint;
848
+ }): Promise<void>;
849
+ /**
850
+ * Simulate returnFromPool
851
+ * Returns gas estimate and result without sending transaction
852
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
853
+ */
854
+ returnFromPool(_poolAddress: `0x${string}`, _receiver: `0x${string}`, _amount: bigint, options?: {
855
+ accessList?: import("viem").AccessList;
856
+ authorizationList?: import("viem").AuthorizationList;
857
+ chain?: import("viem").Chain | null;
858
+ dataSuffix?: `0x${string}`;
859
+ gas?: bigint;
860
+ gasPrice?: bigint;
861
+ maxFeePerGas?: bigint;
862
+ maxPriorityFeePerGas?: bigint;
863
+ nonce?: number;
864
+ value?: bigint;
865
+ }): Promise<void>;
866
+ /**
867
+ * Simulate sendToPool
868
+ * Returns gas estimate and result without sending transaction
869
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
870
+ */
871
+ sendToPool(_sender: `0x${string}`, _poolAddress: `0x${string}`, _amount: bigint, options?: {
872
+ accessList?: import("viem").AccessList;
873
+ authorizationList?: import("viem").AuthorizationList;
874
+ chain?: import("viem").Chain | null;
875
+ dataSuffix?: `0x${string}`;
876
+ gas?: bigint;
877
+ gasPrice?: bigint;
878
+ maxFeePerGas?: bigint;
879
+ maxPriorityFeePerGas?: bigint;
880
+ nonce?: number;
881
+ value?: bigint;
882
+ }): Promise<void>;
883
+ /**
884
+ * Simulate transfer
885
+ * Returns gas estimate and result without sending transaction
886
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
887
+ */
888
+ transfer(recipient: `0x${string}`, amount: bigint, options?: {
889
+ accessList?: import("viem").AccessList;
890
+ authorizationList?: import("viem").AuthorizationList;
891
+ chain?: import("viem").Chain | null;
892
+ dataSuffix?: `0x${string}`;
893
+ gas?: bigint;
894
+ gasPrice?: bigint;
895
+ maxFeePerGas?: bigint;
896
+ maxPriorityFeePerGas?: bigint;
897
+ nonce?: number;
898
+ value?: bigint;
899
+ }): Promise<boolean>;
900
+ /**
901
+ * Simulate transferFrom
902
+ * Returns gas estimate and result without sending transaction
903
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
904
+ */
905
+ transferFrom(sender: `0x${string}`, recipient: `0x${string}`, amount: bigint, options?: {
906
+ accessList?: import("viem").AccessList;
907
+ authorizationList?: import("viem").AuthorizationList;
908
+ chain?: import("viem").Chain | null;
909
+ dataSuffix?: `0x${string}`;
910
+ gas?: bigint;
911
+ gasPrice?: bigint;
912
+ maxFeePerGas?: bigint;
913
+ maxPriorityFeePerGas?: bigint;
914
+ nonce?: number;
915
+ value?: bigint;
916
+ }): Promise<boolean>;
917
+ };
918
+ /**
919
+ * Watch contract events
920
+ *
921
+ * @example
922
+ * // Watch all Transfer events
923
+ * const unwatch = contract.watch.Transfer((event) => {
924
+ * console.log('Transfer:', event);
925
+ * });
926
+ *
927
+ * // Stop watching
928
+ * unwatch();
929
+ */
930
+ get watch(): {
931
+ /**
932
+ * Watch Approval events
933
+ * @param callback Function to call when event is emitted
934
+ * @param filter Optional filter for indexed parameters
935
+ * @returns Unwatch function to stop listening
936
+ */
937
+ Approval: (callback: (event: {
938
+ owner: `0x${string}`;
939
+ spender: `0x${string}`;
940
+ value: bigint;
941
+ }) => void, filter?: {
942
+ owner?: `0x${string}` | `0x${string}`[] | null;
943
+ spender?: `0x${string}` | `0x${string}`[] | null;
944
+ }) => () => void;
945
+ /**
946
+ * Watch BorrowerOperationsAddressChanged events
947
+ * @param callback Function to call when event is emitted
948
+ * @param filter Optional filter for indexed parameters
949
+ * @returns Unwatch function to stop listening
950
+ */
951
+ BorrowerOperationsAddressChanged: (callback: (event: {
952
+ _newBorrowerOperationsAddress: `0x${string}`;
953
+ }) => void) => () => void;
954
+ /**
955
+ * Watch LUSDTokenBalanceUpdated events
956
+ * @param callback Function to call when event is emitted
957
+ * @param filter Optional filter for indexed parameters
958
+ * @returns Unwatch function to stop listening
959
+ */
960
+ LUSDTokenBalanceUpdated: (callback: (event: {
961
+ _user: `0x${string}`;
962
+ _amount: bigint;
963
+ }) => void) => () => void;
964
+ /**
965
+ * Watch StabilityPoolAddressChanged events
966
+ * @param callback Function to call when event is emitted
967
+ * @param filter Optional filter for indexed parameters
968
+ * @returns Unwatch function to stop listening
969
+ */
970
+ StabilityPoolAddressChanged: (callback: (event: {
971
+ _newStabilityPoolAddress: `0x${string}`;
972
+ }) => void) => () => void;
973
+ /**
974
+ * Watch Transfer events
975
+ * @param callback Function to call when event is emitted
976
+ * @param filter Optional filter for indexed parameters
977
+ * @returns Unwatch function to stop listening
978
+ */
979
+ Transfer: (callback: (event: {
980
+ from: `0x${string}`;
981
+ to: `0x${string}`;
982
+ value: bigint;
983
+ }) => void, filter?: {
984
+ from?: `0x${string}` | `0x${string}`[] | null;
985
+ to?: `0x${string}` | `0x${string}`[] | null;
986
+ }) => () => void;
987
+ /**
988
+ * Watch TroveManagerAddressChanged events
989
+ * @param callback Function to call when event is emitted
990
+ * @param filter Optional filter for indexed parameters
991
+ * @returns Unwatch function to stop listening
992
+ */
993
+ TroveManagerAddressChanged: (callback: (event: {
994
+ _troveManagerAddress: `0x${string}`;
995
+ }) => void) => () => void;
996
+ };
997
+ }