@gitmyabi/wuyu 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,2514 @@
1
+ import type { Abi, Address, PublicClient, WalletClient, GetContractReturnType } from 'viem';
2
+ import { getContract } from 'viem';
3
+
4
+ /**
5
+ * LatamStable_json ABI
6
+ *
7
+ * This ABI is typed using viem's type system for full type safety.
8
+ */
9
+ export const LatamStable_jsonAbi = [
10
+ {
11
+ "inputs": [],
12
+ "stateMutability": "nonpayable",
13
+ "type": "constructor"
14
+ },
15
+ {
16
+ "inputs": [],
17
+ "name": "AccessControlBadConfirmation",
18
+ "type": "error"
19
+ },
20
+ {
21
+ "inputs": [
22
+ {
23
+ "internalType": "address",
24
+ "name": "account",
25
+ "type": "address"
26
+ },
27
+ {
28
+ "internalType": "bytes32",
29
+ "name": "neededRole",
30
+ "type": "bytes32"
31
+ }
32
+ ],
33
+ "name": "AccessControlUnauthorizedAccount",
34
+ "type": "error"
35
+ },
36
+ {
37
+ "inputs": [
38
+ {
39
+ "internalType": "address",
40
+ "name": "account",
41
+ "type": "address"
42
+ }
43
+ ],
44
+ "name": "AddressBlocked",
45
+ "type": "error"
46
+ },
47
+ {
48
+ "inputs": [
49
+ {
50
+ "internalType": "address",
51
+ "name": "target",
52
+ "type": "address"
53
+ }
54
+ ],
55
+ "name": "AddressEmptyCode",
56
+ "type": "error"
57
+ },
58
+ {
59
+ "inputs": [],
60
+ "name": "CannotBlockZeroAddress",
61
+ "type": "error"
62
+ },
63
+ {
64
+ "inputs": [],
65
+ "name": "ECDSAInvalidSignature",
66
+ "type": "error"
67
+ },
68
+ {
69
+ "inputs": [
70
+ {
71
+ "internalType": "uint256",
72
+ "name": "length",
73
+ "type": "uint256"
74
+ }
75
+ ],
76
+ "name": "ECDSAInvalidSignatureLength",
77
+ "type": "error"
78
+ },
79
+ {
80
+ "inputs": [
81
+ {
82
+ "internalType": "bytes32",
83
+ "name": "s",
84
+ "type": "bytes32"
85
+ }
86
+ ],
87
+ "name": "ECDSAInvalidSignatureS",
88
+ "type": "error"
89
+ },
90
+ {
91
+ "inputs": [
92
+ {
93
+ "internalType": "address",
94
+ "name": "implementation",
95
+ "type": "address"
96
+ }
97
+ ],
98
+ "name": "ERC1967InvalidImplementation",
99
+ "type": "error"
100
+ },
101
+ {
102
+ "inputs": [],
103
+ "name": "ERC1967NonPayable",
104
+ "type": "error"
105
+ },
106
+ {
107
+ "inputs": [
108
+ {
109
+ "internalType": "address",
110
+ "name": "spender",
111
+ "type": "address"
112
+ },
113
+ {
114
+ "internalType": "uint256",
115
+ "name": "allowance",
116
+ "type": "uint256"
117
+ },
118
+ {
119
+ "internalType": "uint256",
120
+ "name": "needed",
121
+ "type": "uint256"
122
+ }
123
+ ],
124
+ "name": "ERC20InsufficientAllowance",
125
+ "type": "error"
126
+ },
127
+ {
128
+ "inputs": [
129
+ {
130
+ "internalType": "address",
131
+ "name": "sender",
132
+ "type": "address"
133
+ },
134
+ {
135
+ "internalType": "uint256",
136
+ "name": "balance",
137
+ "type": "uint256"
138
+ },
139
+ {
140
+ "internalType": "uint256",
141
+ "name": "needed",
142
+ "type": "uint256"
143
+ }
144
+ ],
145
+ "name": "ERC20InsufficientBalance",
146
+ "type": "error"
147
+ },
148
+ {
149
+ "inputs": [
150
+ {
151
+ "internalType": "address",
152
+ "name": "approver",
153
+ "type": "address"
154
+ }
155
+ ],
156
+ "name": "ERC20InvalidApprover",
157
+ "type": "error"
158
+ },
159
+ {
160
+ "inputs": [
161
+ {
162
+ "internalType": "address",
163
+ "name": "receiver",
164
+ "type": "address"
165
+ }
166
+ ],
167
+ "name": "ERC20InvalidReceiver",
168
+ "type": "error"
169
+ },
170
+ {
171
+ "inputs": [
172
+ {
173
+ "internalType": "address",
174
+ "name": "sender",
175
+ "type": "address"
176
+ }
177
+ ],
178
+ "name": "ERC20InvalidSender",
179
+ "type": "error"
180
+ },
181
+ {
182
+ "inputs": [
183
+ {
184
+ "internalType": "address",
185
+ "name": "spender",
186
+ "type": "address"
187
+ }
188
+ ],
189
+ "name": "ERC20InvalidSpender",
190
+ "type": "error"
191
+ },
192
+ {
193
+ "inputs": [
194
+ {
195
+ "internalType": "uint256",
196
+ "name": "deadline",
197
+ "type": "uint256"
198
+ }
199
+ ],
200
+ "name": "ERC2612ExpiredSignature",
201
+ "type": "error"
202
+ },
203
+ {
204
+ "inputs": [
205
+ {
206
+ "internalType": "address",
207
+ "name": "signer",
208
+ "type": "address"
209
+ },
210
+ {
211
+ "internalType": "address",
212
+ "name": "owner",
213
+ "type": "address"
214
+ }
215
+ ],
216
+ "name": "ERC2612InvalidSigner",
217
+ "type": "error"
218
+ },
219
+ {
220
+ "inputs": [],
221
+ "name": "EnforcedPause",
222
+ "type": "error"
223
+ },
224
+ {
225
+ "inputs": [],
226
+ "name": "ExpectedPause",
227
+ "type": "error"
228
+ },
229
+ {
230
+ "inputs": [],
231
+ "name": "FailedCall",
232
+ "type": "error"
233
+ },
234
+ {
235
+ "inputs": [
236
+ {
237
+ "internalType": "address",
238
+ "name": "account",
239
+ "type": "address"
240
+ },
241
+ {
242
+ "internalType": "uint256",
243
+ "name": "currentNonce",
244
+ "type": "uint256"
245
+ }
246
+ ],
247
+ "name": "InvalidAccountNonce",
248
+ "type": "error"
249
+ },
250
+ {
251
+ "inputs": [],
252
+ "name": "InvalidInitialization",
253
+ "type": "error"
254
+ },
255
+ {
256
+ "inputs": [],
257
+ "name": "NotInitializing",
258
+ "type": "error"
259
+ },
260
+ {
261
+ "inputs": [],
262
+ "name": "UUPSUnauthorizedCallContext",
263
+ "type": "error"
264
+ },
265
+ {
266
+ "inputs": [
267
+ {
268
+ "internalType": "bytes32",
269
+ "name": "slot",
270
+ "type": "bytes32"
271
+ }
272
+ ],
273
+ "name": "UUPSUnsupportedProxiableUUID",
274
+ "type": "error"
275
+ },
276
+ {
277
+ "anonymous": false,
278
+ "inputs": [
279
+ {
280
+ "indexed": true,
281
+ "internalType": "address",
282
+ "name": "owner",
283
+ "type": "address"
284
+ },
285
+ {
286
+ "indexed": true,
287
+ "internalType": "address",
288
+ "name": "spender",
289
+ "type": "address"
290
+ },
291
+ {
292
+ "indexed": false,
293
+ "internalType": "uint256",
294
+ "name": "value",
295
+ "type": "uint256"
296
+ }
297
+ ],
298
+ "name": "Approval",
299
+ "type": "event"
300
+ },
301
+ {
302
+ "anonymous": false,
303
+ "inputs": [
304
+ {
305
+ "indexed": true,
306
+ "internalType": "bool",
307
+ "name": "enabled",
308
+ "type": "bool"
309
+ }
310
+ ],
311
+ "name": "BlocklistEnforcementSet",
312
+ "type": "event"
313
+ },
314
+ {
315
+ "anonymous": false,
316
+ "inputs": [],
317
+ "name": "EIP712DomainChanged",
318
+ "type": "event"
319
+ },
320
+ {
321
+ "anonymous": false,
322
+ "inputs": [
323
+ {
324
+ "indexed": false,
325
+ "internalType": "uint64",
326
+ "name": "version",
327
+ "type": "uint64"
328
+ }
329
+ ],
330
+ "name": "Initialized",
331
+ "type": "event"
332
+ },
333
+ {
334
+ "anonymous": false,
335
+ "inputs": [
336
+ {
337
+ "indexed": false,
338
+ "internalType": "address",
339
+ "name": "account",
340
+ "type": "address"
341
+ }
342
+ ],
343
+ "name": "Paused",
344
+ "type": "event"
345
+ },
346
+ {
347
+ "anonymous": false,
348
+ "inputs": [
349
+ {
350
+ "indexed": true,
351
+ "internalType": "bytes32",
352
+ "name": "role",
353
+ "type": "bytes32"
354
+ },
355
+ {
356
+ "indexed": true,
357
+ "internalType": "bytes32",
358
+ "name": "previousAdminRole",
359
+ "type": "bytes32"
360
+ },
361
+ {
362
+ "indexed": true,
363
+ "internalType": "bytes32",
364
+ "name": "newAdminRole",
365
+ "type": "bytes32"
366
+ }
367
+ ],
368
+ "name": "RoleAdminChanged",
369
+ "type": "event"
370
+ },
371
+ {
372
+ "anonymous": false,
373
+ "inputs": [
374
+ {
375
+ "indexed": true,
376
+ "internalType": "bytes32",
377
+ "name": "role",
378
+ "type": "bytes32"
379
+ },
380
+ {
381
+ "indexed": true,
382
+ "internalType": "address",
383
+ "name": "account",
384
+ "type": "address"
385
+ },
386
+ {
387
+ "indexed": true,
388
+ "internalType": "address",
389
+ "name": "sender",
390
+ "type": "address"
391
+ }
392
+ ],
393
+ "name": "RoleGranted",
394
+ "type": "event"
395
+ },
396
+ {
397
+ "anonymous": false,
398
+ "inputs": [
399
+ {
400
+ "indexed": true,
401
+ "internalType": "bytes32",
402
+ "name": "role",
403
+ "type": "bytes32"
404
+ },
405
+ {
406
+ "indexed": true,
407
+ "internalType": "address",
408
+ "name": "account",
409
+ "type": "address"
410
+ },
411
+ {
412
+ "indexed": true,
413
+ "internalType": "address",
414
+ "name": "sender",
415
+ "type": "address"
416
+ }
417
+ ],
418
+ "name": "RoleRevoked",
419
+ "type": "event"
420
+ },
421
+ {
422
+ "anonymous": false,
423
+ "inputs": [
424
+ {
425
+ "indexed": true,
426
+ "internalType": "address",
427
+ "name": "from",
428
+ "type": "address"
429
+ },
430
+ {
431
+ "indexed": true,
432
+ "internalType": "address",
433
+ "name": "to",
434
+ "type": "address"
435
+ },
436
+ {
437
+ "indexed": false,
438
+ "internalType": "uint256",
439
+ "name": "value",
440
+ "type": "uint256"
441
+ }
442
+ ],
443
+ "name": "Transfer",
444
+ "type": "event"
445
+ },
446
+ {
447
+ "anonymous": false,
448
+ "inputs": [
449
+ {
450
+ "indexed": false,
451
+ "internalType": "address",
452
+ "name": "account",
453
+ "type": "address"
454
+ }
455
+ ],
456
+ "name": "Unpaused",
457
+ "type": "event"
458
+ },
459
+ {
460
+ "anonymous": false,
461
+ "inputs": [
462
+ {
463
+ "indexed": true,
464
+ "internalType": "address",
465
+ "name": "implementation",
466
+ "type": "address"
467
+ }
468
+ ],
469
+ "name": "Upgraded",
470
+ "type": "event"
471
+ },
472
+ {
473
+ "anonymous": false,
474
+ "inputs": [
475
+ {
476
+ "indexed": true,
477
+ "internalType": "address",
478
+ "name": "account",
479
+ "type": "address"
480
+ }
481
+ ],
482
+ "name": "UserBlocked",
483
+ "type": "event"
484
+ },
485
+ {
486
+ "anonymous": false,
487
+ "inputs": [
488
+ {
489
+ "indexed": true,
490
+ "internalType": "address",
491
+ "name": "account",
492
+ "type": "address"
493
+ }
494
+ ],
495
+ "name": "UserUnblocked",
496
+ "type": "event"
497
+ },
498
+ {
499
+ "inputs": [],
500
+ "name": "COMPLIANCE_ROLE",
501
+ "outputs": [
502
+ {
503
+ "internalType": "bytes32",
504
+ "name": "",
505
+ "type": "bytes32"
506
+ }
507
+ ],
508
+ "stateMutability": "view",
509
+ "type": "function"
510
+ },
511
+ {
512
+ "inputs": [],
513
+ "name": "DEFAULT_ADMIN_ROLE",
514
+ "outputs": [
515
+ {
516
+ "internalType": "bytes32",
517
+ "name": "",
518
+ "type": "bytes32"
519
+ }
520
+ ],
521
+ "stateMutability": "view",
522
+ "type": "function"
523
+ },
524
+ {
525
+ "inputs": [],
526
+ "name": "DOMAIN_SEPARATOR",
527
+ "outputs": [
528
+ {
529
+ "internalType": "bytes32",
530
+ "name": "",
531
+ "type": "bytes32"
532
+ }
533
+ ],
534
+ "stateMutability": "view",
535
+ "type": "function"
536
+ },
537
+ {
538
+ "inputs": [],
539
+ "name": "MINTER_ROLE",
540
+ "outputs": [
541
+ {
542
+ "internalType": "bytes32",
543
+ "name": "",
544
+ "type": "bytes32"
545
+ }
546
+ ],
547
+ "stateMutability": "view",
548
+ "type": "function"
549
+ },
550
+ {
551
+ "inputs": [],
552
+ "name": "PAUSER_ROLE",
553
+ "outputs": [
554
+ {
555
+ "internalType": "bytes32",
556
+ "name": "",
557
+ "type": "bytes32"
558
+ }
559
+ ],
560
+ "stateMutability": "view",
561
+ "type": "function"
562
+ },
563
+ {
564
+ "inputs": [],
565
+ "name": "UPGRADER_ROLE",
566
+ "outputs": [
567
+ {
568
+ "internalType": "bytes32",
569
+ "name": "",
570
+ "type": "bytes32"
571
+ }
572
+ ],
573
+ "stateMutability": "view",
574
+ "type": "function"
575
+ },
576
+ {
577
+ "inputs": [],
578
+ "name": "UPGRADE_INTERFACE_VERSION",
579
+ "outputs": [
580
+ {
581
+ "internalType": "string",
582
+ "name": "",
583
+ "type": "string"
584
+ }
585
+ ],
586
+ "stateMutability": "view",
587
+ "type": "function"
588
+ },
589
+ {
590
+ "inputs": [
591
+ {
592
+ "internalType": "address",
593
+ "name": "owner",
594
+ "type": "address"
595
+ },
596
+ {
597
+ "internalType": "address",
598
+ "name": "spender",
599
+ "type": "address"
600
+ }
601
+ ],
602
+ "name": "allowance",
603
+ "outputs": [
604
+ {
605
+ "internalType": "uint256",
606
+ "name": "",
607
+ "type": "uint256"
608
+ }
609
+ ],
610
+ "stateMutability": "view",
611
+ "type": "function"
612
+ },
613
+ {
614
+ "inputs": [
615
+ {
616
+ "internalType": "address",
617
+ "name": "spender",
618
+ "type": "address"
619
+ },
620
+ {
621
+ "internalType": "uint256",
622
+ "name": "value",
623
+ "type": "uint256"
624
+ }
625
+ ],
626
+ "name": "approve",
627
+ "outputs": [
628
+ {
629
+ "internalType": "bool",
630
+ "name": "",
631
+ "type": "bool"
632
+ }
633
+ ],
634
+ "stateMutability": "nonpayable",
635
+ "type": "function"
636
+ },
637
+ {
638
+ "inputs": [
639
+ {
640
+ "internalType": "address",
641
+ "name": "account",
642
+ "type": "address"
643
+ }
644
+ ],
645
+ "name": "balanceOf",
646
+ "outputs": [
647
+ {
648
+ "internalType": "uint256",
649
+ "name": "",
650
+ "type": "uint256"
651
+ }
652
+ ],
653
+ "stateMutability": "view",
654
+ "type": "function"
655
+ },
656
+ {
657
+ "inputs": [
658
+ {
659
+ "internalType": "address",
660
+ "name": "account",
661
+ "type": "address"
662
+ }
663
+ ],
664
+ "name": "blockUser",
665
+ "outputs": [],
666
+ "stateMutability": "nonpayable",
667
+ "type": "function"
668
+ },
669
+ {
670
+ "inputs": [
671
+ {
672
+ "internalType": "uint256",
673
+ "name": "value",
674
+ "type": "uint256"
675
+ }
676
+ ],
677
+ "name": "burn",
678
+ "outputs": [],
679
+ "stateMutability": "nonpayable",
680
+ "type": "function"
681
+ },
682
+ {
683
+ "inputs": [
684
+ {
685
+ "internalType": "address",
686
+ "name": "account",
687
+ "type": "address"
688
+ },
689
+ {
690
+ "internalType": "uint256",
691
+ "name": "value",
692
+ "type": "uint256"
693
+ }
694
+ ],
695
+ "name": "burnFrom",
696
+ "outputs": [],
697
+ "stateMutability": "nonpayable",
698
+ "type": "function"
699
+ },
700
+ {
701
+ "inputs": [],
702
+ "name": "decimals",
703
+ "outputs": [
704
+ {
705
+ "internalType": "uint8",
706
+ "name": "",
707
+ "type": "uint8"
708
+ }
709
+ ],
710
+ "stateMutability": "view",
711
+ "type": "function"
712
+ },
713
+ {
714
+ "inputs": [],
715
+ "name": "eip712Domain",
716
+ "outputs": [
717
+ {
718
+ "internalType": "bytes1",
719
+ "name": "fields",
720
+ "type": "bytes1"
721
+ },
722
+ {
723
+ "internalType": "string",
724
+ "name": "name",
725
+ "type": "string"
726
+ },
727
+ {
728
+ "internalType": "string",
729
+ "name": "version",
730
+ "type": "string"
731
+ },
732
+ {
733
+ "internalType": "uint256",
734
+ "name": "chainId",
735
+ "type": "uint256"
736
+ },
737
+ {
738
+ "internalType": "address",
739
+ "name": "verifyingContract",
740
+ "type": "address"
741
+ },
742
+ {
743
+ "internalType": "bytes32",
744
+ "name": "salt",
745
+ "type": "bytes32"
746
+ },
747
+ {
748
+ "internalType": "uint256[]",
749
+ "name": "extensions",
750
+ "type": "uint256[]"
751
+ }
752
+ ],
753
+ "stateMutability": "view",
754
+ "type": "function"
755
+ },
756
+ {
757
+ "inputs": [],
758
+ "name": "enforceBlocklist",
759
+ "outputs": [
760
+ {
761
+ "internalType": "bool",
762
+ "name": "",
763
+ "type": "bool"
764
+ }
765
+ ],
766
+ "stateMutability": "view",
767
+ "type": "function"
768
+ },
769
+ {
770
+ "inputs": [
771
+ {
772
+ "internalType": "bytes32",
773
+ "name": "role",
774
+ "type": "bytes32"
775
+ }
776
+ ],
777
+ "name": "getRoleAdmin",
778
+ "outputs": [
779
+ {
780
+ "internalType": "bytes32",
781
+ "name": "",
782
+ "type": "bytes32"
783
+ }
784
+ ],
785
+ "stateMutability": "view",
786
+ "type": "function"
787
+ },
788
+ {
789
+ "inputs": [
790
+ {
791
+ "internalType": "bytes32",
792
+ "name": "role",
793
+ "type": "bytes32"
794
+ },
795
+ {
796
+ "internalType": "address",
797
+ "name": "account",
798
+ "type": "address"
799
+ }
800
+ ],
801
+ "name": "grantRole",
802
+ "outputs": [],
803
+ "stateMutability": "nonpayable",
804
+ "type": "function"
805
+ },
806
+ {
807
+ "inputs": [
808
+ {
809
+ "internalType": "bytes32",
810
+ "name": "role",
811
+ "type": "bytes32"
812
+ },
813
+ {
814
+ "internalType": "address",
815
+ "name": "account",
816
+ "type": "address"
817
+ }
818
+ ],
819
+ "name": "hasRole",
820
+ "outputs": [
821
+ {
822
+ "internalType": "bool",
823
+ "name": "",
824
+ "type": "bool"
825
+ }
826
+ ],
827
+ "stateMutability": "view",
828
+ "type": "function"
829
+ },
830
+ {
831
+ "inputs": [
832
+ {
833
+ "internalType": "address",
834
+ "name": "defaultAdmin",
835
+ "type": "address"
836
+ },
837
+ {
838
+ "internalType": "address",
839
+ "name": "pauser",
840
+ "type": "address"
841
+ },
842
+ {
843
+ "internalType": "address",
844
+ "name": "minter",
845
+ "type": "address"
846
+ },
847
+ {
848
+ "internalType": "address",
849
+ "name": "upgrader",
850
+ "type": "address"
851
+ },
852
+ {
853
+ "internalType": "address",
854
+ "name": "complianceAdmin",
855
+ "type": "address"
856
+ },
857
+ {
858
+ "internalType": "string",
859
+ "name": "tokenName",
860
+ "type": "string"
861
+ },
862
+ {
863
+ "internalType": "string",
864
+ "name": "tokenSymbol",
865
+ "type": "string"
866
+ }
867
+ ],
868
+ "name": "initialize",
869
+ "outputs": [],
870
+ "stateMutability": "nonpayable",
871
+ "type": "function"
872
+ },
873
+ {
874
+ "inputs": [
875
+ {
876
+ "internalType": "address",
877
+ "name": "complianceAdmin",
878
+ "type": "address"
879
+ }
880
+ ],
881
+ "name": "initializeCompliance",
882
+ "outputs": [],
883
+ "stateMutability": "nonpayable",
884
+ "type": "function"
885
+ },
886
+ {
887
+ "inputs": [
888
+ {
889
+ "internalType": "address",
890
+ "name": "account",
891
+ "type": "address"
892
+ }
893
+ ],
894
+ "name": "isBlocked",
895
+ "outputs": [
896
+ {
897
+ "internalType": "bool",
898
+ "name": "",
899
+ "type": "bool"
900
+ }
901
+ ],
902
+ "stateMutability": "view",
903
+ "type": "function"
904
+ },
905
+ {
906
+ "inputs": [
907
+ {
908
+ "internalType": "address",
909
+ "name": "to",
910
+ "type": "address"
911
+ },
912
+ {
913
+ "internalType": "uint256",
914
+ "name": "amount",
915
+ "type": "uint256"
916
+ }
917
+ ],
918
+ "name": "mint",
919
+ "outputs": [],
920
+ "stateMutability": "nonpayable",
921
+ "type": "function"
922
+ },
923
+ {
924
+ "inputs": [],
925
+ "name": "name",
926
+ "outputs": [
927
+ {
928
+ "internalType": "string",
929
+ "name": "",
930
+ "type": "string"
931
+ }
932
+ ],
933
+ "stateMutability": "view",
934
+ "type": "function"
935
+ },
936
+ {
937
+ "inputs": [
938
+ {
939
+ "internalType": "address",
940
+ "name": "owner",
941
+ "type": "address"
942
+ }
943
+ ],
944
+ "name": "nonces",
945
+ "outputs": [
946
+ {
947
+ "internalType": "uint256",
948
+ "name": "",
949
+ "type": "uint256"
950
+ }
951
+ ],
952
+ "stateMutability": "view",
953
+ "type": "function"
954
+ },
955
+ {
956
+ "inputs": [],
957
+ "name": "pause",
958
+ "outputs": [],
959
+ "stateMutability": "nonpayable",
960
+ "type": "function"
961
+ },
962
+ {
963
+ "inputs": [],
964
+ "name": "paused",
965
+ "outputs": [
966
+ {
967
+ "internalType": "bool",
968
+ "name": "",
969
+ "type": "bool"
970
+ }
971
+ ],
972
+ "stateMutability": "view",
973
+ "type": "function"
974
+ },
975
+ {
976
+ "inputs": [
977
+ {
978
+ "internalType": "address",
979
+ "name": "owner",
980
+ "type": "address"
981
+ },
982
+ {
983
+ "internalType": "address",
984
+ "name": "spender",
985
+ "type": "address"
986
+ },
987
+ {
988
+ "internalType": "uint256",
989
+ "name": "value",
990
+ "type": "uint256"
991
+ },
992
+ {
993
+ "internalType": "uint256",
994
+ "name": "deadline",
995
+ "type": "uint256"
996
+ },
997
+ {
998
+ "internalType": "uint8",
999
+ "name": "v",
1000
+ "type": "uint8"
1001
+ },
1002
+ {
1003
+ "internalType": "bytes32",
1004
+ "name": "r",
1005
+ "type": "bytes32"
1006
+ },
1007
+ {
1008
+ "internalType": "bytes32",
1009
+ "name": "s",
1010
+ "type": "bytes32"
1011
+ }
1012
+ ],
1013
+ "name": "permit",
1014
+ "outputs": [],
1015
+ "stateMutability": "nonpayable",
1016
+ "type": "function"
1017
+ },
1018
+ {
1019
+ "inputs": [],
1020
+ "name": "proxiableUUID",
1021
+ "outputs": [
1022
+ {
1023
+ "internalType": "bytes32",
1024
+ "name": "",
1025
+ "type": "bytes32"
1026
+ }
1027
+ ],
1028
+ "stateMutability": "view",
1029
+ "type": "function"
1030
+ },
1031
+ {
1032
+ "inputs": [
1033
+ {
1034
+ "internalType": "bytes32",
1035
+ "name": "role",
1036
+ "type": "bytes32"
1037
+ },
1038
+ {
1039
+ "internalType": "address",
1040
+ "name": "callerConfirmation",
1041
+ "type": "address"
1042
+ }
1043
+ ],
1044
+ "name": "renounceRole",
1045
+ "outputs": [],
1046
+ "stateMutability": "nonpayable",
1047
+ "type": "function"
1048
+ },
1049
+ {
1050
+ "inputs": [
1051
+ {
1052
+ "internalType": "bytes32",
1053
+ "name": "role",
1054
+ "type": "bytes32"
1055
+ },
1056
+ {
1057
+ "internalType": "address",
1058
+ "name": "account",
1059
+ "type": "address"
1060
+ }
1061
+ ],
1062
+ "name": "revokeRole",
1063
+ "outputs": [],
1064
+ "stateMutability": "nonpayable",
1065
+ "type": "function"
1066
+ },
1067
+ {
1068
+ "inputs": [
1069
+ {
1070
+ "internalType": "bool",
1071
+ "name": "enabled",
1072
+ "type": "bool"
1073
+ }
1074
+ ],
1075
+ "name": "setEnforceBlocklist",
1076
+ "outputs": [],
1077
+ "stateMutability": "nonpayable",
1078
+ "type": "function"
1079
+ },
1080
+ {
1081
+ "inputs": [
1082
+ {
1083
+ "internalType": "bytes4",
1084
+ "name": "interfaceId",
1085
+ "type": "bytes4"
1086
+ }
1087
+ ],
1088
+ "name": "supportsInterface",
1089
+ "outputs": [
1090
+ {
1091
+ "internalType": "bool",
1092
+ "name": "",
1093
+ "type": "bool"
1094
+ }
1095
+ ],
1096
+ "stateMutability": "view",
1097
+ "type": "function"
1098
+ },
1099
+ {
1100
+ "inputs": [],
1101
+ "name": "symbol",
1102
+ "outputs": [
1103
+ {
1104
+ "internalType": "string",
1105
+ "name": "",
1106
+ "type": "string"
1107
+ }
1108
+ ],
1109
+ "stateMutability": "view",
1110
+ "type": "function"
1111
+ },
1112
+ {
1113
+ "inputs": [],
1114
+ "name": "totalSupply",
1115
+ "outputs": [
1116
+ {
1117
+ "internalType": "uint256",
1118
+ "name": "",
1119
+ "type": "uint256"
1120
+ }
1121
+ ],
1122
+ "stateMutability": "view",
1123
+ "type": "function"
1124
+ },
1125
+ {
1126
+ "inputs": [
1127
+ {
1128
+ "internalType": "address",
1129
+ "name": "to",
1130
+ "type": "address"
1131
+ },
1132
+ {
1133
+ "internalType": "uint256",
1134
+ "name": "value",
1135
+ "type": "uint256"
1136
+ }
1137
+ ],
1138
+ "name": "transfer",
1139
+ "outputs": [
1140
+ {
1141
+ "internalType": "bool",
1142
+ "name": "",
1143
+ "type": "bool"
1144
+ }
1145
+ ],
1146
+ "stateMutability": "nonpayable",
1147
+ "type": "function"
1148
+ },
1149
+ {
1150
+ "inputs": [
1151
+ {
1152
+ "internalType": "address",
1153
+ "name": "from",
1154
+ "type": "address"
1155
+ },
1156
+ {
1157
+ "internalType": "address",
1158
+ "name": "to",
1159
+ "type": "address"
1160
+ },
1161
+ {
1162
+ "internalType": "uint256",
1163
+ "name": "value",
1164
+ "type": "uint256"
1165
+ }
1166
+ ],
1167
+ "name": "transferFrom",
1168
+ "outputs": [
1169
+ {
1170
+ "internalType": "bool",
1171
+ "name": "",
1172
+ "type": "bool"
1173
+ }
1174
+ ],
1175
+ "stateMutability": "nonpayable",
1176
+ "type": "function"
1177
+ },
1178
+ {
1179
+ "inputs": [
1180
+ {
1181
+ "internalType": "address",
1182
+ "name": "account",
1183
+ "type": "address"
1184
+ }
1185
+ ],
1186
+ "name": "unblockUser",
1187
+ "outputs": [],
1188
+ "stateMutability": "nonpayable",
1189
+ "type": "function"
1190
+ },
1191
+ {
1192
+ "inputs": [],
1193
+ "name": "unpause",
1194
+ "outputs": [],
1195
+ "stateMutability": "nonpayable",
1196
+ "type": "function"
1197
+ },
1198
+ {
1199
+ "inputs": [
1200
+ {
1201
+ "internalType": "address",
1202
+ "name": "newImplementation",
1203
+ "type": "address"
1204
+ },
1205
+ {
1206
+ "internalType": "bytes",
1207
+ "name": "data",
1208
+ "type": "bytes"
1209
+ }
1210
+ ],
1211
+ "name": "upgradeToAndCall",
1212
+ "outputs": [],
1213
+ "stateMutability": "payable",
1214
+ "type": "function"
1215
+ }
1216
+ ] as const satisfies Abi;
1217
+
1218
+ /**
1219
+ * Type-safe ABI for LatamStable_json
1220
+ */
1221
+ export type LatamStable_jsonAbi = typeof LatamStable_jsonAbi;
1222
+
1223
+ /**
1224
+ * Contract instance type for LatamStable_json
1225
+ */
1226
+ // Use any for contract type to avoid complex viem type issues
1227
+ // The runtime behavior is type-safe through viem's ABI typing
1228
+ export type LatamStable_jsonContract = any;
1229
+
1230
+ /**
1231
+ * LatamStable_json Contract Class
1232
+ *
1233
+ * Provides a class-based API similar to TypeChain for interacting with the contract.
1234
+ *
1235
+ * @example
1236
+ * ```typescript
1237
+ * import { createPublicClient, createWalletClient, http } from 'viem';
1238
+ * import { mainnet } from 'viem/chains';
1239
+ * import { LatamStable_json } from 'LatamStable_json';
1240
+ *
1241
+ * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
1242
+ * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
1243
+ *
1244
+ * const contract = new LatamStable_json('0x...', { publicClient, walletClient });
1245
+ *
1246
+ * // Read functions
1247
+ * const result = await contract.balanceOf('0x...');
1248
+ *
1249
+ * // Write functions
1250
+ * const hash = await contract.transfer('0x...', 1000n);
1251
+ *
1252
+ * // Simulate transactions (dry-run)
1253
+ * const simulation = await contract.simulate.transfer('0x...', 1000n);
1254
+ * console.log('Gas estimate:', simulation.request.gas);
1255
+ *
1256
+ * // Watch events
1257
+ * const unwatch = contract.watch.Transfer((event) => {
1258
+ * console.log('Transfer event:', event);
1259
+ * });
1260
+ * ```
1261
+ */
1262
+ export class LatamStable_json {
1263
+ private contract: LatamStable_jsonContract;
1264
+ private contractAddress: Address;
1265
+ private publicClient: PublicClient;
1266
+
1267
+ constructor(
1268
+ address: Address,
1269
+ clients: {
1270
+ publicClient: PublicClient;
1271
+ walletClient?: WalletClient;
1272
+ }
1273
+ ) {
1274
+ this.contractAddress = address;
1275
+ this.publicClient = clients.publicClient;
1276
+ this.contract = getContract({
1277
+ address,
1278
+ abi: LatamStable_jsonAbi,
1279
+ client: {
1280
+ public: clients.publicClient,
1281
+ wallet: clients.walletClient,
1282
+ },
1283
+ });
1284
+ }
1285
+
1286
+ /**
1287
+ * Get the contract address
1288
+ */
1289
+ get address(): Address {
1290
+ return this.contractAddress;
1291
+ }
1292
+
1293
+ /**
1294
+ * Get the underlying viem contract instance
1295
+ */
1296
+ getContract(): LatamStable_jsonContract {
1297
+ return this.contract;
1298
+ }
1299
+
1300
+ /**
1301
+ * COMPLIANCE_ROLE
1302
+ * view
1303
+ */
1304
+ async COMPLIANCE_ROLE(): Promise<`0x${string}`> {
1305
+ return this.contract.read.COMPLIANCE_ROLE() as Promise<`0x${string}`>;
1306
+ }
1307
+
1308
+ /**
1309
+ * DEFAULT_ADMIN_ROLE
1310
+ * view
1311
+ */
1312
+ async DEFAULT_ADMIN_ROLE(): Promise<`0x${string}`> {
1313
+ return this.contract.read.DEFAULT_ADMIN_ROLE() as Promise<`0x${string}`>;
1314
+ }
1315
+
1316
+ /**
1317
+ * DOMAIN_SEPARATOR
1318
+ * view
1319
+ */
1320
+ async DOMAIN_SEPARATOR(): Promise<`0x${string}`> {
1321
+ return this.contract.read.DOMAIN_SEPARATOR() as Promise<`0x${string}`>;
1322
+ }
1323
+
1324
+ /**
1325
+ * MINTER_ROLE
1326
+ * view
1327
+ */
1328
+ async MINTER_ROLE(): Promise<`0x${string}`> {
1329
+ return this.contract.read.MINTER_ROLE() as Promise<`0x${string}`>;
1330
+ }
1331
+
1332
+ /**
1333
+ * PAUSER_ROLE
1334
+ * view
1335
+ */
1336
+ async PAUSER_ROLE(): Promise<`0x${string}`> {
1337
+ return this.contract.read.PAUSER_ROLE() as Promise<`0x${string}`>;
1338
+ }
1339
+
1340
+ /**
1341
+ * UPGRADER_ROLE
1342
+ * view
1343
+ */
1344
+ async UPGRADER_ROLE(): Promise<`0x${string}`> {
1345
+ return this.contract.read.UPGRADER_ROLE() as Promise<`0x${string}`>;
1346
+ }
1347
+
1348
+ /**
1349
+ * UPGRADE_INTERFACE_VERSION
1350
+ * view
1351
+ */
1352
+ async UPGRADE_INTERFACE_VERSION(): Promise<string> {
1353
+ return this.contract.read.UPGRADE_INTERFACE_VERSION() as Promise<string>;
1354
+ }
1355
+
1356
+ /**
1357
+ * allowance
1358
+ * view
1359
+ */
1360
+ async allowance(owner: `0x${string}`, spender: `0x${string}`): Promise<bigint> {
1361
+ return this.contract.read.allowance([owner, spender] as const) as Promise<bigint>;
1362
+ }
1363
+
1364
+ /**
1365
+ * balanceOf
1366
+ * view
1367
+ */
1368
+ async balanceOf(account: `0x${string}`): Promise<bigint> {
1369
+ return this.contract.read.balanceOf([account] as const) as Promise<bigint>;
1370
+ }
1371
+
1372
+ /**
1373
+ * decimals
1374
+ * view
1375
+ */
1376
+ async decimals(): Promise<bigint> {
1377
+ return this.contract.read.decimals() as Promise<bigint>;
1378
+ }
1379
+
1380
+ /**
1381
+ * eip712Domain
1382
+ * view
1383
+ */
1384
+ async eip712Domain(): Promise<[`0x${string}`, string, string, bigint, `0x${string}`, `0x${string}`, bigint[]]> {
1385
+ return this.contract.read.eip712Domain() as Promise<[`0x${string}`, string, string, bigint, `0x${string}`, `0x${string}`, bigint[]]>;
1386
+ }
1387
+
1388
+ /**
1389
+ * enforceBlocklist
1390
+ * view
1391
+ */
1392
+ async enforceBlocklist(): Promise<boolean> {
1393
+ return this.contract.read.enforceBlocklist() as Promise<boolean>;
1394
+ }
1395
+
1396
+ /**
1397
+ * getRoleAdmin
1398
+ * view
1399
+ */
1400
+ async getRoleAdmin(role: `0x${string}`): Promise<`0x${string}`> {
1401
+ return this.contract.read.getRoleAdmin([role] as const) as Promise<`0x${string}`>;
1402
+ }
1403
+
1404
+ /**
1405
+ * hasRole
1406
+ * view
1407
+ */
1408
+ async hasRole(role: `0x${string}`, account: `0x${string}`): Promise<boolean> {
1409
+ return this.contract.read.hasRole([role, account] as const) as Promise<boolean>;
1410
+ }
1411
+
1412
+ /**
1413
+ * isBlocked
1414
+ * view
1415
+ */
1416
+ async isBlocked(account: `0x${string}`): Promise<boolean> {
1417
+ return this.contract.read.isBlocked([account] as const) as Promise<boolean>;
1418
+ }
1419
+
1420
+ /**
1421
+ * name
1422
+ * view
1423
+ */
1424
+ async name(): Promise<string> {
1425
+ return this.contract.read.name() as Promise<string>;
1426
+ }
1427
+
1428
+ /**
1429
+ * nonces
1430
+ * view
1431
+ */
1432
+ async nonces(owner: `0x${string}`): Promise<bigint> {
1433
+ return this.contract.read.nonces([owner] as const) as Promise<bigint>;
1434
+ }
1435
+
1436
+ /**
1437
+ * paused
1438
+ * view
1439
+ */
1440
+ async paused(): Promise<boolean> {
1441
+ return this.contract.read.paused() as Promise<boolean>;
1442
+ }
1443
+
1444
+ /**
1445
+ * proxiableUUID
1446
+ * view
1447
+ */
1448
+ async proxiableUUID(): Promise<`0x${string}`> {
1449
+ return this.contract.read.proxiableUUID() as Promise<`0x${string}`>;
1450
+ }
1451
+
1452
+ /**
1453
+ * supportsInterface
1454
+ * view
1455
+ */
1456
+ async supportsInterface(interfaceId: `0x${string}`): Promise<boolean> {
1457
+ return this.contract.read.supportsInterface([interfaceId] as const) as Promise<boolean>;
1458
+ }
1459
+
1460
+ /**
1461
+ * symbol
1462
+ * view
1463
+ */
1464
+ async symbol(): Promise<string> {
1465
+ return this.contract.read.symbol() as Promise<string>;
1466
+ }
1467
+
1468
+ /**
1469
+ * totalSupply
1470
+ * view
1471
+ */
1472
+ async totalSupply(): Promise<bigint> {
1473
+ return this.contract.read.totalSupply() as Promise<bigint>;
1474
+ }
1475
+
1476
+ /**
1477
+ * approve
1478
+ * nonpayable
1479
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1480
+ */
1481
+ async approve(spender: `0x${string}`, value: bigint, options?: {
1482
+ accessList?: import('viem').AccessList;
1483
+ authorizationList?: import('viem').AuthorizationList;
1484
+ chain?: import('viem').Chain | null;
1485
+ dataSuffix?: `0x${string}`;
1486
+ gas?: bigint;
1487
+ gasPrice?: bigint;
1488
+ maxFeePerGas?: bigint;
1489
+ maxPriorityFeePerGas?: bigint;
1490
+ nonce?: number;
1491
+ value?: bigint;
1492
+ }): Promise<`0x${string}`> {
1493
+ if (!this.contract.write) {
1494
+ throw new Error('Wallet client is required for write operations');
1495
+ }
1496
+ return this.contract.write.approve([spender, value] as const, options) as Promise<`0x${string}`>;
1497
+ }
1498
+
1499
+ /**
1500
+ * blockUser
1501
+ * nonpayable
1502
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1503
+ */
1504
+ async blockUser(account: `0x${string}`, options?: {
1505
+ accessList?: import('viem').AccessList;
1506
+ authorizationList?: import('viem').AuthorizationList;
1507
+ chain?: import('viem').Chain | null;
1508
+ dataSuffix?: `0x${string}`;
1509
+ gas?: bigint;
1510
+ gasPrice?: bigint;
1511
+ maxFeePerGas?: bigint;
1512
+ maxPriorityFeePerGas?: bigint;
1513
+ nonce?: number;
1514
+ value?: bigint;
1515
+ }): Promise<`0x${string}`> {
1516
+ if (!this.contract.write) {
1517
+ throw new Error('Wallet client is required for write operations');
1518
+ }
1519
+ return this.contract.write.blockUser([account] as const, options) as Promise<`0x${string}`>;
1520
+ }
1521
+
1522
+ /**
1523
+ * burn
1524
+ * nonpayable
1525
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1526
+ */
1527
+ async burn(value: bigint, options?: {
1528
+ accessList?: import('viem').AccessList;
1529
+ authorizationList?: import('viem').AuthorizationList;
1530
+ chain?: import('viem').Chain | null;
1531
+ dataSuffix?: `0x${string}`;
1532
+ gas?: bigint;
1533
+ gasPrice?: bigint;
1534
+ maxFeePerGas?: bigint;
1535
+ maxPriorityFeePerGas?: bigint;
1536
+ nonce?: number;
1537
+ value?: bigint;
1538
+ }): Promise<`0x${string}`> {
1539
+ if (!this.contract.write) {
1540
+ throw new Error('Wallet client is required for write operations');
1541
+ }
1542
+ return this.contract.write.burn([value] as const, options) as Promise<`0x${string}`>;
1543
+ }
1544
+
1545
+ /**
1546
+ * burnFrom
1547
+ * nonpayable
1548
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1549
+ */
1550
+ async burnFrom(account: `0x${string}`, value: bigint, 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<`0x${string}`> {
1562
+ if (!this.contract.write) {
1563
+ throw new Error('Wallet client is required for write operations');
1564
+ }
1565
+ return this.contract.write.burnFrom([account, value] as const, options) as Promise<`0x${string}`>;
1566
+ }
1567
+
1568
+ /**
1569
+ * grantRole
1570
+ * nonpayable
1571
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1572
+ */
1573
+ async grantRole(role: `0x${string}`, account: `0x${string}`, options?: {
1574
+ accessList?: import('viem').AccessList;
1575
+ authorizationList?: import('viem').AuthorizationList;
1576
+ chain?: import('viem').Chain | null;
1577
+ dataSuffix?: `0x${string}`;
1578
+ gas?: bigint;
1579
+ gasPrice?: bigint;
1580
+ maxFeePerGas?: bigint;
1581
+ maxPriorityFeePerGas?: bigint;
1582
+ nonce?: number;
1583
+ value?: bigint;
1584
+ }): Promise<`0x${string}`> {
1585
+ if (!this.contract.write) {
1586
+ throw new Error('Wallet client is required for write operations');
1587
+ }
1588
+ return this.contract.write.grantRole([role, account] as const, options) as Promise<`0x${string}`>;
1589
+ }
1590
+
1591
+ /**
1592
+ * initialize
1593
+ * nonpayable
1594
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1595
+ */
1596
+ async initialize(defaultAdmin: `0x${string}`, pauser: `0x${string}`, minter: `0x${string}`, upgrader: `0x${string}`, complianceAdmin: `0x${string}`, tokenName: string, tokenSymbol: string, options?: {
1597
+ accessList?: import('viem').AccessList;
1598
+ authorizationList?: import('viem').AuthorizationList;
1599
+ chain?: import('viem').Chain | null;
1600
+ dataSuffix?: `0x${string}`;
1601
+ gas?: bigint;
1602
+ gasPrice?: bigint;
1603
+ maxFeePerGas?: bigint;
1604
+ maxPriorityFeePerGas?: bigint;
1605
+ nonce?: number;
1606
+ value?: bigint;
1607
+ }): Promise<`0x${string}`> {
1608
+ if (!this.contract.write) {
1609
+ throw new Error('Wallet client is required for write operations');
1610
+ }
1611
+ return this.contract.write.initialize([defaultAdmin, pauser, minter, upgrader, complianceAdmin, tokenName, tokenSymbol] as const, options) as Promise<`0x${string}`>;
1612
+ }
1613
+
1614
+ /**
1615
+ * initializeCompliance
1616
+ * nonpayable
1617
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1618
+ */
1619
+ async initializeCompliance(complianceAdmin: `0x${string}`, options?: {
1620
+ accessList?: import('viem').AccessList;
1621
+ authorizationList?: import('viem').AuthorizationList;
1622
+ chain?: import('viem').Chain | null;
1623
+ dataSuffix?: `0x${string}`;
1624
+ gas?: bigint;
1625
+ gasPrice?: bigint;
1626
+ maxFeePerGas?: bigint;
1627
+ maxPriorityFeePerGas?: bigint;
1628
+ nonce?: number;
1629
+ value?: bigint;
1630
+ }): Promise<`0x${string}`> {
1631
+ if (!this.contract.write) {
1632
+ throw new Error('Wallet client is required for write operations');
1633
+ }
1634
+ return this.contract.write.initializeCompliance([complianceAdmin] as const, options) as Promise<`0x${string}`>;
1635
+ }
1636
+
1637
+ /**
1638
+ * mint
1639
+ * nonpayable
1640
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1641
+ */
1642
+ async mint(to: `0x${string}`, amount: bigint, options?: {
1643
+ accessList?: import('viem').AccessList;
1644
+ authorizationList?: import('viem').AuthorizationList;
1645
+ chain?: import('viem').Chain | null;
1646
+ dataSuffix?: `0x${string}`;
1647
+ gas?: bigint;
1648
+ gasPrice?: bigint;
1649
+ maxFeePerGas?: bigint;
1650
+ maxPriorityFeePerGas?: bigint;
1651
+ nonce?: number;
1652
+ value?: bigint;
1653
+ }): Promise<`0x${string}`> {
1654
+ if (!this.contract.write) {
1655
+ throw new Error('Wallet client is required for write operations');
1656
+ }
1657
+ return this.contract.write.mint([to, amount] as const, options) as Promise<`0x${string}`>;
1658
+ }
1659
+
1660
+ /**
1661
+ * pause
1662
+ * nonpayable
1663
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1664
+ */
1665
+ async pause(options?: {
1666
+ accessList?: import('viem').AccessList;
1667
+ authorizationList?: import('viem').AuthorizationList;
1668
+ chain?: import('viem').Chain | null;
1669
+ dataSuffix?: `0x${string}`;
1670
+ gas?: bigint;
1671
+ gasPrice?: bigint;
1672
+ maxFeePerGas?: bigint;
1673
+ maxPriorityFeePerGas?: bigint;
1674
+ nonce?: number;
1675
+ value?: bigint;
1676
+ }): Promise<`0x${string}`> {
1677
+ if (!this.contract.write) {
1678
+ throw new Error('Wallet client is required for write operations');
1679
+ }
1680
+ return this.contract.write.pause(options) as Promise<`0x${string}`>;
1681
+ }
1682
+
1683
+ /**
1684
+ * permit
1685
+ * nonpayable
1686
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1687
+ */
1688
+ async permit(owner: `0x${string}`, spender: `0x${string}`, value: bigint, deadline: bigint, v: bigint, r: `0x${string}`, s: `0x${string}`, options?: {
1689
+ accessList?: import('viem').AccessList;
1690
+ authorizationList?: import('viem').AuthorizationList;
1691
+ chain?: import('viem').Chain | null;
1692
+ dataSuffix?: `0x${string}`;
1693
+ gas?: bigint;
1694
+ gasPrice?: bigint;
1695
+ maxFeePerGas?: bigint;
1696
+ maxPriorityFeePerGas?: bigint;
1697
+ nonce?: number;
1698
+ value?: bigint;
1699
+ }): Promise<`0x${string}`> {
1700
+ if (!this.contract.write) {
1701
+ throw new Error('Wallet client is required for write operations');
1702
+ }
1703
+ return this.contract.write.permit([owner, spender, value, deadline, v, r, s] as const, options) as Promise<`0x${string}`>;
1704
+ }
1705
+
1706
+ /**
1707
+ * renounceRole
1708
+ * nonpayable
1709
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1710
+ */
1711
+ async renounceRole(role: `0x${string}`, callerConfirmation: `0x${string}`, options?: {
1712
+ accessList?: import('viem').AccessList;
1713
+ authorizationList?: import('viem').AuthorizationList;
1714
+ chain?: import('viem').Chain | null;
1715
+ dataSuffix?: `0x${string}`;
1716
+ gas?: bigint;
1717
+ gasPrice?: bigint;
1718
+ maxFeePerGas?: bigint;
1719
+ maxPriorityFeePerGas?: bigint;
1720
+ nonce?: number;
1721
+ value?: bigint;
1722
+ }): Promise<`0x${string}`> {
1723
+ if (!this.contract.write) {
1724
+ throw new Error('Wallet client is required for write operations');
1725
+ }
1726
+ return this.contract.write.renounceRole([role, callerConfirmation] as const, options) as Promise<`0x${string}`>;
1727
+ }
1728
+
1729
+ /**
1730
+ * revokeRole
1731
+ * nonpayable
1732
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1733
+ */
1734
+ async revokeRole(role: `0x${string}`, account: `0x${string}`, options?: {
1735
+ accessList?: import('viem').AccessList;
1736
+ authorizationList?: import('viem').AuthorizationList;
1737
+ chain?: import('viem').Chain | null;
1738
+ dataSuffix?: `0x${string}`;
1739
+ gas?: bigint;
1740
+ gasPrice?: bigint;
1741
+ maxFeePerGas?: bigint;
1742
+ maxPriorityFeePerGas?: bigint;
1743
+ nonce?: number;
1744
+ value?: bigint;
1745
+ }): Promise<`0x${string}`> {
1746
+ if (!this.contract.write) {
1747
+ throw new Error('Wallet client is required for write operations');
1748
+ }
1749
+ return this.contract.write.revokeRole([role, account] as const, options) as Promise<`0x${string}`>;
1750
+ }
1751
+
1752
+ /**
1753
+ * setEnforceBlocklist
1754
+ * nonpayable
1755
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1756
+ */
1757
+ async setEnforceBlocklist(enabled: boolean, options?: {
1758
+ accessList?: import('viem').AccessList;
1759
+ authorizationList?: import('viem').AuthorizationList;
1760
+ chain?: import('viem').Chain | null;
1761
+ dataSuffix?: `0x${string}`;
1762
+ gas?: bigint;
1763
+ gasPrice?: bigint;
1764
+ maxFeePerGas?: bigint;
1765
+ maxPriorityFeePerGas?: bigint;
1766
+ nonce?: number;
1767
+ value?: bigint;
1768
+ }): Promise<`0x${string}`> {
1769
+ if (!this.contract.write) {
1770
+ throw new Error('Wallet client is required for write operations');
1771
+ }
1772
+ return this.contract.write.setEnforceBlocklist([enabled] as const, options) as Promise<`0x${string}`>;
1773
+ }
1774
+
1775
+ /**
1776
+ * transfer
1777
+ * nonpayable
1778
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1779
+ */
1780
+ async transfer(to: `0x${string}`, value: bigint, options?: {
1781
+ accessList?: import('viem').AccessList;
1782
+ authorizationList?: import('viem').AuthorizationList;
1783
+ chain?: import('viem').Chain | null;
1784
+ dataSuffix?: `0x${string}`;
1785
+ gas?: bigint;
1786
+ gasPrice?: bigint;
1787
+ maxFeePerGas?: bigint;
1788
+ maxPriorityFeePerGas?: bigint;
1789
+ nonce?: number;
1790
+ value?: bigint;
1791
+ }): Promise<`0x${string}`> {
1792
+ if (!this.contract.write) {
1793
+ throw new Error('Wallet client is required for write operations');
1794
+ }
1795
+ return this.contract.write.transfer([to, value] as const, options) as Promise<`0x${string}`>;
1796
+ }
1797
+
1798
+ /**
1799
+ * transferFrom
1800
+ * nonpayable
1801
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1802
+ */
1803
+ async transferFrom(from: `0x${string}`, to: `0x${string}`, value: bigint, options?: {
1804
+ accessList?: import('viem').AccessList;
1805
+ authorizationList?: import('viem').AuthorizationList;
1806
+ chain?: import('viem').Chain | null;
1807
+ dataSuffix?: `0x${string}`;
1808
+ gas?: bigint;
1809
+ gasPrice?: bigint;
1810
+ maxFeePerGas?: bigint;
1811
+ maxPriorityFeePerGas?: bigint;
1812
+ nonce?: number;
1813
+ value?: bigint;
1814
+ }): Promise<`0x${string}`> {
1815
+ if (!this.contract.write) {
1816
+ throw new Error('Wallet client is required for write operations');
1817
+ }
1818
+ return this.contract.write.transferFrom([from, to, value] as const, options) as Promise<`0x${string}`>;
1819
+ }
1820
+
1821
+ /**
1822
+ * unblockUser
1823
+ * nonpayable
1824
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1825
+ */
1826
+ async unblockUser(account: `0x${string}`, options?: {
1827
+ accessList?: import('viem').AccessList;
1828
+ authorizationList?: import('viem').AuthorizationList;
1829
+ chain?: import('viem').Chain | null;
1830
+ dataSuffix?: `0x${string}`;
1831
+ gas?: bigint;
1832
+ gasPrice?: bigint;
1833
+ maxFeePerGas?: bigint;
1834
+ maxPriorityFeePerGas?: bigint;
1835
+ nonce?: number;
1836
+ value?: bigint;
1837
+ }): Promise<`0x${string}`> {
1838
+ if (!this.contract.write) {
1839
+ throw new Error('Wallet client is required for write operations');
1840
+ }
1841
+ return this.contract.write.unblockUser([account] as const, options) as Promise<`0x${string}`>;
1842
+ }
1843
+
1844
+ /**
1845
+ * unpause
1846
+ * nonpayable
1847
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1848
+ */
1849
+ async unpause(options?: {
1850
+ accessList?: import('viem').AccessList;
1851
+ authorizationList?: import('viem').AuthorizationList;
1852
+ chain?: import('viem').Chain | null;
1853
+ dataSuffix?: `0x${string}`;
1854
+ gas?: bigint;
1855
+ gasPrice?: bigint;
1856
+ maxFeePerGas?: bigint;
1857
+ maxPriorityFeePerGas?: bigint;
1858
+ nonce?: number;
1859
+ value?: bigint;
1860
+ }): Promise<`0x${string}`> {
1861
+ if (!this.contract.write) {
1862
+ throw new Error('Wallet client is required for write operations');
1863
+ }
1864
+ return this.contract.write.unpause(options) as Promise<`0x${string}`>;
1865
+ }
1866
+
1867
+ /**
1868
+ * upgradeToAndCall
1869
+ * payable
1870
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1871
+ */
1872
+ async upgradeToAndCall(newImplementation: `0x${string}`, data: `0x${string}`, options?: {
1873
+ accessList?: import('viem').AccessList;
1874
+ authorizationList?: import('viem').AuthorizationList;
1875
+ chain?: import('viem').Chain | null;
1876
+ dataSuffix?: `0x${string}`;
1877
+ gas?: bigint;
1878
+ gasPrice?: bigint;
1879
+ maxFeePerGas?: bigint;
1880
+ maxPriorityFeePerGas?: bigint;
1881
+ nonce?: number;
1882
+ value?: bigint;
1883
+ }): Promise<`0x${string}`> {
1884
+ if (!this.contract.write) {
1885
+ throw new Error('Wallet client is required for write operations');
1886
+ }
1887
+ return this.contract.write.upgradeToAndCall([newImplementation, data] as const, options) as Promise<`0x${string}`>;
1888
+ }
1889
+
1890
+
1891
+
1892
+ /**
1893
+ * Simulate contract write operations (dry-run without sending transaction)
1894
+ *
1895
+ * @example
1896
+ * const result = await contract.simulate.transfer('0x...', 1000n);
1897
+ * console.log('Gas estimate:', result.request.gas);
1898
+ * console.log('Would succeed:', result.result);
1899
+ */
1900
+ get simulate() {
1901
+ const contract = this.contract;
1902
+ if (!contract.simulate) {
1903
+ throw new Error('Public client is required for simulation');
1904
+ }
1905
+ return {
1906
+ /**
1907
+ * Simulate approve
1908
+ * Returns gas estimate and result without sending transaction
1909
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1910
+ */
1911
+ async approve(spender: `0x${string}`, value: bigint, options?: {
1912
+ accessList?: import('viem').AccessList;
1913
+ authorizationList?: import('viem').AuthorizationList;
1914
+ chain?: import('viem').Chain | null;
1915
+ dataSuffix?: `0x${string}`;
1916
+ gas?: bigint;
1917
+ gasPrice?: bigint;
1918
+ maxFeePerGas?: bigint;
1919
+ maxPriorityFeePerGas?: bigint;
1920
+ nonce?: number;
1921
+ value?: bigint;
1922
+ }): Promise<boolean> {
1923
+ return contract.simulate.approve([spender, value] as const, options) as Promise<boolean>;
1924
+ },
1925
+ /**
1926
+ * Simulate blockUser
1927
+ * Returns gas estimate and result without sending transaction
1928
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1929
+ */
1930
+ async blockUser(account: `0x${string}`, options?: {
1931
+ accessList?: import('viem').AccessList;
1932
+ authorizationList?: import('viem').AuthorizationList;
1933
+ chain?: import('viem').Chain | null;
1934
+ dataSuffix?: `0x${string}`;
1935
+ gas?: bigint;
1936
+ gasPrice?: bigint;
1937
+ maxFeePerGas?: bigint;
1938
+ maxPriorityFeePerGas?: bigint;
1939
+ nonce?: number;
1940
+ value?: bigint;
1941
+ }): Promise<void> {
1942
+ return contract.simulate.blockUser([account] as const, options) as Promise<void>;
1943
+ },
1944
+ /**
1945
+ * Simulate burn
1946
+ * Returns gas estimate and result without sending transaction
1947
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1948
+ */
1949
+ async burn(value: bigint, options?: {
1950
+ accessList?: import('viem').AccessList;
1951
+ authorizationList?: import('viem').AuthorizationList;
1952
+ chain?: import('viem').Chain | null;
1953
+ dataSuffix?: `0x${string}`;
1954
+ gas?: bigint;
1955
+ gasPrice?: bigint;
1956
+ maxFeePerGas?: bigint;
1957
+ maxPriorityFeePerGas?: bigint;
1958
+ nonce?: number;
1959
+ value?: bigint;
1960
+ }): Promise<void> {
1961
+ return contract.simulate.burn([value] as const, options) as Promise<void>;
1962
+ },
1963
+ /**
1964
+ * Simulate burnFrom
1965
+ * Returns gas estimate and result without sending transaction
1966
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1967
+ */
1968
+ async burnFrom(account: `0x${string}`, value: bigint, options?: {
1969
+ accessList?: import('viem').AccessList;
1970
+ authorizationList?: import('viem').AuthorizationList;
1971
+ chain?: import('viem').Chain | null;
1972
+ dataSuffix?: `0x${string}`;
1973
+ gas?: bigint;
1974
+ gasPrice?: bigint;
1975
+ maxFeePerGas?: bigint;
1976
+ maxPriorityFeePerGas?: bigint;
1977
+ nonce?: number;
1978
+ value?: bigint;
1979
+ }): Promise<void> {
1980
+ return contract.simulate.burnFrom([account, value] as const, options) as Promise<void>;
1981
+ },
1982
+ /**
1983
+ * Simulate grantRole
1984
+ * Returns gas estimate and result without sending transaction
1985
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1986
+ */
1987
+ async grantRole(role: `0x${string}`, account: `0x${string}`, options?: {
1988
+ accessList?: import('viem').AccessList;
1989
+ authorizationList?: import('viem').AuthorizationList;
1990
+ chain?: import('viem').Chain | null;
1991
+ dataSuffix?: `0x${string}`;
1992
+ gas?: bigint;
1993
+ gasPrice?: bigint;
1994
+ maxFeePerGas?: bigint;
1995
+ maxPriorityFeePerGas?: bigint;
1996
+ nonce?: number;
1997
+ value?: bigint;
1998
+ }): Promise<void> {
1999
+ return contract.simulate.grantRole([role, account] as const, options) as Promise<void>;
2000
+ },
2001
+ /**
2002
+ * Simulate initialize
2003
+ * Returns gas estimate and result without sending transaction
2004
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2005
+ */
2006
+ async initialize(defaultAdmin: `0x${string}`, pauser: `0x${string}`, minter: `0x${string}`, upgrader: `0x${string}`, complianceAdmin: `0x${string}`, tokenName: string, tokenSymbol: string, options?: {
2007
+ accessList?: import('viem').AccessList;
2008
+ authorizationList?: import('viem').AuthorizationList;
2009
+ chain?: import('viem').Chain | null;
2010
+ dataSuffix?: `0x${string}`;
2011
+ gas?: bigint;
2012
+ gasPrice?: bigint;
2013
+ maxFeePerGas?: bigint;
2014
+ maxPriorityFeePerGas?: bigint;
2015
+ nonce?: number;
2016
+ value?: bigint;
2017
+ }): Promise<void> {
2018
+ return contract.simulate.initialize([defaultAdmin, pauser, minter, upgrader, complianceAdmin, tokenName, tokenSymbol] as const, options) as Promise<void>;
2019
+ },
2020
+ /**
2021
+ * Simulate initializeCompliance
2022
+ * Returns gas estimate and result without sending transaction
2023
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2024
+ */
2025
+ async initializeCompliance(complianceAdmin: `0x${string}`, options?: {
2026
+ accessList?: import('viem').AccessList;
2027
+ authorizationList?: import('viem').AuthorizationList;
2028
+ chain?: import('viem').Chain | null;
2029
+ dataSuffix?: `0x${string}`;
2030
+ gas?: bigint;
2031
+ gasPrice?: bigint;
2032
+ maxFeePerGas?: bigint;
2033
+ maxPriorityFeePerGas?: bigint;
2034
+ nonce?: number;
2035
+ value?: bigint;
2036
+ }): Promise<void> {
2037
+ return contract.simulate.initializeCompliance([complianceAdmin] as const, options) as Promise<void>;
2038
+ },
2039
+ /**
2040
+ * Simulate mint
2041
+ * Returns gas estimate and result without sending transaction
2042
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2043
+ */
2044
+ async mint(to: `0x${string}`, amount: bigint, options?: {
2045
+ accessList?: import('viem').AccessList;
2046
+ authorizationList?: import('viem').AuthorizationList;
2047
+ chain?: import('viem').Chain | null;
2048
+ dataSuffix?: `0x${string}`;
2049
+ gas?: bigint;
2050
+ gasPrice?: bigint;
2051
+ maxFeePerGas?: bigint;
2052
+ maxPriorityFeePerGas?: bigint;
2053
+ nonce?: number;
2054
+ value?: bigint;
2055
+ }): Promise<void> {
2056
+ return contract.simulate.mint([to, amount] as const, options) as Promise<void>;
2057
+ },
2058
+ /**
2059
+ * Simulate pause
2060
+ * Returns gas estimate and result without sending transaction
2061
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2062
+ */
2063
+ async pause(options?: {
2064
+ accessList?: import('viem').AccessList;
2065
+ authorizationList?: import('viem').AuthorizationList;
2066
+ chain?: import('viem').Chain | null;
2067
+ dataSuffix?: `0x${string}`;
2068
+ gas?: bigint;
2069
+ gasPrice?: bigint;
2070
+ maxFeePerGas?: bigint;
2071
+ maxPriorityFeePerGas?: bigint;
2072
+ nonce?: number;
2073
+ value?: bigint;
2074
+ }): Promise<void> {
2075
+ return contract.simulate.pause(options) as Promise<void>;
2076
+ },
2077
+ /**
2078
+ * Simulate permit
2079
+ * Returns gas estimate and result without sending transaction
2080
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2081
+ */
2082
+ async permit(owner: `0x${string}`, spender: `0x${string}`, value: bigint, deadline: bigint, v: bigint, r: `0x${string}`, s: `0x${string}`, options?: {
2083
+ accessList?: import('viem').AccessList;
2084
+ authorizationList?: import('viem').AuthorizationList;
2085
+ chain?: import('viem').Chain | null;
2086
+ dataSuffix?: `0x${string}`;
2087
+ gas?: bigint;
2088
+ gasPrice?: bigint;
2089
+ maxFeePerGas?: bigint;
2090
+ maxPriorityFeePerGas?: bigint;
2091
+ nonce?: number;
2092
+ value?: bigint;
2093
+ }): Promise<void> {
2094
+ return contract.simulate.permit([owner, spender, value, deadline, v, r, s] as const, options) as Promise<void>;
2095
+ },
2096
+ /**
2097
+ * Simulate renounceRole
2098
+ * Returns gas estimate and result without sending transaction
2099
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2100
+ */
2101
+ async renounceRole(role: `0x${string}`, callerConfirmation: `0x${string}`, options?: {
2102
+ accessList?: import('viem').AccessList;
2103
+ authorizationList?: import('viem').AuthorizationList;
2104
+ chain?: import('viem').Chain | null;
2105
+ dataSuffix?: `0x${string}`;
2106
+ gas?: bigint;
2107
+ gasPrice?: bigint;
2108
+ maxFeePerGas?: bigint;
2109
+ maxPriorityFeePerGas?: bigint;
2110
+ nonce?: number;
2111
+ value?: bigint;
2112
+ }): Promise<void> {
2113
+ return contract.simulate.renounceRole([role, callerConfirmation] as const, options) as Promise<void>;
2114
+ },
2115
+ /**
2116
+ * Simulate revokeRole
2117
+ * Returns gas estimate and result without sending transaction
2118
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2119
+ */
2120
+ async revokeRole(role: `0x${string}`, account: `0x${string}`, options?: {
2121
+ accessList?: import('viem').AccessList;
2122
+ authorizationList?: import('viem').AuthorizationList;
2123
+ chain?: import('viem').Chain | null;
2124
+ dataSuffix?: `0x${string}`;
2125
+ gas?: bigint;
2126
+ gasPrice?: bigint;
2127
+ maxFeePerGas?: bigint;
2128
+ maxPriorityFeePerGas?: bigint;
2129
+ nonce?: number;
2130
+ value?: bigint;
2131
+ }): Promise<void> {
2132
+ return contract.simulate.revokeRole([role, account] as const, options) as Promise<void>;
2133
+ },
2134
+ /**
2135
+ * Simulate setEnforceBlocklist
2136
+ * Returns gas estimate and result without sending transaction
2137
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2138
+ */
2139
+ async setEnforceBlocklist(enabled: boolean, options?: {
2140
+ accessList?: import('viem').AccessList;
2141
+ authorizationList?: import('viem').AuthorizationList;
2142
+ chain?: import('viem').Chain | null;
2143
+ dataSuffix?: `0x${string}`;
2144
+ gas?: bigint;
2145
+ gasPrice?: bigint;
2146
+ maxFeePerGas?: bigint;
2147
+ maxPriorityFeePerGas?: bigint;
2148
+ nonce?: number;
2149
+ value?: bigint;
2150
+ }): Promise<void> {
2151
+ return contract.simulate.setEnforceBlocklist([enabled] as const, options) as Promise<void>;
2152
+ },
2153
+ /**
2154
+ * Simulate transfer
2155
+ * Returns gas estimate and result without sending transaction
2156
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2157
+ */
2158
+ async transfer(to: `0x${string}`, value: bigint, options?: {
2159
+ accessList?: import('viem').AccessList;
2160
+ authorizationList?: import('viem').AuthorizationList;
2161
+ chain?: import('viem').Chain | null;
2162
+ dataSuffix?: `0x${string}`;
2163
+ gas?: bigint;
2164
+ gasPrice?: bigint;
2165
+ maxFeePerGas?: bigint;
2166
+ maxPriorityFeePerGas?: bigint;
2167
+ nonce?: number;
2168
+ value?: bigint;
2169
+ }): Promise<boolean> {
2170
+ return contract.simulate.transfer([to, value] as const, options) as Promise<boolean>;
2171
+ },
2172
+ /**
2173
+ * Simulate transferFrom
2174
+ * Returns gas estimate and result without sending transaction
2175
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2176
+ */
2177
+ async transferFrom(from: `0x${string}`, to: `0x${string}`, value: bigint, options?: {
2178
+ accessList?: import('viem').AccessList;
2179
+ authorizationList?: import('viem').AuthorizationList;
2180
+ chain?: import('viem').Chain | null;
2181
+ dataSuffix?: `0x${string}`;
2182
+ gas?: bigint;
2183
+ gasPrice?: bigint;
2184
+ maxFeePerGas?: bigint;
2185
+ maxPriorityFeePerGas?: bigint;
2186
+ nonce?: number;
2187
+ value?: bigint;
2188
+ }): Promise<boolean> {
2189
+ return contract.simulate.transferFrom([from, to, value] as const, options) as Promise<boolean>;
2190
+ },
2191
+ /**
2192
+ * Simulate unblockUser
2193
+ * Returns gas estimate and result without sending transaction
2194
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2195
+ */
2196
+ async unblockUser(account: `0x${string}`, options?: {
2197
+ accessList?: import('viem').AccessList;
2198
+ authorizationList?: import('viem').AuthorizationList;
2199
+ chain?: import('viem').Chain | null;
2200
+ dataSuffix?: `0x${string}`;
2201
+ gas?: bigint;
2202
+ gasPrice?: bigint;
2203
+ maxFeePerGas?: bigint;
2204
+ maxPriorityFeePerGas?: bigint;
2205
+ nonce?: number;
2206
+ value?: bigint;
2207
+ }): Promise<void> {
2208
+ return contract.simulate.unblockUser([account] as const, options) as Promise<void>;
2209
+ },
2210
+ /**
2211
+ * Simulate unpause
2212
+ * Returns gas estimate and result without sending transaction
2213
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2214
+ */
2215
+ async unpause(options?: {
2216
+ accessList?: import('viem').AccessList;
2217
+ authorizationList?: import('viem').AuthorizationList;
2218
+ chain?: import('viem').Chain | null;
2219
+ dataSuffix?: `0x${string}`;
2220
+ gas?: bigint;
2221
+ gasPrice?: bigint;
2222
+ maxFeePerGas?: bigint;
2223
+ maxPriorityFeePerGas?: bigint;
2224
+ nonce?: number;
2225
+ value?: bigint;
2226
+ }): Promise<void> {
2227
+ return contract.simulate.unpause(options) as Promise<void>;
2228
+ },
2229
+ /**
2230
+ * Simulate upgradeToAndCall
2231
+ * Returns gas estimate and result without sending transaction
2232
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
2233
+ */
2234
+ async upgradeToAndCall(newImplementation: `0x${string}`, data: `0x${string}`, options?: {
2235
+ accessList?: import('viem').AccessList;
2236
+ authorizationList?: import('viem').AuthorizationList;
2237
+ chain?: import('viem').Chain | null;
2238
+ dataSuffix?: `0x${string}`;
2239
+ gas?: bigint;
2240
+ gasPrice?: bigint;
2241
+ maxFeePerGas?: bigint;
2242
+ maxPriorityFeePerGas?: bigint;
2243
+ nonce?: number;
2244
+ value?: bigint;
2245
+ }): Promise<void> {
2246
+ return contract.simulate.upgradeToAndCall([newImplementation, data] as const, options) as Promise<void>;
2247
+ }
2248
+ };
2249
+ }
2250
+
2251
+ /**
2252
+ * Watch contract events
2253
+ *
2254
+ * @example
2255
+ * // Watch all Transfer events
2256
+ * const unwatch = contract.watch.Transfer((event) => {
2257
+ * console.log('Transfer:', event);
2258
+ * });
2259
+ *
2260
+ * // Stop watching
2261
+ * unwatch();
2262
+ */
2263
+ get watch() {
2264
+ return {
2265
+ /**
2266
+ * Watch Approval events
2267
+ * @param callback Function to call when event is emitted
2268
+ * @param filter Optional filter for indexed parameters
2269
+ * @returns Unwatch function to stop listening
2270
+ */
2271
+ Approval: (callback: (event: { owner: `0x${string}`; spender: `0x${string}`; value: bigint }) => void, filter?: { owner: `0x${string}`; spender: `0x${string}` }) => {
2272
+ return this.publicClient.watchContractEvent({
2273
+ address: this.contractAddress,
2274
+ abi: LatamStable_jsonAbi,
2275
+ eventName: 'Approval',
2276
+ args: filter,
2277
+ onLogs: (logs: any[]) => {
2278
+ logs.forEach((log: any) => {
2279
+ callback(log.args as any);
2280
+ });
2281
+ },
2282
+ }) as () => void;
2283
+ },
2284
+ /**
2285
+ * Watch BlocklistEnforcementSet events
2286
+ * @param callback Function to call when event is emitted
2287
+ * @param filter Optional filter for indexed parameters
2288
+ * @returns Unwatch function to stop listening
2289
+ */
2290
+ BlocklistEnforcementSet: (callback: (event: { enabled: boolean }) => void, filter?: { enabled: boolean }) => {
2291
+ return this.publicClient.watchContractEvent({
2292
+ address: this.contractAddress,
2293
+ abi: LatamStable_jsonAbi,
2294
+ eventName: 'BlocklistEnforcementSet',
2295
+ args: filter,
2296
+ onLogs: (logs: any[]) => {
2297
+ logs.forEach((log: any) => {
2298
+ callback(log.args as any);
2299
+ });
2300
+ },
2301
+ }) as () => void;
2302
+ },
2303
+ /**
2304
+ * Watch EIP712DomainChanged events
2305
+ * @param callback Function to call when event is emitted
2306
+ * @param filter Optional filter for indexed parameters
2307
+ * @returns Unwatch function to stop listening
2308
+ */
2309
+ EIP712DomainChanged: (callback: (event: { }) => void) => {
2310
+ return this.publicClient.watchContractEvent({
2311
+ address: this.contractAddress,
2312
+ abi: LatamStable_jsonAbi,
2313
+ eventName: 'EIP712DomainChanged',
2314
+
2315
+ onLogs: (logs: any[]) => {
2316
+ logs.forEach((log: any) => {
2317
+ callback(log.args as any);
2318
+ });
2319
+ },
2320
+ }) as () => void;
2321
+ },
2322
+ /**
2323
+ * Watch Initialized events
2324
+ * @param callback Function to call when event is emitted
2325
+ * @param filter Optional filter for indexed parameters
2326
+ * @returns Unwatch function to stop listening
2327
+ */
2328
+ Initialized: (callback: (event: { version: bigint }) => void) => {
2329
+ return this.publicClient.watchContractEvent({
2330
+ address: this.contractAddress,
2331
+ abi: LatamStable_jsonAbi,
2332
+ eventName: 'Initialized',
2333
+
2334
+ onLogs: (logs: any[]) => {
2335
+ logs.forEach((log: any) => {
2336
+ callback(log.args as any);
2337
+ });
2338
+ },
2339
+ }) as () => void;
2340
+ },
2341
+ /**
2342
+ * Watch Paused events
2343
+ * @param callback Function to call when event is emitted
2344
+ * @param filter Optional filter for indexed parameters
2345
+ * @returns Unwatch function to stop listening
2346
+ */
2347
+ Paused: (callback: (event: { account: `0x${string}` }) => void) => {
2348
+ return this.publicClient.watchContractEvent({
2349
+ address: this.contractAddress,
2350
+ abi: LatamStable_jsonAbi,
2351
+ eventName: 'Paused',
2352
+
2353
+ onLogs: (logs: any[]) => {
2354
+ logs.forEach((log: any) => {
2355
+ callback(log.args as any);
2356
+ });
2357
+ },
2358
+ }) as () => void;
2359
+ },
2360
+ /**
2361
+ * Watch RoleAdminChanged events
2362
+ * @param callback Function to call when event is emitted
2363
+ * @param filter Optional filter for indexed parameters
2364
+ * @returns Unwatch function to stop listening
2365
+ */
2366
+ RoleAdminChanged: (callback: (event: { role: `0x${string}`; previousAdminRole: `0x${string}`; newAdminRole: `0x${string}` }) => void, filter?: { role: `0x${string}`; previousAdminRole: `0x${string}`; newAdminRole: `0x${string}` }) => {
2367
+ return this.publicClient.watchContractEvent({
2368
+ address: this.contractAddress,
2369
+ abi: LatamStable_jsonAbi,
2370
+ eventName: 'RoleAdminChanged',
2371
+ args: filter,
2372
+ onLogs: (logs: any[]) => {
2373
+ logs.forEach((log: any) => {
2374
+ callback(log.args as any);
2375
+ });
2376
+ },
2377
+ }) as () => void;
2378
+ },
2379
+ /**
2380
+ * Watch RoleGranted events
2381
+ * @param callback Function to call when event is emitted
2382
+ * @param filter Optional filter for indexed parameters
2383
+ * @returns Unwatch function to stop listening
2384
+ */
2385
+ RoleGranted: (callback: (event: { role: `0x${string}`; account: `0x${string}`; sender: `0x${string}` }) => void, filter?: { role: `0x${string}`; account: `0x${string}`; sender: `0x${string}` }) => {
2386
+ return this.publicClient.watchContractEvent({
2387
+ address: this.contractAddress,
2388
+ abi: LatamStable_jsonAbi,
2389
+ eventName: 'RoleGranted',
2390
+ args: filter,
2391
+ onLogs: (logs: any[]) => {
2392
+ logs.forEach((log: any) => {
2393
+ callback(log.args as any);
2394
+ });
2395
+ },
2396
+ }) as () => void;
2397
+ },
2398
+ /**
2399
+ * Watch RoleRevoked events
2400
+ * @param callback Function to call when event is emitted
2401
+ * @param filter Optional filter for indexed parameters
2402
+ * @returns Unwatch function to stop listening
2403
+ */
2404
+ RoleRevoked: (callback: (event: { role: `0x${string}`; account: `0x${string}`; sender: `0x${string}` }) => void, filter?: { role: `0x${string}`; account: `0x${string}`; sender: `0x${string}` }) => {
2405
+ return this.publicClient.watchContractEvent({
2406
+ address: this.contractAddress,
2407
+ abi: LatamStable_jsonAbi,
2408
+ eventName: 'RoleRevoked',
2409
+ args: filter,
2410
+ onLogs: (logs: any[]) => {
2411
+ logs.forEach((log: any) => {
2412
+ callback(log.args as any);
2413
+ });
2414
+ },
2415
+ }) as () => void;
2416
+ },
2417
+ /**
2418
+ * Watch Transfer events
2419
+ * @param callback Function to call when event is emitted
2420
+ * @param filter Optional filter for indexed parameters
2421
+ * @returns Unwatch function to stop listening
2422
+ */
2423
+ Transfer: (callback: (event: { from: `0x${string}`; to: `0x${string}`; value: bigint }) => void, filter?: { from: `0x${string}`; to: `0x${string}` }) => {
2424
+ return this.publicClient.watchContractEvent({
2425
+ address: this.contractAddress,
2426
+ abi: LatamStable_jsonAbi,
2427
+ eventName: 'Transfer',
2428
+ args: filter,
2429
+ onLogs: (logs: any[]) => {
2430
+ logs.forEach((log: any) => {
2431
+ callback(log.args as any);
2432
+ });
2433
+ },
2434
+ }) as () => void;
2435
+ },
2436
+ /**
2437
+ * Watch Unpaused events
2438
+ * @param callback Function to call when event is emitted
2439
+ * @param filter Optional filter for indexed parameters
2440
+ * @returns Unwatch function to stop listening
2441
+ */
2442
+ Unpaused: (callback: (event: { account: `0x${string}` }) => void) => {
2443
+ return this.publicClient.watchContractEvent({
2444
+ address: this.contractAddress,
2445
+ abi: LatamStable_jsonAbi,
2446
+ eventName: 'Unpaused',
2447
+
2448
+ onLogs: (logs: any[]) => {
2449
+ logs.forEach((log: any) => {
2450
+ callback(log.args as any);
2451
+ });
2452
+ },
2453
+ }) as () => void;
2454
+ },
2455
+ /**
2456
+ * Watch Upgraded events
2457
+ * @param callback Function to call when event is emitted
2458
+ * @param filter Optional filter for indexed parameters
2459
+ * @returns Unwatch function to stop listening
2460
+ */
2461
+ Upgraded: (callback: (event: { implementation: `0x${string}` }) => void, filter?: { implementation: `0x${string}` }) => {
2462
+ return this.publicClient.watchContractEvent({
2463
+ address: this.contractAddress,
2464
+ abi: LatamStable_jsonAbi,
2465
+ eventName: 'Upgraded',
2466
+ args: filter,
2467
+ onLogs: (logs: any[]) => {
2468
+ logs.forEach((log: any) => {
2469
+ callback(log.args as any);
2470
+ });
2471
+ },
2472
+ }) as () => void;
2473
+ },
2474
+ /**
2475
+ * Watch UserBlocked events
2476
+ * @param callback Function to call when event is emitted
2477
+ * @param filter Optional filter for indexed parameters
2478
+ * @returns Unwatch function to stop listening
2479
+ */
2480
+ UserBlocked: (callback: (event: { account: `0x${string}` }) => void, filter?: { account: `0x${string}` }) => {
2481
+ return this.publicClient.watchContractEvent({
2482
+ address: this.contractAddress,
2483
+ abi: LatamStable_jsonAbi,
2484
+ eventName: 'UserBlocked',
2485
+ args: filter,
2486
+ onLogs: (logs: any[]) => {
2487
+ logs.forEach((log: any) => {
2488
+ callback(log.args as any);
2489
+ });
2490
+ },
2491
+ }) as () => void;
2492
+ },
2493
+ /**
2494
+ * Watch UserUnblocked events
2495
+ * @param callback Function to call when event is emitted
2496
+ * @param filter Optional filter for indexed parameters
2497
+ * @returns Unwatch function to stop listening
2498
+ */
2499
+ UserUnblocked: (callback: (event: { account: `0x${string}` }) => void, filter?: { account: `0x${string}` }) => {
2500
+ return this.publicClient.watchContractEvent({
2501
+ address: this.contractAddress,
2502
+ abi: LatamStable_jsonAbi,
2503
+ eventName: 'UserUnblocked',
2504
+ args: filter,
2505
+ onLogs: (logs: any[]) => {
2506
+ logs.forEach((log: any) => {
2507
+ callback(log.args as any);
2508
+ });
2509
+ },
2510
+ }) as () => void;
2511
+ }
2512
+ };
2513
+ }
2514
+ }