@gitmyabi-stg/usdn 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,1812 @@
1
+ import type { Address, PublicClient, WalletClient } from 'viem';
2
+ /**
3
+ * Usdn ABI
4
+ *
5
+ * This ABI is typed using viem's type system for full type safety.
6
+ */
7
+ export declare const UsdnAbi: readonly [{
8
+ readonly inputs: readonly [{
9
+ readonly internalType: "address";
10
+ readonly name: "minter";
11
+ readonly type: "address";
12
+ }, {
13
+ readonly internalType: "address";
14
+ readonly name: "rebaser";
15
+ readonly type: "address";
16
+ }];
17
+ readonly stateMutability: "nonpayable";
18
+ readonly type: "constructor";
19
+ }, {
20
+ readonly inputs: readonly [];
21
+ readonly name: "AccessControlBadConfirmation";
22
+ readonly type: "error";
23
+ }, {
24
+ readonly inputs: readonly [{
25
+ readonly internalType: "address";
26
+ readonly name: "account";
27
+ readonly type: "address";
28
+ }, {
29
+ readonly internalType: "bytes32";
30
+ readonly name: "neededRole";
31
+ readonly type: "bytes32";
32
+ }];
33
+ readonly name: "AccessControlUnauthorizedAccount";
34
+ readonly type: "error";
35
+ }, {
36
+ readonly inputs: readonly [];
37
+ readonly name: "ECDSAInvalidSignature";
38
+ readonly type: "error";
39
+ }, {
40
+ readonly inputs: readonly [{
41
+ readonly internalType: "uint256";
42
+ readonly name: "length";
43
+ readonly type: "uint256";
44
+ }];
45
+ readonly name: "ECDSAInvalidSignatureLength";
46
+ readonly type: "error";
47
+ }, {
48
+ readonly inputs: readonly [{
49
+ readonly internalType: "bytes32";
50
+ readonly name: "s";
51
+ readonly type: "bytes32";
52
+ }];
53
+ readonly name: "ECDSAInvalidSignatureS";
54
+ readonly type: "error";
55
+ }, {
56
+ readonly inputs: readonly [{
57
+ readonly internalType: "address";
58
+ readonly name: "spender";
59
+ readonly type: "address";
60
+ }, {
61
+ readonly internalType: "uint256";
62
+ readonly name: "allowance";
63
+ readonly type: "uint256";
64
+ }, {
65
+ readonly internalType: "uint256";
66
+ readonly name: "needed";
67
+ readonly type: "uint256";
68
+ }];
69
+ readonly name: "ERC20InsufficientAllowance";
70
+ readonly type: "error";
71
+ }, {
72
+ readonly inputs: readonly [{
73
+ readonly internalType: "address";
74
+ readonly name: "sender";
75
+ readonly type: "address";
76
+ }, {
77
+ readonly internalType: "uint256";
78
+ readonly name: "balance";
79
+ readonly type: "uint256";
80
+ }, {
81
+ readonly internalType: "uint256";
82
+ readonly name: "needed";
83
+ readonly type: "uint256";
84
+ }];
85
+ readonly name: "ERC20InsufficientBalance";
86
+ readonly type: "error";
87
+ }, {
88
+ readonly inputs: readonly [{
89
+ readonly internalType: "address";
90
+ readonly name: "approver";
91
+ readonly type: "address";
92
+ }];
93
+ readonly name: "ERC20InvalidApprover";
94
+ readonly type: "error";
95
+ }, {
96
+ readonly inputs: readonly [{
97
+ readonly internalType: "address";
98
+ readonly name: "receiver";
99
+ readonly type: "address";
100
+ }];
101
+ readonly name: "ERC20InvalidReceiver";
102
+ readonly type: "error";
103
+ }, {
104
+ readonly inputs: readonly [{
105
+ readonly internalType: "address";
106
+ readonly name: "sender";
107
+ readonly type: "address";
108
+ }];
109
+ readonly name: "ERC20InvalidSender";
110
+ readonly type: "error";
111
+ }, {
112
+ readonly inputs: readonly [{
113
+ readonly internalType: "address";
114
+ readonly name: "spender";
115
+ readonly type: "address";
116
+ }];
117
+ readonly name: "ERC20InvalidSpender";
118
+ readonly type: "error";
119
+ }, {
120
+ readonly inputs: readonly [{
121
+ readonly internalType: "uint256";
122
+ readonly name: "deadline";
123
+ readonly type: "uint256";
124
+ }];
125
+ readonly name: "ERC2612ExpiredSignature";
126
+ readonly type: "error";
127
+ }, {
128
+ readonly inputs: readonly [{
129
+ readonly internalType: "address";
130
+ readonly name: "signer";
131
+ readonly type: "address";
132
+ }, {
133
+ readonly internalType: "address";
134
+ readonly name: "owner";
135
+ readonly type: "address";
136
+ }];
137
+ readonly name: "ERC2612InvalidSigner";
138
+ readonly type: "error";
139
+ }, {
140
+ readonly inputs: readonly [{
141
+ readonly internalType: "address";
142
+ readonly name: "account";
143
+ readonly type: "address";
144
+ }, {
145
+ readonly internalType: "uint256";
146
+ readonly name: "currentNonce";
147
+ readonly type: "uint256";
148
+ }];
149
+ readonly name: "InvalidAccountNonce";
150
+ readonly type: "error";
151
+ }, {
152
+ readonly inputs: readonly [];
153
+ readonly name: "InvalidShortString";
154
+ readonly type: "error";
155
+ }, {
156
+ readonly inputs: readonly [{
157
+ readonly internalType: "string";
158
+ readonly name: "str";
159
+ readonly type: "string";
160
+ }];
161
+ readonly name: "StringTooLong";
162
+ readonly type: "error";
163
+ }, {
164
+ readonly inputs: readonly [{
165
+ readonly internalType: "address";
166
+ readonly name: "sender";
167
+ readonly type: "address";
168
+ }, {
169
+ readonly internalType: "uint256";
170
+ readonly name: "balance";
171
+ readonly type: "uint256";
172
+ }, {
173
+ readonly internalType: "uint256";
174
+ readonly name: "needed";
175
+ readonly type: "uint256";
176
+ }];
177
+ readonly name: "UsdnInsufficientSharesBalance";
178
+ readonly type: "error";
179
+ }, {
180
+ readonly inputs: readonly [];
181
+ readonly name: "UsdnInvalidDivisor";
182
+ readonly type: "error";
183
+ }, {
184
+ readonly inputs: readonly [{
185
+ readonly internalType: "uint256";
186
+ readonly name: "value";
187
+ readonly type: "uint256";
188
+ }];
189
+ readonly name: "UsdnMaxTokensExceeded";
190
+ readonly type: "error";
191
+ }, {
192
+ readonly anonymous: false;
193
+ readonly inputs: readonly [{
194
+ readonly indexed: true;
195
+ readonly internalType: "address";
196
+ readonly name: "owner";
197
+ readonly type: "address";
198
+ }, {
199
+ readonly indexed: true;
200
+ readonly internalType: "address";
201
+ readonly name: "spender";
202
+ readonly type: "address";
203
+ }, {
204
+ readonly indexed: false;
205
+ readonly internalType: "uint256";
206
+ readonly name: "value";
207
+ readonly type: "uint256";
208
+ }];
209
+ readonly name: "Approval";
210
+ readonly type: "event";
211
+ }, {
212
+ readonly anonymous: false;
213
+ readonly inputs: readonly [];
214
+ readonly name: "EIP712DomainChanged";
215
+ readonly type: "event";
216
+ }, {
217
+ readonly anonymous: false;
218
+ readonly inputs: readonly [{
219
+ readonly indexed: false;
220
+ readonly internalType: "uint256";
221
+ readonly name: "oldDivisor";
222
+ readonly type: "uint256";
223
+ }, {
224
+ readonly indexed: false;
225
+ readonly internalType: "uint256";
226
+ readonly name: "newDivisor";
227
+ readonly type: "uint256";
228
+ }];
229
+ readonly name: "Rebase";
230
+ readonly type: "event";
231
+ }, {
232
+ readonly anonymous: false;
233
+ readonly inputs: readonly [{
234
+ readonly indexed: false;
235
+ readonly internalType: "contract IRebaseCallback";
236
+ readonly name: "newHandler";
237
+ readonly type: "address";
238
+ }];
239
+ readonly name: "RebaseHandlerUpdated";
240
+ readonly type: "event";
241
+ }, {
242
+ readonly anonymous: false;
243
+ readonly inputs: readonly [{
244
+ readonly indexed: true;
245
+ readonly internalType: "bytes32";
246
+ readonly name: "role";
247
+ readonly type: "bytes32";
248
+ }, {
249
+ readonly indexed: true;
250
+ readonly internalType: "bytes32";
251
+ readonly name: "previousAdminRole";
252
+ readonly type: "bytes32";
253
+ }, {
254
+ readonly indexed: true;
255
+ readonly internalType: "bytes32";
256
+ readonly name: "newAdminRole";
257
+ readonly type: "bytes32";
258
+ }];
259
+ readonly name: "RoleAdminChanged";
260
+ readonly type: "event";
261
+ }, {
262
+ readonly anonymous: false;
263
+ readonly inputs: readonly [{
264
+ readonly indexed: true;
265
+ readonly internalType: "bytes32";
266
+ readonly name: "role";
267
+ readonly type: "bytes32";
268
+ }, {
269
+ readonly indexed: true;
270
+ readonly internalType: "address";
271
+ readonly name: "account";
272
+ readonly type: "address";
273
+ }, {
274
+ readonly indexed: true;
275
+ readonly internalType: "address";
276
+ readonly name: "sender";
277
+ readonly type: "address";
278
+ }];
279
+ readonly name: "RoleGranted";
280
+ readonly type: "event";
281
+ }, {
282
+ readonly anonymous: false;
283
+ readonly inputs: readonly [{
284
+ readonly indexed: true;
285
+ readonly internalType: "bytes32";
286
+ readonly name: "role";
287
+ readonly type: "bytes32";
288
+ }, {
289
+ readonly indexed: true;
290
+ readonly internalType: "address";
291
+ readonly name: "account";
292
+ readonly type: "address";
293
+ }, {
294
+ readonly indexed: true;
295
+ readonly internalType: "address";
296
+ readonly name: "sender";
297
+ readonly type: "address";
298
+ }];
299
+ readonly name: "RoleRevoked";
300
+ readonly type: "event";
301
+ }, {
302
+ readonly anonymous: false;
303
+ readonly inputs: readonly [{
304
+ readonly indexed: true;
305
+ readonly internalType: "address";
306
+ readonly name: "from";
307
+ readonly type: "address";
308
+ }, {
309
+ readonly indexed: true;
310
+ readonly internalType: "address";
311
+ readonly name: "to";
312
+ readonly type: "address";
313
+ }, {
314
+ readonly indexed: false;
315
+ readonly internalType: "uint256";
316
+ readonly name: "value";
317
+ readonly type: "uint256";
318
+ }];
319
+ readonly name: "Transfer";
320
+ readonly type: "event";
321
+ }, {
322
+ readonly inputs: readonly [];
323
+ readonly name: "DEFAULT_ADMIN_ROLE";
324
+ readonly outputs: readonly [{
325
+ readonly internalType: "bytes32";
326
+ readonly name: "";
327
+ readonly type: "bytes32";
328
+ }];
329
+ readonly stateMutability: "view";
330
+ readonly type: "function";
331
+ }, {
332
+ readonly inputs: readonly [];
333
+ readonly name: "DOMAIN_SEPARATOR";
334
+ readonly outputs: readonly [{
335
+ readonly internalType: "bytes32";
336
+ readonly name: "";
337
+ readonly type: "bytes32";
338
+ }];
339
+ readonly stateMutability: "view";
340
+ readonly type: "function";
341
+ }, {
342
+ readonly inputs: readonly [];
343
+ readonly name: "MAX_DIVISOR";
344
+ readonly outputs: readonly [{
345
+ readonly internalType: "uint256";
346
+ readonly name: "";
347
+ readonly type: "uint256";
348
+ }];
349
+ readonly stateMutability: "view";
350
+ readonly type: "function";
351
+ }, {
352
+ readonly inputs: readonly [];
353
+ readonly name: "MINTER_ROLE";
354
+ readonly outputs: readonly [{
355
+ readonly internalType: "bytes32";
356
+ readonly name: "";
357
+ readonly type: "bytes32";
358
+ }];
359
+ readonly stateMutability: "view";
360
+ readonly type: "function";
361
+ }, {
362
+ readonly inputs: readonly [];
363
+ readonly name: "MIN_DIVISOR";
364
+ readonly outputs: readonly [{
365
+ readonly internalType: "uint256";
366
+ readonly name: "";
367
+ readonly type: "uint256";
368
+ }];
369
+ readonly stateMutability: "view";
370
+ readonly type: "function";
371
+ }, {
372
+ readonly inputs: readonly [];
373
+ readonly name: "REBASER_ROLE";
374
+ readonly outputs: readonly [{
375
+ readonly internalType: "bytes32";
376
+ readonly name: "";
377
+ readonly type: "bytes32";
378
+ }];
379
+ readonly stateMutability: "view";
380
+ readonly type: "function";
381
+ }, {
382
+ readonly inputs: readonly [{
383
+ readonly internalType: "address";
384
+ readonly name: "owner";
385
+ readonly type: "address";
386
+ }, {
387
+ readonly internalType: "address";
388
+ readonly name: "spender";
389
+ readonly type: "address";
390
+ }];
391
+ readonly name: "allowance";
392
+ readonly outputs: readonly [{
393
+ readonly internalType: "uint256";
394
+ readonly name: "";
395
+ readonly type: "uint256";
396
+ }];
397
+ readonly stateMutability: "view";
398
+ readonly type: "function";
399
+ }, {
400
+ readonly inputs: readonly [{
401
+ readonly internalType: "address";
402
+ readonly name: "spender";
403
+ readonly type: "address";
404
+ }, {
405
+ readonly internalType: "uint256";
406
+ readonly name: "value";
407
+ readonly type: "uint256";
408
+ }];
409
+ readonly name: "approve";
410
+ readonly outputs: readonly [{
411
+ readonly internalType: "bool";
412
+ readonly name: "";
413
+ readonly type: "bool";
414
+ }];
415
+ readonly stateMutability: "nonpayable";
416
+ readonly type: "function";
417
+ }, {
418
+ readonly inputs: readonly [{
419
+ readonly internalType: "address";
420
+ readonly name: "account";
421
+ readonly type: "address";
422
+ }];
423
+ readonly name: "balanceOf";
424
+ readonly outputs: readonly [{
425
+ readonly internalType: "uint256";
426
+ readonly name: "balance_";
427
+ readonly type: "uint256";
428
+ }];
429
+ readonly stateMutability: "view";
430
+ readonly type: "function";
431
+ }, {
432
+ readonly inputs: readonly [{
433
+ readonly internalType: "uint256";
434
+ readonly name: "value";
435
+ readonly type: "uint256";
436
+ }];
437
+ readonly name: "burn";
438
+ readonly outputs: readonly [];
439
+ readonly stateMutability: "nonpayable";
440
+ readonly type: "function";
441
+ }, {
442
+ readonly inputs: readonly [{
443
+ readonly internalType: "address";
444
+ readonly name: "account";
445
+ readonly type: "address";
446
+ }, {
447
+ readonly internalType: "uint256";
448
+ readonly name: "value";
449
+ readonly type: "uint256";
450
+ }];
451
+ readonly name: "burnFrom";
452
+ readonly outputs: readonly [];
453
+ readonly stateMutability: "nonpayable";
454
+ readonly type: "function";
455
+ }, {
456
+ readonly inputs: readonly [{
457
+ readonly internalType: "uint256";
458
+ readonly name: "value";
459
+ readonly type: "uint256";
460
+ }];
461
+ readonly name: "burnShares";
462
+ readonly outputs: readonly [];
463
+ readonly stateMutability: "nonpayable";
464
+ readonly type: "function";
465
+ }, {
466
+ readonly inputs: readonly [{
467
+ readonly internalType: "address";
468
+ readonly name: "account";
469
+ readonly type: "address";
470
+ }, {
471
+ readonly internalType: "uint256";
472
+ readonly name: "value";
473
+ readonly type: "uint256";
474
+ }];
475
+ readonly name: "burnSharesFrom";
476
+ readonly outputs: readonly [];
477
+ readonly stateMutability: "nonpayable";
478
+ readonly type: "function";
479
+ }, {
480
+ readonly inputs: readonly [{
481
+ readonly internalType: "uint256";
482
+ readonly name: "amountTokens";
483
+ readonly type: "uint256";
484
+ }];
485
+ readonly name: "convertToShares";
486
+ readonly outputs: readonly [{
487
+ readonly internalType: "uint256";
488
+ readonly name: "shares_";
489
+ readonly type: "uint256";
490
+ }];
491
+ readonly stateMutability: "view";
492
+ readonly type: "function";
493
+ }, {
494
+ readonly inputs: readonly [{
495
+ readonly internalType: "uint256";
496
+ readonly name: "amountShares";
497
+ readonly type: "uint256";
498
+ }];
499
+ readonly name: "convertToTokens";
500
+ readonly outputs: readonly [{
501
+ readonly internalType: "uint256";
502
+ readonly name: "tokens_";
503
+ readonly type: "uint256";
504
+ }];
505
+ readonly stateMutability: "view";
506
+ readonly type: "function";
507
+ }, {
508
+ readonly inputs: readonly [{
509
+ readonly internalType: "uint256";
510
+ readonly name: "amountShares";
511
+ readonly type: "uint256";
512
+ }];
513
+ readonly name: "convertToTokensRoundUp";
514
+ readonly outputs: readonly [{
515
+ readonly internalType: "uint256";
516
+ readonly name: "tokens_";
517
+ readonly type: "uint256";
518
+ }];
519
+ readonly stateMutability: "view";
520
+ readonly type: "function";
521
+ }, {
522
+ readonly inputs: readonly [];
523
+ readonly name: "decimals";
524
+ readonly outputs: readonly [{
525
+ readonly internalType: "uint8";
526
+ readonly name: "";
527
+ readonly type: "uint8";
528
+ }];
529
+ readonly stateMutability: "view";
530
+ readonly type: "function";
531
+ }, {
532
+ readonly inputs: readonly [];
533
+ readonly name: "divisor";
534
+ readonly outputs: readonly [{
535
+ readonly internalType: "uint256";
536
+ readonly name: "divisor_";
537
+ readonly type: "uint256";
538
+ }];
539
+ readonly stateMutability: "view";
540
+ readonly type: "function";
541
+ }, {
542
+ readonly inputs: readonly [];
543
+ readonly name: "eip712Domain";
544
+ readonly outputs: readonly [{
545
+ readonly internalType: "bytes1";
546
+ readonly name: "fields";
547
+ readonly type: "bytes1";
548
+ }, {
549
+ readonly internalType: "string";
550
+ readonly name: "name";
551
+ readonly type: "string";
552
+ }, {
553
+ readonly internalType: "string";
554
+ readonly name: "version";
555
+ readonly type: "string";
556
+ }, {
557
+ readonly internalType: "uint256";
558
+ readonly name: "chainId";
559
+ readonly type: "uint256";
560
+ }, {
561
+ readonly internalType: "address";
562
+ readonly name: "verifyingContract";
563
+ readonly type: "address";
564
+ }, {
565
+ readonly internalType: "bytes32";
566
+ readonly name: "salt";
567
+ readonly type: "bytes32";
568
+ }, {
569
+ readonly internalType: "uint256[]";
570
+ readonly name: "extensions";
571
+ readonly type: "uint256[]";
572
+ }];
573
+ readonly stateMutability: "view";
574
+ readonly type: "function";
575
+ }, {
576
+ readonly inputs: readonly [{
577
+ readonly internalType: "bytes32";
578
+ readonly name: "role";
579
+ readonly type: "bytes32";
580
+ }];
581
+ readonly name: "getRoleAdmin";
582
+ readonly outputs: readonly [{
583
+ readonly internalType: "bytes32";
584
+ readonly name: "";
585
+ readonly type: "bytes32";
586
+ }];
587
+ readonly stateMutability: "view";
588
+ readonly type: "function";
589
+ }, {
590
+ readonly inputs: readonly [{
591
+ readonly internalType: "bytes32";
592
+ readonly name: "role";
593
+ readonly type: "bytes32";
594
+ }, {
595
+ readonly internalType: "address";
596
+ readonly name: "account";
597
+ readonly type: "address";
598
+ }];
599
+ readonly name: "grantRole";
600
+ readonly outputs: readonly [];
601
+ readonly stateMutability: "nonpayable";
602
+ readonly type: "function";
603
+ }, {
604
+ readonly inputs: readonly [{
605
+ readonly internalType: "bytes32";
606
+ readonly name: "role";
607
+ readonly type: "bytes32";
608
+ }, {
609
+ readonly internalType: "address";
610
+ readonly name: "account";
611
+ readonly type: "address";
612
+ }];
613
+ readonly name: "hasRole";
614
+ readonly outputs: readonly [{
615
+ readonly internalType: "bool";
616
+ readonly name: "";
617
+ readonly type: "bool";
618
+ }];
619
+ readonly stateMutability: "view";
620
+ readonly type: "function";
621
+ }, {
622
+ readonly inputs: readonly [];
623
+ readonly name: "maxTokens";
624
+ readonly outputs: readonly [{
625
+ readonly internalType: "uint256";
626
+ readonly name: "maxTokens_";
627
+ readonly type: "uint256";
628
+ }];
629
+ readonly stateMutability: "view";
630
+ readonly type: "function";
631
+ }, {
632
+ readonly inputs: readonly [{
633
+ readonly internalType: "address";
634
+ readonly name: "to";
635
+ readonly type: "address";
636
+ }, {
637
+ readonly internalType: "uint256";
638
+ readonly name: "amount";
639
+ readonly type: "uint256";
640
+ }];
641
+ readonly name: "mint";
642
+ readonly outputs: readonly [];
643
+ readonly stateMutability: "nonpayable";
644
+ readonly type: "function";
645
+ }, {
646
+ readonly inputs: readonly [{
647
+ readonly internalType: "address";
648
+ readonly name: "to";
649
+ readonly type: "address";
650
+ }, {
651
+ readonly internalType: "uint256";
652
+ readonly name: "amount";
653
+ readonly type: "uint256";
654
+ }];
655
+ readonly name: "mintShares";
656
+ readonly outputs: readonly [{
657
+ readonly internalType: "uint256";
658
+ readonly name: "mintedTokens_";
659
+ readonly type: "uint256";
660
+ }];
661
+ readonly stateMutability: "nonpayable";
662
+ readonly type: "function";
663
+ }, {
664
+ readonly inputs: readonly [];
665
+ readonly name: "name";
666
+ readonly outputs: readonly [{
667
+ readonly internalType: "string";
668
+ readonly name: "";
669
+ readonly type: "string";
670
+ }];
671
+ readonly stateMutability: "view";
672
+ readonly type: "function";
673
+ }, {
674
+ readonly inputs: readonly [{
675
+ readonly internalType: "address";
676
+ readonly name: "owner";
677
+ readonly type: "address";
678
+ }];
679
+ readonly name: "nonces";
680
+ readonly outputs: readonly [{
681
+ readonly internalType: "uint256";
682
+ readonly name: "";
683
+ readonly type: "uint256";
684
+ }];
685
+ readonly stateMutability: "view";
686
+ readonly type: "function";
687
+ }, {
688
+ readonly inputs: readonly [{
689
+ readonly internalType: "address";
690
+ readonly name: "owner";
691
+ readonly type: "address";
692
+ }, {
693
+ readonly internalType: "address";
694
+ readonly name: "spender";
695
+ readonly type: "address";
696
+ }, {
697
+ readonly internalType: "uint256";
698
+ readonly name: "value";
699
+ readonly type: "uint256";
700
+ }, {
701
+ readonly internalType: "uint256";
702
+ readonly name: "deadline";
703
+ readonly type: "uint256";
704
+ }, {
705
+ readonly internalType: "uint8";
706
+ readonly name: "v";
707
+ readonly type: "uint8";
708
+ }, {
709
+ readonly internalType: "bytes32";
710
+ readonly name: "r";
711
+ readonly type: "bytes32";
712
+ }, {
713
+ readonly internalType: "bytes32";
714
+ readonly name: "s";
715
+ readonly type: "bytes32";
716
+ }];
717
+ readonly name: "permit";
718
+ readonly outputs: readonly [];
719
+ readonly stateMutability: "nonpayable";
720
+ readonly type: "function";
721
+ }, {
722
+ readonly inputs: readonly [{
723
+ readonly internalType: "uint256";
724
+ readonly name: "newDivisor";
725
+ readonly type: "uint256";
726
+ }];
727
+ readonly name: "rebase";
728
+ readonly outputs: readonly [{
729
+ readonly internalType: "bool";
730
+ readonly name: "rebased_";
731
+ readonly type: "bool";
732
+ }, {
733
+ readonly internalType: "uint256";
734
+ readonly name: "oldDivisor_";
735
+ readonly type: "uint256";
736
+ }, {
737
+ readonly internalType: "bytes";
738
+ readonly name: "callbackResult_";
739
+ readonly type: "bytes";
740
+ }];
741
+ readonly stateMutability: "nonpayable";
742
+ readonly type: "function";
743
+ }, {
744
+ readonly inputs: readonly [];
745
+ readonly name: "rebaseHandler";
746
+ readonly outputs: readonly [{
747
+ readonly internalType: "contract IRebaseCallback";
748
+ readonly name: "rebaseHandler_";
749
+ readonly type: "address";
750
+ }];
751
+ readonly stateMutability: "view";
752
+ readonly type: "function";
753
+ }, {
754
+ readonly inputs: readonly [{
755
+ readonly internalType: "bytes32";
756
+ readonly name: "role";
757
+ readonly type: "bytes32";
758
+ }, {
759
+ readonly internalType: "address";
760
+ readonly name: "callerConfirmation";
761
+ readonly type: "address";
762
+ }];
763
+ readonly name: "renounceRole";
764
+ readonly outputs: readonly [];
765
+ readonly stateMutability: "nonpayable";
766
+ readonly type: "function";
767
+ }, {
768
+ readonly inputs: readonly [{
769
+ readonly internalType: "bytes32";
770
+ readonly name: "role";
771
+ readonly type: "bytes32";
772
+ }, {
773
+ readonly internalType: "address";
774
+ readonly name: "account";
775
+ readonly type: "address";
776
+ }];
777
+ readonly name: "revokeRole";
778
+ readonly outputs: readonly [];
779
+ readonly stateMutability: "nonpayable";
780
+ readonly type: "function";
781
+ }, {
782
+ readonly inputs: readonly [{
783
+ readonly internalType: "contract IRebaseCallback";
784
+ readonly name: "newHandler";
785
+ readonly type: "address";
786
+ }];
787
+ readonly name: "setRebaseHandler";
788
+ readonly outputs: readonly [];
789
+ readonly stateMutability: "nonpayable";
790
+ readonly type: "function";
791
+ }, {
792
+ readonly inputs: readonly [{
793
+ readonly internalType: "address";
794
+ readonly name: "account";
795
+ readonly type: "address";
796
+ }];
797
+ readonly name: "sharesOf";
798
+ readonly outputs: readonly [{
799
+ readonly internalType: "uint256";
800
+ readonly name: "shares_";
801
+ readonly type: "uint256";
802
+ }];
803
+ readonly stateMutability: "view";
804
+ readonly type: "function";
805
+ }, {
806
+ readonly inputs: readonly [{
807
+ readonly internalType: "bytes4";
808
+ readonly name: "interfaceId";
809
+ readonly type: "bytes4";
810
+ }];
811
+ readonly name: "supportsInterface";
812
+ readonly outputs: readonly [{
813
+ readonly internalType: "bool";
814
+ readonly name: "";
815
+ readonly type: "bool";
816
+ }];
817
+ readonly stateMutability: "view";
818
+ readonly type: "function";
819
+ }, {
820
+ readonly inputs: readonly [];
821
+ readonly name: "symbol";
822
+ readonly outputs: readonly [{
823
+ readonly internalType: "string";
824
+ readonly name: "";
825
+ readonly type: "string";
826
+ }];
827
+ readonly stateMutability: "view";
828
+ readonly type: "function";
829
+ }, {
830
+ readonly inputs: readonly [];
831
+ readonly name: "totalShares";
832
+ readonly outputs: readonly [{
833
+ readonly internalType: "uint256";
834
+ readonly name: "shares_";
835
+ readonly type: "uint256";
836
+ }];
837
+ readonly stateMutability: "view";
838
+ readonly type: "function";
839
+ }, {
840
+ readonly inputs: readonly [];
841
+ readonly name: "totalSupply";
842
+ readonly outputs: readonly [{
843
+ readonly internalType: "uint256";
844
+ readonly name: "totalSupply_";
845
+ readonly type: "uint256";
846
+ }];
847
+ readonly stateMutability: "view";
848
+ readonly type: "function";
849
+ }, {
850
+ readonly inputs: readonly [{
851
+ readonly internalType: "address";
852
+ readonly name: "to";
853
+ readonly type: "address";
854
+ }, {
855
+ readonly internalType: "uint256";
856
+ readonly name: "value";
857
+ readonly type: "uint256";
858
+ }];
859
+ readonly name: "transfer";
860
+ readonly outputs: readonly [{
861
+ readonly internalType: "bool";
862
+ readonly name: "";
863
+ readonly type: "bool";
864
+ }];
865
+ readonly stateMutability: "nonpayable";
866
+ readonly type: "function";
867
+ }, {
868
+ readonly inputs: readonly [{
869
+ readonly internalType: "address";
870
+ readonly name: "from";
871
+ readonly type: "address";
872
+ }, {
873
+ readonly internalType: "address";
874
+ readonly name: "to";
875
+ readonly type: "address";
876
+ }, {
877
+ readonly internalType: "uint256";
878
+ readonly name: "value";
879
+ readonly type: "uint256";
880
+ }];
881
+ readonly name: "transferFrom";
882
+ readonly outputs: readonly [{
883
+ readonly internalType: "bool";
884
+ readonly name: "";
885
+ readonly type: "bool";
886
+ }];
887
+ readonly stateMutability: "nonpayable";
888
+ readonly type: "function";
889
+ }, {
890
+ readonly inputs: readonly [{
891
+ readonly internalType: "address";
892
+ readonly name: "to";
893
+ readonly type: "address";
894
+ }, {
895
+ readonly internalType: "uint256";
896
+ readonly name: "value";
897
+ readonly type: "uint256";
898
+ }];
899
+ readonly name: "transferShares";
900
+ readonly outputs: readonly [{
901
+ readonly internalType: "bool";
902
+ readonly name: "success_";
903
+ readonly type: "bool";
904
+ }];
905
+ readonly stateMutability: "nonpayable";
906
+ readonly type: "function";
907
+ }, {
908
+ readonly inputs: readonly [{
909
+ readonly internalType: "address";
910
+ readonly name: "from";
911
+ readonly type: "address";
912
+ }, {
913
+ readonly internalType: "address";
914
+ readonly name: "to";
915
+ readonly type: "address";
916
+ }, {
917
+ readonly internalType: "uint256";
918
+ readonly name: "value";
919
+ readonly type: "uint256";
920
+ }];
921
+ readonly name: "transferSharesFrom";
922
+ readonly outputs: readonly [{
923
+ readonly internalType: "bool";
924
+ readonly name: "success_";
925
+ readonly type: "bool";
926
+ }];
927
+ readonly stateMutability: "nonpayable";
928
+ readonly type: "function";
929
+ }];
930
+ /**
931
+ * Type-safe ABI for Usdn
932
+ */
933
+ export type UsdnAbi = typeof UsdnAbi;
934
+ /**
935
+ * Contract instance type for Usdn
936
+ */
937
+ export type UsdnContract = any;
938
+ /**
939
+ * Usdn Contract Class
940
+ *
941
+ * Provides a class-based API similar to TypeChain for interacting with the contract.
942
+ *
943
+ * @example
944
+ * ```typescript
945
+ * import { createPublicClient, createWalletClient, http } from 'viem';
946
+ * import { mainnet } from 'viem/chains';
947
+ * import { Usdn } from 'Usdn';
948
+ *
949
+ * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
950
+ * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
951
+ *
952
+ * const contract = new Usdn('0x...', { publicClient, walletClient });
953
+ *
954
+ * // Read functions
955
+ * const result = await contract.balanceOf('0x...');
956
+ *
957
+ * // Write functions
958
+ * const hash = await contract.transfer('0x...', 1000n);
959
+ *
960
+ * // Simulate transactions (dry-run)
961
+ * const simulation = await contract.simulate.transfer('0x...', 1000n);
962
+ * console.log('Gas estimate:', simulation.request.gas);
963
+ *
964
+ * // Watch events
965
+ * const unwatch = contract.watch.Transfer((event) => {
966
+ * console.log('Transfer event:', event);
967
+ * });
968
+ * ```
969
+ */
970
+ export declare class Usdn {
971
+ private contract;
972
+ private contractAddress;
973
+ private publicClient;
974
+ constructor(address: Address, clients: {
975
+ publicClient: PublicClient;
976
+ walletClient?: WalletClient;
977
+ });
978
+ /**
979
+ * Get the contract address
980
+ */
981
+ get address(): Address;
982
+ /**
983
+ * Get the underlying viem contract instance.
984
+ */
985
+ getContract(): UsdnContract;
986
+ /**
987
+ * DEFAULT_ADMIN_ROLE
988
+ * view
989
+ */
990
+ DEFAULT_ADMIN_ROLE(): Promise<`0x${string}`>;
991
+ /**
992
+ * DOMAIN_SEPARATOR
993
+ * view
994
+ */
995
+ DOMAIN_SEPARATOR(): Promise<`0x${string}`>;
996
+ /**
997
+ * MAX_DIVISOR
998
+ * view
999
+ */
1000
+ MAX_DIVISOR(): Promise<bigint>;
1001
+ /**
1002
+ * MINTER_ROLE
1003
+ * view
1004
+ */
1005
+ MINTER_ROLE(): Promise<`0x${string}`>;
1006
+ /**
1007
+ * MIN_DIVISOR
1008
+ * view
1009
+ */
1010
+ MIN_DIVISOR(): Promise<bigint>;
1011
+ /**
1012
+ * REBASER_ROLE
1013
+ * view
1014
+ */
1015
+ REBASER_ROLE(): Promise<`0x${string}`>;
1016
+ /**
1017
+ * allowance
1018
+ * view
1019
+ */
1020
+ allowance(owner: `0x${string}`, spender: `0x${string}`): Promise<bigint>;
1021
+ /**
1022
+ * balanceOf
1023
+ * view
1024
+ */
1025
+ balanceOf(account: `0x${string}`): Promise<bigint>;
1026
+ /**
1027
+ * convertToShares
1028
+ * view
1029
+ */
1030
+ convertToShares(amountTokens: bigint): Promise<bigint>;
1031
+ /**
1032
+ * convertToTokens
1033
+ * view
1034
+ */
1035
+ convertToTokens(amountShares: bigint): Promise<bigint>;
1036
+ /**
1037
+ * convertToTokensRoundUp
1038
+ * view
1039
+ */
1040
+ convertToTokensRoundUp(amountShares: bigint): Promise<bigint>;
1041
+ /**
1042
+ * decimals
1043
+ * view
1044
+ */
1045
+ decimals(): Promise<bigint>;
1046
+ /**
1047
+ * divisor
1048
+ * view
1049
+ */
1050
+ divisor(): Promise<bigint>;
1051
+ /**
1052
+ * eip712Domain
1053
+ * view
1054
+ */
1055
+ eip712Domain(): Promise<[`0x${string}`, string, string, bigint, `0x${string}`, `0x${string}`, bigint[]]>;
1056
+ /**
1057
+ * getRoleAdmin
1058
+ * view
1059
+ */
1060
+ getRoleAdmin(role: `0x${string}`): Promise<`0x${string}`>;
1061
+ /**
1062
+ * hasRole
1063
+ * view
1064
+ */
1065
+ hasRole(role: `0x${string}`, account: `0x${string}`): Promise<boolean>;
1066
+ /**
1067
+ * maxTokens
1068
+ * view
1069
+ */
1070
+ maxTokens(): Promise<bigint>;
1071
+ /**
1072
+ * name
1073
+ * view
1074
+ */
1075
+ name(): Promise<string>;
1076
+ /**
1077
+ * nonces
1078
+ * view
1079
+ */
1080
+ nonces(owner: `0x${string}`): Promise<bigint>;
1081
+ /**
1082
+ * rebaseHandler
1083
+ * view
1084
+ */
1085
+ rebaseHandler(): Promise<`0x${string}`>;
1086
+ /**
1087
+ * sharesOf
1088
+ * view
1089
+ */
1090
+ sharesOf(account: `0x${string}`): Promise<bigint>;
1091
+ /**
1092
+ * supportsInterface
1093
+ * view
1094
+ */
1095
+ supportsInterface(interfaceId: `0x${string}`): Promise<boolean>;
1096
+ /**
1097
+ * symbol
1098
+ * view
1099
+ */
1100
+ symbol(): Promise<string>;
1101
+ /**
1102
+ * totalShares
1103
+ * view
1104
+ */
1105
+ totalShares(): Promise<bigint>;
1106
+ /**
1107
+ * totalSupply
1108
+ * view
1109
+ */
1110
+ totalSupply(): Promise<bigint>;
1111
+ /**
1112
+ * approve
1113
+ * nonpayable
1114
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1115
+ */
1116
+ approve(spender: `0x${string}`, value: bigint, options?: {
1117
+ accessList?: import('viem').AccessList;
1118
+ authorizationList?: import('viem').AuthorizationList;
1119
+ chain?: import('viem').Chain | null;
1120
+ dataSuffix?: `0x${string}`;
1121
+ gas?: bigint;
1122
+ gasPrice?: bigint;
1123
+ maxFeePerGas?: bigint;
1124
+ maxPriorityFeePerGas?: bigint;
1125
+ nonce?: number;
1126
+ value?: bigint;
1127
+ }): Promise<`0x${string}`>;
1128
+ /**
1129
+ * burn
1130
+ * nonpayable
1131
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1132
+ */
1133
+ burn(value: bigint, options?: {
1134
+ accessList?: import('viem').AccessList;
1135
+ authorizationList?: import('viem').AuthorizationList;
1136
+ chain?: import('viem').Chain | null;
1137
+ dataSuffix?: `0x${string}`;
1138
+ gas?: bigint;
1139
+ gasPrice?: bigint;
1140
+ maxFeePerGas?: bigint;
1141
+ maxPriorityFeePerGas?: bigint;
1142
+ nonce?: number;
1143
+ value?: bigint;
1144
+ }): Promise<`0x${string}`>;
1145
+ /**
1146
+ * burnFrom
1147
+ * nonpayable
1148
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1149
+ */
1150
+ burnFrom(account: `0x${string}`, value: bigint, options?: {
1151
+ accessList?: import('viem').AccessList;
1152
+ authorizationList?: import('viem').AuthorizationList;
1153
+ chain?: import('viem').Chain | null;
1154
+ dataSuffix?: `0x${string}`;
1155
+ gas?: bigint;
1156
+ gasPrice?: bigint;
1157
+ maxFeePerGas?: bigint;
1158
+ maxPriorityFeePerGas?: bigint;
1159
+ nonce?: number;
1160
+ value?: bigint;
1161
+ }): Promise<`0x${string}`>;
1162
+ /**
1163
+ * burnShares
1164
+ * nonpayable
1165
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1166
+ */
1167
+ burnShares(value: bigint, options?: {
1168
+ accessList?: import('viem').AccessList;
1169
+ authorizationList?: import('viem').AuthorizationList;
1170
+ chain?: import('viem').Chain | null;
1171
+ dataSuffix?: `0x${string}`;
1172
+ gas?: bigint;
1173
+ gasPrice?: bigint;
1174
+ maxFeePerGas?: bigint;
1175
+ maxPriorityFeePerGas?: bigint;
1176
+ nonce?: number;
1177
+ value?: bigint;
1178
+ }): Promise<`0x${string}`>;
1179
+ /**
1180
+ * burnSharesFrom
1181
+ * nonpayable
1182
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1183
+ */
1184
+ burnSharesFrom(account: `0x${string}`, value: bigint, options?: {
1185
+ accessList?: import('viem').AccessList;
1186
+ authorizationList?: import('viem').AuthorizationList;
1187
+ chain?: import('viem').Chain | null;
1188
+ dataSuffix?: `0x${string}`;
1189
+ gas?: bigint;
1190
+ gasPrice?: bigint;
1191
+ maxFeePerGas?: bigint;
1192
+ maxPriorityFeePerGas?: bigint;
1193
+ nonce?: number;
1194
+ value?: bigint;
1195
+ }): Promise<`0x${string}`>;
1196
+ /**
1197
+ * grantRole
1198
+ * nonpayable
1199
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1200
+ */
1201
+ grantRole(role: `0x${string}`, account: `0x${string}`, options?: {
1202
+ accessList?: import('viem').AccessList;
1203
+ authorizationList?: import('viem').AuthorizationList;
1204
+ chain?: import('viem').Chain | null;
1205
+ dataSuffix?: `0x${string}`;
1206
+ gas?: bigint;
1207
+ gasPrice?: bigint;
1208
+ maxFeePerGas?: bigint;
1209
+ maxPriorityFeePerGas?: bigint;
1210
+ nonce?: number;
1211
+ value?: bigint;
1212
+ }): Promise<`0x${string}`>;
1213
+ /**
1214
+ * mint
1215
+ * nonpayable
1216
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1217
+ */
1218
+ mint(to: `0x${string}`, amount: bigint, options?: {
1219
+ accessList?: import('viem').AccessList;
1220
+ authorizationList?: import('viem').AuthorizationList;
1221
+ chain?: import('viem').Chain | null;
1222
+ dataSuffix?: `0x${string}`;
1223
+ gas?: bigint;
1224
+ gasPrice?: bigint;
1225
+ maxFeePerGas?: bigint;
1226
+ maxPriorityFeePerGas?: bigint;
1227
+ nonce?: number;
1228
+ value?: bigint;
1229
+ }): Promise<`0x${string}`>;
1230
+ /**
1231
+ * mintShares
1232
+ * nonpayable
1233
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1234
+ */
1235
+ mintShares(to: `0x${string}`, amount: bigint, options?: {
1236
+ accessList?: import('viem').AccessList;
1237
+ authorizationList?: import('viem').AuthorizationList;
1238
+ chain?: import('viem').Chain | null;
1239
+ dataSuffix?: `0x${string}`;
1240
+ gas?: bigint;
1241
+ gasPrice?: bigint;
1242
+ maxFeePerGas?: bigint;
1243
+ maxPriorityFeePerGas?: bigint;
1244
+ nonce?: number;
1245
+ value?: bigint;
1246
+ }): Promise<`0x${string}`>;
1247
+ /**
1248
+ * permit
1249
+ * nonpayable
1250
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1251
+ */
1252
+ permit(owner: `0x${string}`, spender: `0x${string}`, value: bigint, deadline: bigint, v: bigint, r: `0x${string}`, s: `0x${string}`, options?: {
1253
+ accessList?: import('viem').AccessList;
1254
+ authorizationList?: import('viem').AuthorizationList;
1255
+ chain?: import('viem').Chain | null;
1256
+ dataSuffix?: `0x${string}`;
1257
+ gas?: bigint;
1258
+ gasPrice?: bigint;
1259
+ maxFeePerGas?: bigint;
1260
+ maxPriorityFeePerGas?: bigint;
1261
+ nonce?: number;
1262
+ value?: bigint;
1263
+ }): Promise<`0x${string}`>;
1264
+ /**
1265
+ * rebase
1266
+ * nonpayable
1267
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1268
+ */
1269
+ rebase(newDivisor: bigint, options?: {
1270
+ accessList?: import('viem').AccessList;
1271
+ authorizationList?: import('viem').AuthorizationList;
1272
+ chain?: import('viem').Chain | null;
1273
+ dataSuffix?: `0x${string}`;
1274
+ gas?: bigint;
1275
+ gasPrice?: bigint;
1276
+ maxFeePerGas?: bigint;
1277
+ maxPriorityFeePerGas?: bigint;
1278
+ nonce?: number;
1279
+ value?: bigint;
1280
+ }): Promise<`0x${string}`>;
1281
+ /**
1282
+ * renounceRole
1283
+ * nonpayable
1284
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1285
+ */
1286
+ renounceRole(role: `0x${string}`, callerConfirmation: `0x${string}`, options?: {
1287
+ accessList?: import('viem').AccessList;
1288
+ authorizationList?: import('viem').AuthorizationList;
1289
+ chain?: import('viem').Chain | null;
1290
+ dataSuffix?: `0x${string}`;
1291
+ gas?: bigint;
1292
+ gasPrice?: bigint;
1293
+ maxFeePerGas?: bigint;
1294
+ maxPriorityFeePerGas?: bigint;
1295
+ nonce?: number;
1296
+ value?: bigint;
1297
+ }): Promise<`0x${string}`>;
1298
+ /**
1299
+ * revokeRole
1300
+ * nonpayable
1301
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1302
+ */
1303
+ revokeRole(role: `0x${string}`, account: `0x${string}`, options?: {
1304
+ accessList?: import('viem').AccessList;
1305
+ authorizationList?: import('viem').AuthorizationList;
1306
+ chain?: import('viem').Chain | null;
1307
+ dataSuffix?: `0x${string}`;
1308
+ gas?: bigint;
1309
+ gasPrice?: bigint;
1310
+ maxFeePerGas?: bigint;
1311
+ maxPriorityFeePerGas?: bigint;
1312
+ nonce?: number;
1313
+ value?: bigint;
1314
+ }): Promise<`0x${string}`>;
1315
+ /**
1316
+ * setRebaseHandler
1317
+ * nonpayable
1318
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1319
+ */
1320
+ setRebaseHandler(newHandler: `0x${string}`, options?: {
1321
+ accessList?: import('viem').AccessList;
1322
+ authorizationList?: import('viem').AuthorizationList;
1323
+ chain?: import('viem').Chain | null;
1324
+ dataSuffix?: `0x${string}`;
1325
+ gas?: bigint;
1326
+ gasPrice?: bigint;
1327
+ maxFeePerGas?: bigint;
1328
+ maxPriorityFeePerGas?: bigint;
1329
+ nonce?: number;
1330
+ value?: bigint;
1331
+ }): Promise<`0x${string}`>;
1332
+ /**
1333
+ * transfer
1334
+ * nonpayable
1335
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1336
+ */
1337
+ transfer(to: `0x${string}`, value: bigint, options?: {
1338
+ accessList?: import('viem').AccessList;
1339
+ authorizationList?: import('viem').AuthorizationList;
1340
+ chain?: import('viem').Chain | null;
1341
+ dataSuffix?: `0x${string}`;
1342
+ gas?: bigint;
1343
+ gasPrice?: bigint;
1344
+ maxFeePerGas?: bigint;
1345
+ maxPriorityFeePerGas?: bigint;
1346
+ nonce?: number;
1347
+ value?: bigint;
1348
+ }): Promise<`0x${string}`>;
1349
+ /**
1350
+ * transferFrom
1351
+ * nonpayable
1352
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1353
+ */
1354
+ transferFrom(from: `0x${string}`, to: `0x${string}`, value: bigint, options?: {
1355
+ accessList?: import('viem').AccessList;
1356
+ authorizationList?: import('viem').AuthorizationList;
1357
+ chain?: import('viem').Chain | null;
1358
+ dataSuffix?: `0x${string}`;
1359
+ gas?: bigint;
1360
+ gasPrice?: bigint;
1361
+ maxFeePerGas?: bigint;
1362
+ maxPriorityFeePerGas?: bigint;
1363
+ nonce?: number;
1364
+ value?: bigint;
1365
+ }): Promise<`0x${string}`>;
1366
+ /**
1367
+ * transferShares
1368
+ * nonpayable
1369
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1370
+ */
1371
+ transferShares(to: `0x${string}`, value: bigint, options?: {
1372
+ accessList?: import('viem').AccessList;
1373
+ authorizationList?: import('viem').AuthorizationList;
1374
+ chain?: import('viem').Chain | null;
1375
+ dataSuffix?: `0x${string}`;
1376
+ gas?: bigint;
1377
+ gasPrice?: bigint;
1378
+ maxFeePerGas?: bigint;
1379
+ maxPriorityFeePerGas?: bigint;
1380
+ nonce?: number;
1381
+ value?: bigint;
1382
+ }): Promise<`0x${string}`>;
1383
+ /**
1384
+ * transferSharesFrom
1385
+ * nonpayable
1386
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1387
+ */
1388
+ transferSharesFrom(from: `0x${string}`, to: `0x${string}`, value: bigint, options?: {
1389
+ accessList?: import('viem').AccessList;
1390
+ authorizationList?: import('viem').AuthorizationList;
1391
+ chain?: import('viem').Chain | null;
1392
+ dataSuffix?: `0x${string}`;
1393
+ gas?: bigint;
1394
+ gasPrice?: bigint;
1395
+ maxFeePerGas?: bigint;
1396
+ maxPriorityFeePerGas?: bigint;
1397
+ nonce?: number;
1398
+ value?: bigint;
1399
+ }): Promise<`0x${string}`>;
1400
+ /**
1401
+ * Simulate contract write operations (dry-run without sending transaction)
1402
+ *
1403
+ * @example
1404
+ * const result = await contract.simulate.transfer('0x...', 1000n);
1405
+ * console.log('Gas estimate:', result.request.gas);
1406
+ * console.log('Would succeed:', result.result);
1407
+ */
1408
+ get simulate(): {
1409
+ /**
1410
+ * Simulate approve
1411
+ * Returns gas estimate and result without sending transaction
1412
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1413
+ */
1414
+ approve(spender: `0x${string}`, value: bigint, options?: {
1415
+ accessList?: import("viem").AccessList;
1416
+ authorizationList?: import("viem").AuthorizationList;
1417
+ chain?: import("viem").Chain | null;
1418
+ dataSuffix?: `0x${string}`;
1419
+ gas?: bigint;
1420
+ gasPrice?: bigint;
1421
+ maxFeePerGas?: bigint;
1422
+ maxPriorityFeePerGas?: bigint;
1423
+ nonce?: number;
1424
+ value?: bigint;
1425
+ }): Promise<boolean>;
1426
+ /**
1427
+ * Simulate burn
1428
+ * Returns gas estimate and result without sending transaction
1429
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1430
+ */
1431
+ burn(value: bigint, options?: {
1432
+ accessList?: import("viem").AccessList;
1433
+ authorizationList?: import("viem").AuthorizationList;
1434
+ chain?: import("viem").Chain | null;
1435
+ dataSuffix?: `0x${string}`;
1436
+ gas?: bigint;
1437
+ gasPrice?: bigint;
1438
+ maxFeePerGas?: bigint;
1439
+ maxPriorityFeePerGas?: bigint;
1440
+ nonce?: number;
1441
+ value?: bigint;
1442
+ }): Promise<void>;
1443
+ /**
1444
+ * Simulate burnFrom
1445
+ * Returns gas estimate and result without sending transaction
1446
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1447
+ */
1448
+ burnFrom(account: `0x${string}`, value: bigint, options?: {
1449
+ accessList?: import("viem").AccessList;
1450
+ authorizationList?: import("viem").AuthorizationList;
1451
+ chain?: import("viem").Chain | null;
1452
+ dataSuffix?: `0x${string}`;
1453
+ gas?: bigint;
1454
+ gasPrice?: bigint;
1455
+ maxFeePerGas?: bigint;
1456
+ maxPriorityFeePerGas?: bigint;
1457
+ nonce?: number;
1458
+ value?: bigint;
1459
+ }): Promise<void>;
1460
+ /**
1461
+ * Simulate burnShares
1462
+ * Returns gas estimate and result without sending transaction
1463
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1464
+ */
1465
+ burnShares(value: bigint, options?: {
1466
+ accessList?: import("viem").AccessList;
1467
+ authorizationList?: import("viem").AuthorizationList;
1468
+ chain?: import("viem").Chain | null;
1469
+ dataSuffix?: `0x${string}`;
1470
+ gas?: bigint;
1471
+ gasPrice?: bigint;
1472
+ maxFeePerGas?: bigint;
1473
+ maxPriorityFeePerGas?: bigint;
1474
+ nonce?: number;
1475
+ value?: bigint;
1476
+ }): Promise<void>;
1477
+ /**
1478
+ * Simulate burnSharesFrom
1479
+ * Returns gas estimate and result without sending transaction
1480
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1481
+ */
1482
+ burnSharesFrom(account: `0x${string}`, value: bigint, options?: {
1483
+ accessList?: import("viem").AccessList;
1484
+ authorizationList?: import("viem").AuthorizationList;
1485
+ chain?: import("viem").Chain | null;
1486
+ dataSuffix?: `0x${string}`;
1487
+ gas?: bigint;
1488
+ gasPrice?: bigint;
1489
+ maxFeePerGas?: bigint;
1490
+ maxPriorityFeePerGas?: bigint;
1491
+ nonce?: number;
1492
+ value?: bigint;
1493
+ }): Promise<void>;
1494
+ /**
1495
+ * Simulate grantRole
1496
+ * Returns gas estimate and result without sending transaction
1497
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1498
+ */
1499
+ grantRole(role: `0x${string}`, account: `0x${string}`, options?: {
1500
+ accessList?: import("viem").AccessList;
1501
+ authorizationList?: import("viem").AuthorizationList;
1502
+ chain?: import("viem").Chain | null;
1503
+ dataSuffix?: `0x${string}`;
1504
+ gas?: bigint;
1505
+ gasPrice?: bigint;
1506
+ maxFeePerGas?: bigint;
1507
+ maxPriorityFeePerGas?: bigint;
1508
+ nonce?: number;
1509
+ value?: bigint;
1510
+ }): Promise<void>;
1511
+ /**
1512
+ * Simulate mint
1513
+ * Returns gas estimate and result without sending transaction
1514
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1515
+ */
1516
+ mint(to: `0x${string}`, amount: bigint, options?: {
1517
+ accessList?: import("viem").AccessList;
1518
+ authorizationList?: import("viem").AuthorizationList;
1519
+ chain?: import("viem").Chain | null;
1520
+ dataSuffix?: `0x${string}`;
1521
+ gas?: bigint;
1522
+ gasPrice?: bigint;
1523
+ maxFeePerGas?: bigint;
1524
+ maxPriorityFeePerGas?: bigint;
1525
+ nonce?: number;
1526
+ value?: bigint;
1527
+ }): Promise<void>;
1528
+ /**
1529
+ * Simulate mintShares
1530
+ * Returns gas estimate and result without sending transaction
1531
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1532
+ */
1533
+ mintShares(to: `0x${string}`, amount: bigint, options?: {
1534
+ accessList?: import("viem").AccessList;
1535
+ authorizationList?: import("viem").AuthorizationList;
1536
+ chain?: import("viem").Chain | null;
1537
+ dataSuffix?: `0x${string}`;
1538
+ gas?: bigint;
1539
+ gasPrice?: bigint;
1540
+ maxFeePerGas?: bigint;
1541
+ maxPriorityFeePerGas?: bigint;
1542
+ nonce?: number;
1543
+ value?: bigint;
1544
+ }): Promise<bigint>;
1545
+ /**
1546
+ * Simulate permit
1547
+ * Returns gas estimate and result without sending transaction
1548
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1549
+ */
1550
+ permit(owner: `0x${string}`, spender: `0x${string}`, value: bigint, deadline: bigint, v: bigint, r: `0x${string}`, s: `0x${string}`, options?: {
1551
+ accessList?: import("viem").AccessList;
1552
+ authorizationList?: import("viem").AuthorizationList;
1553
+ chain?: import("viem").Chain | null;
1554
+ dataSuffix?: `0x${string}`;
1555
+ gas?: bigint;
1556
+ gasPrice?: bigint;
1557
+ maxFeePerGas?: bigint;
1558
+ maxPriorityFeePerGas?: bigint;
1559
+ nonce?: number;
1560
+ value?: bigint;
1561
+ }): Promise<void>;
1562
+ /**
1563
+ * Simulate rebase
1564
+ * Returns gas estimate and result without sending transaction
1565
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1566
+ */
1567
+ rebase(newDivisor: bigint, options?: {
1568
+ accessList?: import("viem").AccessList;
1569
+ authorizationList?: import("viem").AuthorizationList;
1570
+ chain?: import("viem").Chain | null;
1571
+ dataSuffix?: `0x${string}`;
1572
+ gas?: bigint;
1573
+ gasPrice?: bigint;
1574
+ maxFeePerGas?: bigint;
1575
+ maxPriorityFeePerGas?: bigint;
1576
+ nonce?: number;
1577
+ value?: bigint;
1578
+ }): Promise<[boolean, bigint, `0x${string}`]>;
1579
+ /**
1580
+ * Simulate renounceRole
1581
+ * Returns gas estimate and result without sending transaction
1582
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1583
+ */
1584
+ renounceRole(role: `0x${string}`, callerConfirmation: `0x${string}`, options?: {
1585
+ accessList?: import("viem").AccessList;
1586
+ authorizationList?: import("viem").AuthorizationList;
1587
+ chain?: import("viem").Chain | null;
1588
+ dataSuffix?: `0x${string}`;
1589
+ gas?: bigint;
1590
+ gasPrice?: bigint;
1591
+ maxFeePerGas?: bigint;
1592
+ maxPriorityFeePerGas?: bigint;
1593
+ nonce?: number;
1594
+ value?: bigint;
1595
+ }): Promise<void>;
1596
+ /**
1597
+ * Simulate revokeRole
1598
+ * Returns gas estimate and result without sending transaction
1599
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1600
+ */
1601
+ revokeRole(role: `0x${string}`, account: `0x${string}`, options?: {
1602
+ accessList?: import("viem").AccessList;
1603
+ authorizationList?: import("viem").AuthorizationList;
1604
+ chain?: import("viem").Chain | null;
1605
+ dataSuffix?: `0x${string}`;
1606
+ gas?: bigint;
1607
+ gasPrice?: bigint;
1608
+ maxFeePerGas?: bigint;
1609
+ maxPriorityFeePerGas?: bigint;
1610
+ nonce?: number;
1611
+ value?: bigint;
1612
+ }): Promise<void>;
1613
+ /**
1614
+ * Simulate setRebaseHandler
1615
+ * Returns gas estimate and result without sending transaction
1616
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1617
+ */
1618
+ setRebaseHandler(newHandler: `0x${string}`, options?: {
1619
+ accessList?: import("viem").AccessList;
1620
+ authorizationList?: import("viem").AuthorizationList;
1621
+ chain?: import("viem").Chain | null;
1622
+ dataSuffix?: `0x${string}`;
1623
+ gas?: bigint;
1624
+ gasPrice?: bigint;
1625
+ maxFeePerGas?: bigint;
1626
+ maxPriorityFeePerGas?: bigint;
1627
+ nonce?: number;
1628
+ value?: bigint;
1629
+ }): Promise<void>;
1630
+ /**
1631
+ * Simulate transfer
1632
+ * Returns gas estimate and result without sending transaction
1633
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1634
+ */
1635
+ transfer(to: `0x${string}`, value: bigint, options?: {
1636
+ accessList?: import("viem").AccessList;
1637
+ authorizationList?: import("viem").AuthorizationList;
1638
+ chain?: import("viem").Chain | null;
1639
+ dataSuffix?: `0x${string}`;
1640
+ gas?: bigint;
1641
+ gasPrice?: bigint;
1642
+ maxFeePerGas?: bigint;
1643
+ maxPriorityFeePerGas?: bigint;
1644
+ nonce?: number;
1645
+ value?: bigint;
1646
+ }): Promise<boolean>;
1647
+ /**
1648
+ * Simulate transferFrom
1649
+ * Returns gas estimate and result without sending transaction
1650
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1651
+ */
1652
+ transferFrom(from: `0x${string}`, to: `0x${string}`, value: bigint, options?: {
1653
+ accessList?: import("viem").AccessList;
1654
+ authorizationList?: import("viem").AuthorizationList;
1655
+ chain?: import("viem").Chain | null;
1656
+ dataSuffix?: `0x${string}`;
1657
+ gas?: bigint;
1658
+ gasPrice?: bigint;
1659
+ maxFeePerGas?: bigint;
1660
+ maxPriorityFeePerGas?: bigint;
1661
+ nonce?: number;
1662
+ value?: bigint;
1663
+ }): Promise<boolean>;
1664
+ /**
1665
+ * Simulate transferShares
1666
+ * Returns gas estimate and result without sending transaction
1667
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1668
+ */
1669
+ transferShares(to: `0x${string}`, value: bigint, options?: {
1670
+ accessList?: import("viem").AccessList;
1671
+ authorizationList?: import("viem").AuthorizationList;
1672
+ chain?: import("viem").Chain | null;
1673
+ dataSuffix?: `0x${string}`;
1674
+ gas?: bigint;
1675
+ gasPrice?: bigint;
1676
+ maxFeePerGas?: bigint;
1677
+ maxPriorityFeePerGas?: bigint;
1678
+ nonce?: number;
1679
+ value?: bigint;
1680
+ }): Promise<boolean>;
1681
+ /**
1682
+ * Simulate transferSharesFrom
1683
+ * Returns gas estimate and result without sending transaction
1684
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1685
+ */
1686
+ transferSharesFrom(from: `0x${string}`, to: `0x${string}`, value: bigint, options?: {
1687
+ accessList?: import("viem").AccessList;
1688
+ authorizationList?: import("viem").AuthorizationList;
1689
+ chain?: import("viem").Chain | null;
1690
+ dataSuffix?: `0x${string}`;
1691
+ gas?: bigint;
1692
+ gasPrice?: bigint;
1693
+ maxFeePerGas?: bigint;
1694
+ maxPriorityFeePerGas?: bigint;
1695
+ nonce?: number;
1696
+ value?: bigint;
1697
+ }): Promise<boolean>;
1698
+ };
1699
+ /**
1700
+ * Watch contract events
1701
+ *
1702
+ * @example
1703
+ * // Watch all Transfer events
1704
+ * const unwatch = contract.watch.Transfer((event) => {
1705
+ * console.log('Transfer:', event);
1706
+ * });
1707
+ *
1708
+ * // Stop watching
1709
+ * unwatch();
1710
+ */
1711
+ get watch(): {
1712
+ /**
1713
+ * Watch Approval events
1714
+ * @param callback Function to call when event is emitted
1715
+ * @param filter Optional filter for indexed parameters
1716
+ * @returns Unwatch function to stop listening
1717
+ */
1718
+ Approval: (callback: (event: {
1719
+ owner: `0x${string}`;
1720
+ spender: `0x${string}`;
1721
+ value: bigint;
1722
+ }) => void, filter?: {
1723
+ owner?: `0x${string}` | `0x${string}`[] | null;
1724
+ spender?: `0x${string}` | `0x${string}`[] | null;
1725
+ }) => () => void;
1726
+ /**
1727
+ * Watch EIP712DomainChanged events
1728
+ * @param callback Function to call when event is emitted
1729
+ * @param filter Optional filter for indexed parameters
1730
+ * @returns Unwatch function to stop listening
1731
+ */
1732
+ EIP712DomainChanged: (callback: (event: {}) => void) => () => void;
1733
+ /**
1734
+ * Watch Rebase events
1735
+ * @param callback Function to call when event is emitted
1736
+ * @param filter Optional filter for indexed parameters
1737
+ * @returns Unwatch function to stop listening
1738
+ */
1739
+ Rebase: (callback: (event: {
1740
+ oldDivisor: bigint;
1741
+ newDivisor: bigint;
1742
+ }) => void) => () => void;
1743
+ /**
1744
+ * Watch RebaseHandlerUpdated events
1745
+ * @param callback Function to call when event is emitted
1746
+ * @param filter Optional filter for indexed parameters
1747
+ * @returns Unwatch function to stop listening
1748
+ */
1749
+ RebaseHandlerUpdated: (callback: (event: {
1750
+ newHandler: `0x${string}`;
1751
+ }) => void) => () => void;
1752
+ /**
1753
+ * Watch RoleAdminChanged events
1754
+ * @param callback Function to call when event is emitted
1755
+ * @param filter Optional filter for indexed parameters
1756
+ * @returns Unwatch function to stop listening
1757
+ */
1758
+ RoleAdminChanged: (callback: (event: {
1759
+ role: `0x${string}`;
1760
+ previousAdminRole: `0x${string}`;
1761
+ newAdminRole: `0x${string}`;
1762
+ }) => void, filter?: {
1763
+ role?: `0x${string}` | `0x${string}`[] | null;
1764
+ previousAdminRole?: `0x${string}` | `0x${string}`[] | null;
1765
+ newAdminRole?: `0x${string}` | `0x${string}`[] | null;
1766
+ }) => () => void;
1767
+ /**
1768
+ * Watch RoleGranted events
1769
+ * @param callback Function to call when event is emitted
1770
+ * @param filter Optional filter for indexed parameters
1771
+ * @returns Unwatch function to stop listening
1772
+ */
1773
+ RoleGranted: (callback: (event: {
1774
+ role: `0x${string}`;
1775
+ account: `0x${string}`;
1776
+ sender: `0x${string}`;
1777
+ }) => void, filter?: {
1778
+ role?: `0x${string}` | `0x${string}`[] | null;
1779
+ account?: `0x${string}` | `0x${string}`[] | null;
1780
+ sender?: `0x${string}` | `0x${string}`[] | null;
1781
+ }) => () => void;
1782
+ /**
1783
+ * Watch RoleRevoked events
1784
+ * @param callback Function to call when event is emitted
1785
+ * @param filter Optional filter for indexed parameters
1786
+ * @returns Unwatch function to stop listening
1787
+ */
1788
+ RoleRevoked: (callback: (event: {
1789
+ role: `0x${string}`;
1790
+ account: `0x${string}`;
1791
+ sender: `0x${string}`;
1792
+ }) => void, filter?: {
1793
+ role?: `0x${string}` | `0x${string}`[] | null;
1794
+ account?: `0x${string}` | `0x${string}`[] | null;
1795
+ sender?: `0x${string}` | `0x${string}`[] | null;
1796
+ }) => () => void;
1797
+ /**
1798
+ * Watch Transfer events
1799
+ * @param callback Function to call when event is emitted
1800
+ * @param filter Optional filter for indexed parameters
1801
+ * @returns Unwatch function to stop listening
1802
+ */
1803
+ Transfer: (callback: (event: {
1804
+ from: `0x${string}`;
1805
+ to: `0x${string}`;
1806
+ value: bigint;
1807
+ }) => void, filter?: {
1808
+ from?: `0x${string}` | `0x${string}`[] | null;
1809
+ to?: `0x${string}` | `0x${string}`[] | null;
1810
+ }) => () => void;
1811
+ };
1812
+ }