@gitmyabi/number 0.0.0-stage → 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,2110 @@
1
+ import type { Abi, Address, PublicClient, WalletClient, GetContractReturnType } from 'viem';
2
+ import { getContract } from 'viem';
3
+
4
+
5
+ /**
6
+ * LazySovereignNFT.MintConfig struct type
7
+ */
8
+ export type LazySovereignNFT_MintConfig = {
9
+ numberOfTokens: bigint;
10
+ baseURI: string;
11
+ lockedMetadata: boolean;
12
+ };
13
+ /**
14
+ * LazySovereignNFT_json ABI
15
+ *
16
+ * This ABI is typed using viem's type system for full type safety.
17
+ */
18
+ export const LazySovereignNFT_jsonAbi = [
19
+ {
20
+ "anonymous": false,
21
+ "inputs": [
22
+ {
23
+ "indexed": true,
24
+ "internalType": "address",
25
+ "name": "owner",
26
+ "type": "address"
27
+ },
28
+ {
29
+ "indexed": true,
30
+ "internalType": "address",
31
+ "name": "approved",
32
+ "type": "address"
33
+ },
34
+ {
35
+ "indexed": true,
36
+ "internalType": "uint256",
37
+ "name": "tokenId",
38
+ "type": "uint256"
39
+ }
40
+ ],
41
+ "name": "Approval",
42
+ "type": "event"
43
+ },
44
+ {
45
+ "anonymous": false,
46
+ "inputs": [
47
+ {
48
+ "indexed": true,
49
+ "internalType": "address",
50
+ "name": "owner",
51
+ "type": "address"
52
+ },
53
+ {
54
+ "indexed": true,
55
+ "internalType": "address",
56
+ "name": "operator",
57
+ "type": "address"
58
+ },
59
+ {
60
+ "indexed": false,
61
+ "internalType": "bool",
62
+ "name": "approved",
63
+ "type": "bool"
64
+ }
65
+ ],
66
+ "name": "ApprovalForAll",
67
+ "type": "event"
68
+ },
69
+ {
70
+ "anonymous": false,
71
+ "inputs": [
72
+ {
73
+ "indexed": true,
74
+ "internalType": "address",
75
+ "name": "user",
76
+ "type": "address"
77
+ }
78
+ ],
79
+ "name": "ContractDisabled",
80
+ "type": "event"
81
+ },
82
+ {
83
+ "anonymous": false,
84
+ "inputs": [
85
+ {
86
+ "indexed": false,
87
+ "internalType": "uint8",
88
+ "name": "version",
89
+ "type": "uint8"
90
+ }
91
+ ],
92
+ "name": "Initialized",
93
+ "type": "event"
94
+ },
95
+ {
96
+ "anonymous": false,
97
+ "inputs": [
98
+ {
99
+ "indexed": false,
100
+ "internalType": "string",
101
+ "name": "baseURI",
102
+ "type": "string"
103
+ }
104
+ ],
105
+ "name": "MetadataLocked",
106
+ "type": "event"
107
+ },
108
+ {
109
+ "anonymous": false,
110
+ "inputs": [
111
+ {
112
+ "indexed": false,
113
+ "internalType": "string",
114
+ "name": "baseURI",
115
+ "type": "string"
116
+ }
117
+ ],
118
+ "name": "MetadataUpdated",
119
+ "type": "event"
120
+ },
121
+ {
122
+ "anonymous": false,
123
+ "inputs": [
124
+ {
125
+ "indexed": true,
126
+ "internalType": "address",
127
+ "name": "previousOwner",
128
+ "type": "address"
129
+ },
130
+ {
131
+ "indexed": true,
132
+ "internalType": "address",
133
+ "name": "newOwner",
134
+ "type": "address"
135
+ }
136
+ ],
137
+ "name": "OwnershipTransferred",
138
+ "type": "event"
139
+ },
140
+ {
141
+ "anonymous": false,
142
+ "inputs": [
143
+ {
144
+ "indexed": true,
145
+ "internalType": "uint256",
146
+ "name": "numberOfTokens",
147
+ "type": "uint256"
148
+ },
149
+ {
150
+ "indexed": false,
151
+ "internalType": "string",
152
+ "name": "baseURI",
153
+ "type": "string"
154
+ }
155
+ ],
156
+ "name": "PrepareMint",
157
+ "type": "event"
158
+ },
159
+ {
160
+ "anonymous": false,
161
+ "inputs": [
162
+ {
163
+ "indexed": true,
164
+ "internalType": "uint256",
165
+ "name": "tokenId",
166
+ "type": "uint256"
167
+ },
168
+ {
169
+ "indexed": false,
170
+ "internalType": "string",
171
+ "name": "metadataUri",
172
+ "type": "string"
173
+ }
174
+ ],
175
+ "name": "TokenURIUpdated",
176
+ "type": "event"
177
+ },
178
+ {
179
+ "anonymous": false,
180
+ "inputs": [
181
+ {
182
+ "indexed": true,
183
+ "internalType": "address",
184
+ "name": "from",
185
+ "type": "address"
186
+ },
187
+ {
188
+ "indexed": true,
189
+ "internalType": "address",
190
+ "name": "to",
191
+ "type": "address"
192
+ },
193
+ {
194
+ "indexed": true,
195
+ "internalType": "uint256",
196
+ "name": "tokenId",
197
+ "type": "uint256"
198
+ }
199
+ ],
200
+ "name": "Transfer",
201
+ "type": "event"
202
+ },
203
+ {
204
+ "inputs": [
205
+ {
206
+ "internalType": "address",
207
+ "name": "to",
208
+ "type": "address"
209
+ },
210
+ {
211
+ "internalType": "uint256",
212
+ "name": "tokenId",
213
+ "type": "uint256"
214
+ }
215
+ ],
216
+ "name": "approve",
217
+ "outputs": [],
218
+ "stateMutability": "nonpayable",
219
+ "type": "function"
220
+ },
221
+ {
222
+ "inputs": [
223
+ {
224
+ "internalType": "address",
225
+ "name": "owner",
226
+ "type": "address"
227
+ }
228
+ ],
229
+ "name": "balanceOf",
230
+ "outputs": [
231
+ {
232
+ "internalType": "uint256",
233
+ "name": "",
234
+ "type": "uint256"
235
+ }
236
+ ],
237
+ "stateMutability": "view",
238
+ "type": "function"
239
+ },
240
+ {
241
+ "inputs": [
242
+ {
243
+ "internalType": "uint256",
244
+ "name": "tokenId",
245
+ "type": "uint256"
246
+ }
247
+ ],
248
+ "name": "burn",
249
+ "outputs": [],
250
+ "stateMutability": "nonpayable",
251
+ "type": "function"
252
+ },
253
+ {
254
+ "inputs": [
255
+ {
256
+ "internalType": "uint256",
257
+ "name": "_tokenId",
258
+ "type": "uint256"
259
+ }
260
+ ],
261
+ "name": "deleteToken",
262
+ "outputs": [],
263
+ "stateMutability": "nonpayable",
264
+ "type": "function"
265
+ },
266
+ {
267
+ "inputs": [],
268
+ "name": "disableContract",
269
+ "outputs": [],
270
+ "stateMutability": "nonpayable",
271
+ "type": "function"
272
+ },
273
+ {
274
+ "inputs": [],
275
+ "name": "disabled",
276
+ "outputs": [
277
+ {
278
+ "internalType": "bool",
279
+ "name": "",
280
+ "type": "bool"
281
+ }
282
+ ],
283
+ "stateMutability": "view",
284
+ "type": "function"
285
+ },
286
+ {
287
+ "inputs": [
288
+ {
289
+ "internalType": "uint256",
290
+ "name": "tokenId",
291
+ "type": "uint256"
292
+ }
293
+ ],
294
+ "name": "getApproved",
295
+ "outputs": [
296
+ {
297
+ "internalType": "address",
298
+ "name": "",
299
+ "type": "address"
300
+ }
301
+ ],
302
+ "stateMutability": "view",
303
+ "type": "function"
304
+ },
305
+ {
306
+ "inputs": [],
307
+ "name": "getDefaultRoyaltyPercentage",
308
+ "outputs": [
309
+ {
310
+ "internalType": "uint256",
311
+ "name": "",
312
+ "type": "uint256"
313
+ }
314
+ ],
315
+ "stateMutability": "view",
316
+ "type": "function"
317
+ },
318
+ {
319
+ "inputs": [],
320
+ "name": "getDefaultRoyaltyReceiver",
321
+ "outputs": [
322
+ {
323
+ "internalType": "address",
324
+ "name": "",
325
+ "type": "address"
326
+ }
327
+ ],
328
+ "stateMutability": "view",
329
+ "type": "function"
330
+ },
331
+ {
332
+ "inputs": [],
333
+ "name": "getMintConfig",
334
+ "outputs": [
335
+ {
336
+ "components": [
337
+ {
338
+ "internalType": "uint256",
339
+ "name": "numberOfTokens",
340
+ "type": "uint256"
341
+ },
342
+ {
343
+ "internalType": "string",
344
+ "name": "baseURI",
345
+ "type": "string"
346
+ },
347
+ {
348
+ "internalType": "bool",
349
+ "name": "lockedMetadata",
350
+ "type": "bool"
351
+ }
352
+ ],
353
+ "internalType": "struct LazySovereignNFT.MintConfig",
354
+ "name": "",
355
+ "type": "tuple"
356
+ }
357
+ ],
358
+ "stateMutability": "view",
359
+ "type": "function"
360
+ },
361
+ {
362
+ "inputs": [
363
+ {
364
+ "internalType": "string",
365
+ "name": "_name",
366
+ "type": "string"
367
+ },
368
+ {
369
+ "internalType": "string",
370
+ "name": "_symbol",
371
+ "type": "string"
372
+ },
373
+ {
374
+ "internalType": "address",
375
+ "name": "_creator",
376
+ "type": "address"
377
+ },
378
+ {
379
+ "internalType": "uint256",
380
+ "name": "_maxTokens",
381
+ "type": "uint256"
382
+ }
383
+ ],
384
+ "name": "init",
385
+ "outputs": [],
386
+ "stateMutability": "nonpayable",
387
+ "type": "function"
388
+ },
389
+ {
390
+ "inputs": [
391
+ {
392
+ "internalType": "address",
393
+ "name": "owner",
394
+ "type": "address"
395
+ },
396
+ {
397
+ "internalType": "address",
398
+ "name": "operator",
399
+ "type": "address"
400
+ }
401
+ ],
402
+ "name": "isApprovedForAll",
403
+ "outputs": [
404
+ {
405
+ "internalType": "bool",
406
+ "name": "",
407
+ "type": "bool"
408
+ }
409
+ ],
410
+ "stateMutability": "view",
411
+ "type": "function"
412
+ },
413
+ {
414
+ "inputs": [
415
+ {
416
+ "internalType": "address",
417
+ "name": "_address",
418
+ "type": "address"
419
+ }
420
+ ],
421
+ "name": "isApprovedMinter",
422
+ "outputs": [
423
+ {
424
+ "internalType": "bool",
425
+ "name": "",
426
+ "type": "bool"
427
+ }
428
+ ],
429
+ "stateMutability": "view",
430
+ "type": "function"
431
+ },
432
+ {
433
+ "inputs": [],
434
+ "name": "lockBaseURI",
435
+ "outputs": [],
436
+ "stateMutability": "nonpayable",
437
+ "type": "function"
438
+ },
439
+ {
440
+ "inputs": [],
441
+ "name": "maxTokens",
442
+ "outputs": [
443
+ {
444
+ "internalType": "uint256",
445
+ "name": "",
446
+ "type": "uint256"
447
+ }
448
+ ],
449
+ "stateMutability": "view",
450
+ "type": "function"
451
+ },
452
+ {
453
+ "inputs": [
454
+ {
455
+ "internalType": "address",
456
+ "name": "_receiver",
457
+ "type": "address"
458
+ }
459
+ ],
460
+ "name": "mintTo",
461
+ "outputs": [
462
+ {
463
+ "internalType": "uint256",
464
+ "name": "",
465
+ "type": "uint256"
466
+ }
467
+ ],
468
+ "stateMutability": "nonpayable",
469
+ "type": "function"
470
+ },
471
+ {
472
+ "inputs": [],
473
+ "name": "name",
474
+ "outputs": [
475
+ {
476
+ "internalType": "string",
477
+ "name": "",
478
+ "type": "string"
479
+ }
480
+ ],
481
+ "stateMutability": "view",
482
+ "type": "function"
483
+ },
484
+ {
485
+ "inputs": [],
486
+ "name": "owner",
487
+ "outputs": [
488
+ {
489
+ "internalType": "address",
490
+ "name": "",
491
+ "type": "address"
492
+ }
493
+ ],
494
+ "stateMutability": "view",
495
+ "type": "function"
496
+ },
497
+ {
498
+ "inputs": [
499
+ {
500
+ "internalType": "uint256",
501
+ "name": "tokenId",
502
+ "type": "uint256"
503
+ }
504
+ ],
505
+ "name": "ownerOf",
506
+ "outputs": [
507
+ {
508
+ "internalType": "address",
509
+ "name": "",
510
+ "type": "address"
511
+ }
512
+ ],
513
+ "stateMutability": "view",
514
+ "type": "function"
515
+ },
516
+ {
517
+ "inputs": [
518
+ {
519
+ "internalType": "string",
520
+ "name": "_baseURI",
521
+ "type": "string"
522
+ },
523
+ {
524
+ "internalType": "uint256",
525
+ "name": "_numberOfTokens",
526
+ "type": "uint256"
527
+ }
528
+ ],
529
+ "name": "prepareMint",
530
+ "outputs": [],
531
+ "stateMutability": "nonpayable",
532
+ "type": "function"
533
+ },
534
+ {
535
+ "inputs": [
536
+ {
537
+ "internalType": "string",
538
+ "name": "_baseURI",
539
+ "type": "string"
540
+ },
541
+ {
542
+ "internalType": "uint256",
543
+ "name": "_numberOfTokens",
544
+ "type": "uint256"
545
+ },
546
+ {
547
+ "internalType": "address",
548
+ "name": "_minter",
549
+ "type": "address"
550
+ }
551
+ ],
552
+ "name": "prepareMintWithMinter",
553
+ "outputs": [],
554
+ "stateMutability": "nonpayable",
555
+ "type": "function"
556
+ },
557
+ {
558
+ "inputs": [],
559
+ "name": "renounceOwnership",
560
+ "outputs": [],
561
+ "stateMutability": "nonpayable",
562
+ "type": "function"
563
+ },
564
+ {
565
+ "inputs": [
566
+ {
567
+ "internalType": "uint256",
568
+ "name": "_tokenId",
569
+ "type": "uint256"
570
+ },
571
+ {
572
+ "internalType": "uint256",
573
+ "name": "_salePrice",
574
+ "type": "uint256"
575
+ }
576
+ ],
577
+ "name": "royaltyInfo",
578
+ "outputs": [
579
+ {
580
+ "internalType": "address",
581
+ "name": "receiver",
582
+ "type": "address"
583
+ },
584
+ {
585
+ "internalType": "uint256",
586
+ "name": "royaltyAmount",
587
+ "type": "uint256"
588
+ }
589
+ ],
590
+ "stateMutability": "view",
591
+ "type": "function"
592
+ },
593
+ {
594
+ "inputs": [
595
+ {
596
+ "internalType": "address",
597
+ "name": "from",
598
+ "type": "address"
599
+ },
600
+ {
601
+ "internalType": "address",
602
+ "name": "to",
603
+ "type": "address"
604
+ },
605
+ {
606
+ "internalType": "uint256",
607
+ "name": "tokenId",
608
+ "type": "uint256"
609
+ }
610
+ ],
611
+ "name": "safeTransferFrom",
612
+ "outputs": [],
613
+ "stateMutability": "nonpayable",
614
+ "type": "function"
615
+ },
616
+ {
617
+ "inputs": [
618
+ {
619
+ "internalType": "address",
620
+ "name": "from",
621
+ "type": "address"
622
+ },
623
+ {
624
+ "internalType": "address",
625
+ "name": "to",
626
+ "type": "address"
627
+ },
628
+ {
629
+ "internalType": "uint256",
630
+ "name": "tokenId",
631
+ "type": "uint256"
632
+ },
633
+ {
634
+ "internalType": "bytes",
635
+ "name": "_data",
636
+ "type": "bytes"
637
+ }
638
+ ],
639
+ "name": "safeTransferFrom",
640
+ "outputs": [],
641
+ "stateMutability": "nonpayable",
642
+ "type": "function"
643
+ },
644
+ {
645
+ "inputs": [
646
+ {
647
+ "internalType": "address",
648
+ "name": "operator",
649
+ "type": "address"
650
+ },
651
+ {
652
+ "internalType": "bool",
653
+ "name": "approved",
654
+ "type": "bool"
655
+ }
656
+ ],
657
+ "name": "setApprovalForAll",
658
+ "outputs": [],
659
+ "stateMutability": "nonpayable",
660
+ "type": "function"
661
+ },
662
+ {
663
+ "inputs": [
664
+ {
665
+ "internalType": "address",
666
+ "name": "_receiver",
667
+ "type": "address"
668
+ }
669
+ ],
670
+ "name": "setDefaultRoyaltyReceiver",
671
+ "outputs": [],
672
+ "stateMutability": "nonpayable",
673
+ "type": "function"
674
+ },
675
+ {
676
+ "inputs": [
677
+ {
678
+ "internalType": "address",
679
+ "name": "_minter",
680
+ "type": "address"
681
+ },
682
+ {
683
+ "internalType": "bool",
684
+ "name": "_isMinter",
685
+ "type": "bool"
686
+ }
687
+ ],
688
+ "name": "setMinterApproval",
689
+ "outputs": [],
690
+ "stateMutability": "nonpayable",
691
+ "type": "function"
692
+ },
693
+ {
694
+ "inputs": [
695
+ {
696
+ "internalType": "address",
697
+ "name": "_receiver",
698
+ "type": "address"
699
+ },
700
+ {
701
+ "internalType": "uint256",
702
+ "name": "_tokenId",
703
+ "type": "uint256"
704
+ }
705
+ ],
706
+ "name": "setRoyaltyReceiverForToken",
707
+ "outputs": [],
708
+ "stateMutability": "nonpayable",
709
+ "type": "function"
710
+ },
711
+ {
712
+ "inputs": [
713
+ {
714
+ "internalType": "bytes4",
715
+ "name": "interfaceId",
716
+ "type": "bytes4"
717
+ }
718
+ ],
719
+ "name": "supportsInterface",
720
+ "outputs": [
721
+ {
722
+ "internalType": "bool",
723
+ "name": "",
724
+ "type": "bool"
725
+ }
726
+ ],
727
+ "stateMutability": "view",
728
+ "type": "function"
729
+ },
730
+ {
731
+ "inputs": [],
732
+ "name": "symbol",
733
+ "outputs": [
734
+ {
735
+ "internalType": "string",
736
+ "name": "",
737
+ "type": "string"
738
+ }
739
+ ],
740
+ "stateMutability": "view",
741
+ "type": "function"
742
+ },
743
+ {
744
+ "inputs": [
745
+ {
746
+ "internalType": "uint256",
747
+ "name": "_tokenId",
748
+ "type": "uint256"
749
+ }
750
+ ],
751
+ "name": "tokenCreator",
752
+ "outputs": [
753
+ {
754
+ "internalType": "address payable",
755
+ "name": "",
756
+ "type": "address"
757
+ }
758
+ ],
759
+ "stateMutability": "view",
760
+ "type": "function"
761
+ },
762
+ {
763
+ "inputs": [
764
+ {
765
+ "internalType": "uint256",
766
+ "name": "_tokenId",
767
+ "type": "uint256"
768
+ }
769
+ ],
770
+ "name": "tokenURI",
771
+ "outputs": [
772
+ {
773
+ "internalType": "string",
774
+ "name": "",
775
+ "type": "string"
776
+ }
777
+ ],
778
+ "stateMutability": "view",
779
+ "type": "function"
780
+ },
781
+ {
782
+ "inputs": [],
783
+ "name": "totalSupply",
784
+ "outputs": [
785
+ {
786
+ "internalType": "uint256",
787
+ "name": "",
788
+ "type": "uint256"
789
+ }
790
+ ],
791
+ "stateMutability": "view",
792
+ "type": "function"
793
+ },
794
+ {
795
+ "inputs": [
796
+ {
797
+ "internalType": "address",
798
+ "name": "from",
799
+ "type": "address"
800
+ },
801
+ {
802
+ "internalType": "address",
803
+ "name": "to",
804
+ "type": "address"
805
+ },
806
+ {
807
+ "internalType": "uint256",
808
+ "name": "tokenId",
809
+ "type": "uint256"
810
+ }
811
+ ],
812
+ "name": "transferFrom",
813
+ "outputs": [],
814
+ "stateMutability": "nonpayable",
815
+ "type": "function"
816
+ },
817
+ {
818
+ "inputs": [
819
+ {
820
+ "internalType": "address",
821
+ "name": "newOwner",
822
+ "type": "address"
823
+ }
824
+ ],
825
+ "name": "transferOwnership",
826
+ "outputs": [],
827
+ "stateMutability": "nonpayable",
828
+ "type": "function"
829
+ },
830
+ {
831
+ "inputs": [
832
+ {
833
+ "internalType": "string",
834
+ "name": "_baseURI",
835
+ "type": "string"
836
+ }
837
+ ],
838
+ "name": "updateBaseURI",
839
+ "outputs": [],
840
+ "stateMutability": "nonpayable",
841
+ "type": "function"
842
+ },
843
+ {
844
+ "inputs": [
845
+ {
846
+ "internalType": "uint256",
847
+ "name": "_tokenId",
848
+ "type": "uint256"
849
+ },
850
+ {
851
+ "internalType": "string",
852
+ "name": "_metadataUri",
853
+ "type": "string"
854
+ }
855
+ ],
856
+ "name": "updateTokenURI",
857
+ "outputs": [],
858
+ "stateMutability": "nonpayable",
859
+ "type": "function"
860
+ }
861
+ ] as const satisfies Abi;
862
+
863
+ /**
864
+ * Type-safe ABI for LazySovereignNFT_json
865
+ */
866
+ export type LazySovereignNFT_jsonAbi = typeof LazySovereignNFT_jsonAbi;
867
+
868
+ /**
869
+ * Contract instance type for LazySovereignNFT_json
870
+ */
871
+ // Use any for contract type to avoid complex viem type issues
872
+ // The runtime behavior is type-safe through viem's ABI typing
873
+ export type LazySovereignNFT_jsonContract = any;
874
+
875
+ /**
876
+ * LazySovereignNFT_json Contract Class
877
+ *
878
+ * Provides a class-based API similar to TypeChain for interacting with the contract.
879
+ *
880
+ * @example
881
+ * ```typescript
882
+ * import { createPublicClient, createWalletClient, http } from 'viem';
883
+ * import { mainnet } from 'viem/chains';
884
+ * import { LazySovereignNFT_json } from 'LazySovereignNFT_json';
885
+ *
886
+ * const publicClient = createPublicClient({ chain: mainnet, transport: http() });
887
+ * const walletClient = createWalletClient({ chain: mainnet, transport: http() });
888
+ *
889
+ * const contract = new LazySovereignNFT_json('0x...', { publicClient, walletClient });
890
+ *
891
+ * // Read functions
892
+ * const result = await contract.balanceOf('0x...');
893
+ *
894
+ * // Write functions
895
+ * const hash = await contract.transfer('0x...', 1000n);
896
+ *
897
+ * // Simulate transactions (dry-run)
898
+ * const simulation = await contract.simulate.transfer('0x...', 1000n);
899
+ * console.log('Gas estimate:', simulation.request.gas);
900
+ *
901
+ * // Watch events
902
+ * const unwatch = contract.watch.Transfer((event) => {
903
+ * console.log('Transfer event:', event);
904
+ * });
905
+ * ```
906
+ */
907
+ export class LazySovereignNFT_json {
908
+ private contract: LazySovereignNFT_jsonContract;
909
+ private contractAddress: Address;
910
+ private publicClient: PublicClient;
911
+
912
+ constructor(
913
+ address: Address,
914
+ clients: {
915
+ publicClient: PublicClient;
916
+ walletClient?: WalletClient;
917
+ }
918
+ ) {
919
+ this.contractAddress = address;
920
+ this.publicClient = clients.publicClient;
921
+ this.contract = getContract({
922
+ address,
923
+ abi: LazySovereignNFT_jsonAbi,
924
+ client: {
925
+ public: clients.publicClient,
926
+ wallet: clients.walletClient,
927
+ },
928
+ });
929
+ }
930
+
931
+ /**
932
+ * Get the contract address
933
+ */
934
+ get address(): Address {
935
+ return this.contractAddress;
936
+ }
937
+
938
+ /**
939
+ * Get the underlying viem contract instance
940
+ */
941
+ getContract(): LazySovereignNFT_jsonContract {
942
+ return this.contract;
943
+ }
944
+
945
+ /**
946
+ * balanceOf
947
+ * view
948
+ */
949
+ async balanceOf(owner: `0x${string}`): Promise<bigint> {
950
+ return this.contract.read.balanceOf([owner] as const) as Promise<bigint>;
951
+ }
952
+
953
+ /**
954
+ * disabled
955
+ * view
956
+ */
957
+ async disabled(): Promise<boolean> {
958
+ return this.contract.read.disabled() as Promise<boolean>;
959
+ }
960
+
961
+ /**
962
+ * getApproved
963
+ * view
964
+ */
965
+ async getApproved(tokenId: bigint): Promise<`0x${string}`> {
966
+ return this.contract.read.getApproved([tokenId] as const) as Promise<`0x${string}`>;
967
+ }
968
+
969
+ /**
970
+ * getDefaultRoyaltyPercentage
971
+ * view
972
+ */
973
+ async getDefaultRoyaltyPercentage(): Promise<bigint> {
974
+ return this.contract.read.getDefaultRoyaltyPercentage() as Promise<bigint>;
975
+ }
976
+
977
+ /**
978
+ * getDefaultRoyaltyReceiver
979
+ * view
980
+ */
981
+ async getDefaultRoyaltyReceiver(): Promise<`0x${string}`> {
982
+ return this.contract.read.getDefaultRoyaltyReceiver() as Promise<`0x${string}`>;
983
+ }
984
+
985
+ /**
986
+ * getMintConfig
987
+ * view
988
+ */
989
+ async getMintConfig(): Promise<LazySovereignNFT_MintConfig> {
990
+ return this.contract.read.getMintConfig() as Promise<LazySovereignNFT_MintConfig>;
991
+ }
992
+
993
+ /**
994
+ * isApprovedForAll
995
+ * view
996
+ */
997
+ async isApprovedForAll(owner: `0x${string}`, operator: `0x${string}`): Promise<boolean> {
998
+ return this.contract.read.isApprovedForAll([owner, operator] as const) as Promise<boolean>;
999
+ }
1000
+
1001
+ /**
1002
+ * isApprovedMinter
1003
+ * view
1004
+ */
1005
+ async isApprovedMinter(_address: `0x${string}`): Promise<boolean> {
1006
+ return this.contract.read.isApprovedMinter([_address] as const) as Promise<boolean>;
1007
+ }
1008
+
1009
+ /**
1010
+ * maxTokens
1011
+ * view
1012
+ */
1013
+ async maxTokens(): Promise<bigint> {
1014
+ return this.contract.read.maxTokens() as Promise<bigint>;
1015
+ }
1016
+
1017
+ /**
1018
+ * name
1019
+ * view
1020
+ */
1021
+ async name(): Promise<string> {
1022
+ return this.contract.read.name() as Promise<string>;
1023
+ }
1024
+
1025
+ /**
1026
+ * owner
1027
+ * view
1028
+ */
1029
+ async owner(): Promise<`0x${string}`> {
1030
+ return this.contract.read.owner() as Promise<`0x${string}`>;
1031
+ }
1032
+
1033
+ /**
1034
+ * ownerOf
1035
+ * view
1036
+ */
1037
+ async ownerOf(tokenId: bigint): Promise<`0x${string}`> {
1038
+ return this.contract.read.ownerOf([tokenId] as const) as Promise<`0x${string}`>;
1039
+ }
1040
+
1041
+ /**
1042
+ * royaltyInfo
1043
+ * view
1044
+ */
1045
+ async royaltyInfo(_tokenId: bigint, _salePrice: bigint): Promise<[`0x${string}`, bigint]> {
1046
+ return this.contract.read.royaltyInfo([_tokenId, _salePrice] as const) as Promise<[`0x${string}`, bigint]>;
1047
+ }
1048
+
1049
+ /**
1050
+ * supportsInterface
1051
+ * view
1052
+ */
1053
+ async supportsInterface(interfaceId: `0x${string}`): Promise<boolean> {
1054
+ return this.contract.read.supportsInterface([interfaceId] as const) as Promise<boolean>;
1055
+ }
1056
+
1057
+ /**
1058
+ * symbol
1059
+ * view
1060
+ */
1061
+ async symbol(): Promise<string> {
1062
+ return this.contract.read.symbol() as Promise<string>;
1063
+ }
1064
+
1065
+ /**
1066
+ * tokenCreator
1067
+ * view
1068
+ */
1069
+ async tokenCreator(_tokenId: bigint): Promise<`0x${string}`> {
1070
+ return this.contract.read.tokenCreator([_tokenId] as const) as Promise<`0x${string}`>;
1071
+ }
1072
+
1073
+ /**
1074
+ * tokenURI
1075
+ * view
1076
+ */
1077
+ async tokenURI(_tokenId: bigint): Promise<string> {
1078
+ return this.contract.read.tokenURI([_tokenId] as const) as Promise<string>;
1079
+ }
1080
+
1081
+ /**
1082
+ * totalSupply
1083
+ * view
1084
+ */
1085
+ async totalSupply(): Promise<bigint> {
1086
+ return this.contract.read.totalSupply() as Promise<bigint>;
1087
+ }
1088
+
1089
+ /**
1090
+ * approve
1091
+ * nonpayable
1092
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1093
+ */
1094
+ async approve(to: `0x${string}`, tokenId: bigint, options?: {
1095
+ accessList?: import('viem').AccessList;
1096
+ authorizationList?: import('viem').AuthorizationList;
1097
+ chain?: import('viem').Chain | null;
1098
+ dataSuffix?: `0x${string}`;
1099
+ gas?: bigint;
1100
+ gasPrice?: bigint;
1101
+ maxFeePerGas?: bigint;
1102
+ maxPriorityFeePerGas?: bigint;
1103
+ nonce?: number;
1104
+ value?: bigint;
1105
+ }): Promise<`0x${string}`> {
1106
+ if (!this.contract.write) {
1107
+ throw new Error('Wallet client is required for write operations');
1108
+ }
1109
+ return this.contract.write.approve([to, tokenId] as const, options) as Promise<`0x${string}`>;
1110
+ }
1111
+
1112
+ /**
1113
+ * burn
1114
+ * nonpayable
1115
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1116
+ */
1117
+ async burn(tokenId: bigint, options?: {
1118
+ accessList?: import('viem').AccessList;
1119
+ authorizationList?: import('viem').AuthorizationList;
1120
+ chain?: import('viem').Chain | null;
1121
+ dataSuffix?: `0x${string}`;
1122
+ gas?: bigint;
1123
+ gasPrice?: bigint;
1124
+ maxFeePerGas?: bigint;
1125
+ maxPriorityFeePerGas?: bigint;
1126
+ nonce?: number;
1127
+ value?: bigint;
1128
+ }): Promise<`0x${string}`> {
1129
+ if (!this.contract.write) {
1130
+ throw new Error('Wallet client is required for write operations');
1131
+ }
1132
+ return this.contract.write.burn([tokenId] as const, options) as Promise<`0x${string}`>;
1133
+ }
1134
+
1135
+ /**
1136
+ * deleteToken
1137
+ * nonpayable
1138
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1139
+ */
1140
+ async deleteToken(_tokenId: bigint, options?: {
1141
+ accessList?: import('viem').AccessList;
1142
+ authorizationList?: import('viem').AuthorizationList;
1143
+ chain?: import('viem').Chain | null;
1144
+ dataSuffix?: `0x${string}`;
1145
+ gas?: bigint;
1146
+ gasPrice?: bigint;
1147
+ maxFeePerGas?: bigint;
1148
+ maxPriorityFeePerGas?: bigint;
1149
+ nonce?: number;
1150
+ value?: bigint;
1151
+ }): Promise<`0x${string}`> {
1152
+ if (!this.contract.write) {
1153
+ throw new Error('Wallet client is required for write operations');
1154
+ }
1155
+ return this.contract.write.deleteToken([_tokenId] as const, options) as Promise<`0x${string}`>;
1156
+ }
1157
+
1158
+ /**
1159
+ * disableContract
1160
+ * nonpayable
1161
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1162
+ */
1163
+ async disableContract(options?: {
1164
+ accessList?: import('viem').AccessList;
1165
+ authorizationList?: import('viem').AuthorizationList;
1166
+ chain?: import('viem').Chain | null;
1167
+ dataSuffix?: `0x${string}`;
1168
+ gas?: bigint;
1169
+ gasPrice?: bigint;
1170
+ maxFeePerGas?: bigint;
1171
+ maxPriorityFeePerGas?: bigint;
1172
+ nonce?: number;
1173
+ value?: bigint;
1174
+ }): Promise<`0x${string}`> {
1175
+ if (!this.contract.write) {
1176
+ throw new Error('Wallet client is required for write operations');
1177
+ }
1178
+ return this.contract.write.disableContract(options) as Promise<`0x${string}`>;
1179
+ }
1180
+
1181
+ /**
1182
+ * init
1183
+ * nonpayable
1184
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1185
+ */
1186
+ async init(_name: string, _symbol: string, _creator: `0x${string}`, _maxTokens: bigint, options?: {
1187
+ accessList?: import('viem').AccessList;
1188
+ authorizationList?: import('viem').AuthorizationList;
1189
+ chain?: import('viem').Chain | null;
1190
+ dataSuffix?: `0x${string}`;
1191
+ gas?: bigint;
1192
+ gasPrice?: bigint;
1193
+ maxFeePerGas?: bigint;
1194
+ maxPriorityFeePerGas?: bigint;
1195
+ nonce?: number;
1196
+ value?: bigint;
1197
+ }): Promise<`0x${string}`> {
1198
+ if (!this.contract.write) {
1199
+ throw new Error('Wallet client is required for write operations');
1200
+ }
1201
+ return this.contract.write.init([_name, _symbol, _creator, _maxTokens] as const, options) as Promise<`0x${string}`>;
1202
+ }
1203
+
1204
+ /**
1205
+ * lockBaseURI
1206
+ * nonpayable
1207
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1208
+ */
1209
+ async lockBaseURI(options?: {
1210
+ accessList?: import('viem').AccessList;
1211
+ authorizationList?: import('viem').AuthorizationList;
1212
+ chain?: import('viem').Chain | null;
1213
+ dataSuffix?: `0x${string}`;
1214
+ gas?: bigint;
1215
+ gasPrice?: bigint;
1216
+ maxFeePerGas?: bigint;
1217
+ maxPriorityFeePerGas?: bigint;
1218
+ nonce?: number;
1219
+ value?: bigint;
1220
+ }): Promise<`0x${string}`> {
1221
+ if (!this.contract.write) {
1222
+ throw new Error('Wallet client is required for write operations');
1223
+ }
1224
+ return this.contract.write.lockBaseURI(options) as Promise<`0x${string}`>;
1225
+ }
1226
+
1227
+ /**
1228
+ * mintTo
1229
+ * nonpayable
1230
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1231
+ */
1232
+ async mintTo(_receiver: `0x${string}`, options?: {
1233
+ accessList?: import('viem').AccessList;
1234
+ authorizationList?: import('viem').AuthorizationList;
1235
+ chain?: import('viem').Chain | null;
1236
+ dataSuffix?: `0x${string}`;
1237
+ gas?: bigint;
1238
+ gasPrice?: bigint;
1239
+ maxFeePerGas?: bigint;
1240
+ maxPriorityFeePerGas?: bigint;
1241
+ nonce?: number;
1242
+ value?: bigint;
1243
+ }): Promise<`0x${string}`> {
1244
+ if (!this.contract.write) {
1245
+ throw new Error('Wallet client is required for write operations');
1246
+ }
1247
+ return this.contract.write.mintTo([_receiver] as const, options) as Promise<`0x${string}`>;
1248
+ }
1249
+
1250
+ /**
1251
+ * prepareMint
1252
+ * nonpayable
1253
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1254
+ */
1255
+ async prepareMint(_baseURI: string, _numberOfTokens: bigint, options?: {
1256
+ accessList?: import('viem').AccessList;
1257
+ authorizationList?: import('viem').AuthorizationList;
1258
+ chain?: import('viem').Chain | null;
1259
+ dataSuffix?: `0x${string}`;
1260
+ gas?: bigint;
1261
+ gasPrice?: bigint;
1262
+ maxFeePerGas?: bigint;
1263
+ maxPriorityFeePerGas?: bigint;
1264
+ nonce?: number;
1265
+ value?: bigint;
1266
+ }): Promise<`0x${string}`> {
1267
+ if (!this.contract.write) {
1268
+ throw new Error('Wallet client is required for write operations');
1269
+ }
1270
+ return this.contract.write.prepareMint([_baseURI, _numberOfTokens] as const, options) as Promise<`0x${string}`>;
1271
+ }
1272
+
1273
+ /**
1274
+ * prepareMintWithMinter
1275
+ * nonpayable
1276
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1277
+ */
1278
+ async prepareMintWithMinter(_baseURI: string, _numberOfTokens: bigint, _minter: `0x${string}`, options?: {
1279
+ accessList?: import('viem').AccessList;
1280
+ authorizationList?: import('viem').AuthorizationList;
1281
+ chain?: import('viem').Chain | null;
1282
+ dataSuffix?: `0x${string}`;
1283
+ gas?: bigint;
1284
+ gasPrice?: bigint;
1285
+ maxFeePerGas?: bigint;
1286
+ maxPriorityFeePerGas?: bigint;
1287
+ nonce?: number;
1288
+ value?: bigint;
1289
+ }): Promise<`0x${string}`> {
1290
+ if (!this.contract.write) {
1291
+ throw new Error('Wallet client is required for write operations');
1292
+ }
1293
+ return this.contract.write.prepareMintWithMinter([_baseURI, _numberOfTokens, _minter] as const, options) as Promise<`0x${string}`>;
1294
+ }
1295
+
1296
+ /**
1297
+ * renounceOwnership
1298
+ * nonpayable
1299
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1300
+ */
1301
+ async renounceOwnership(options?: {
1302
+ accessList?: import('viem').AccessList;
1303
+ authorizationList?: import('viem').AuthorizationList;
1304
+ chain?: import('viem').Chain | null;
1305
+ dataSuffix?: `0x${string}`;
1306
+ gas?: bigint;
1307
+ gasPrice?: bigint;
1308
+ maxFeePerGas?: bigint;
1309
+ maxPriorityFeePerGas?: bigint;
1310
+ nonce?: number;
1311
+ value?: bigint;
1312
+ }): Promise<`0x${string}`> {
1313
+ if (!this.contract.write) {
1314
+ throw new Error('Wallet client is required for write operations');
1315
+ }
1316
+ return this.contract.write.renounceOwnership(options) as Promise<`0x${string}`>;
1317
+ }
1318
+
1319
+ async safeTransferFrom(from: `0x${string}`, to: `0x${string}`, tokenId: bigint, options?: {
1320
+ accessList?: import('viem').AccessList;
1321
+ authorizationList?: import('viem').AuthorizationList;
1322
+ chain?: import('viem').Chain | null;
1323
+ dataSuffix?: `0x${string}`;
1324
+ gas?: bigint;
1325
+ gasPrice?: bigint;
1326
+ maxFeePerGas?: bigint;
1327
+ maxPriorityFeePerGas?: bigint;
1328
+ nonce?: number;
1329
+ value?: bigint;
1330
+ }): Promise<`0x${string}`>;
1331
+ async safeTransferFrom(from: `0x${string}`, to: `0x${string}`, tokenId: bigint, _data: `0x${string}`, options?: {
1332
+ accessList?: import('viem').AccessList;
1333
+ authorizationList?: import('viem').AuthorizationList;
1334
+ chain?: import('viem').Chain | null;
1335
+ dataSuffix?: `0x${string}`;
1336
+ gas?: bigint;
1337
+ gasPrice?: bigint;
1338
+ maxFeePerGas?: bigint;
1339
+ maxPriorityFeePerGas?: bigint;
1340
+ nonce?: number;
1341
+ value?: bigint;
1342
+ }): Promise<`0x${string}`>;
1343
+ async safeTransferFrom(...args: any[]): Promise<`0x${string}`> {
1344
+ if (!this.contract.write) {
1345
+ throw new Error('Wallet client is required for write operations');
1346
+ }
1347
+ return this.contract.write.safeTransferFrom(args as any) as Promise<`0x${string}`>;
1348
+ }
1349
+
1350
+ /**
1351
+ * setApprovalForAll
1352
+ * nonpayable
1353
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1354
+ */
1355
+ async setApprovalForAll(operator: `0x${string}`, approved: boolean, options?: {
1356
+ accessList?: import('viem').AccessList;
1357
+ authorizationList?: import('viem').AuthorizationList;
1358
+ chain?: import('viem').Chain | null;
1359
+ dataSuffix?: `0x${string}`;
1360
+ gas?: bigint;
1361
+ gasPrice?: bigint;
1362
+ maxFeePerGas?: bigint;
1363
+ maxPriorityFeePerGas?: bigint;
1364
+ nonce?: number;
1365
+ value?: bigint;
1366
+ }): Promise<`0x${string}`> {
1367
+ if (!this.contract.write) {
1368
+ throw new Error('Wallet client is required for write operations');
1369
+ }
1370
+ return this.contract.write.setApprovalForAll([operator, approved] as const, options) as Promise<`0x${string}`>;
1371
+ }
1372
+
1373
+ /**
1374
+ * setDefaultRoyaltyReceiver
1375
+ * nonpayable
1376
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1377
+ */
1378
+ async setDefaultRoyaltyReceiver(_receiver: `0x${string}`, options?: {
1379
+ accessList?: import('viem').AccessList;
1380
+ authorizationList?: import('viem').AuthorizationList;
1381
+ chain?: import('viem').Chain | null;
1382
+ dataSuffix?: `0x${string}`;
1383
+ gas?: bigint;
1384
+ gasPrice?: bigint;
1385
+ maxFeePerGas?: bigint;
1386
+ maxPriorityFeePerGas?: bigint;
1387
+ nonce?: number;
1388
+ value?: bigint;
1389
+ }): Promise<`0x${string}`> {
1390
+ if (!this.contract.write) {
1391
+ throw new Error('Wallet client is required for write operations');
1392
+ }
1393
+ return this.contract.write.setDefaultRoyaltyReceiver([_receiver] as const, options) as Promise<`0x${string}`>;
1394
+ }
1395
+
1396
+ /**
1397
+ * setMinterApproval
1398
+ * nonpayable
1399
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1400
+ */
1401
+ async setMinterApproval(_minter: `0x${string}`, _isMinter: boolean, options?: {
1402
+ accessList?: import('viem').AccessList;
1403
+ authorizationList?: import('viem').AuthorizationList;
1404
+ chain?: import('viem').Chain | null;
1405
+ dataSuffix?: `0x${string}`;
1406
+ gas?: bigint;
1407
+ gasPrice?: bigint;
1408
+ maxFeePerGas?: bigint;
1409
+ maxPriorityFeePerGas?: bigint;
1410
+ nonce?: number;
1411
+ value?: bigint;
1412
+ }): Promise<`0x${string}`> {
1413
+ if (!this.contract.write) {
1414
+ throw new Error('Wallet client is required for write operations');
1415
+ }
1416
+ return this.contract.write.setMinterApproval([_minter, _isMinter] as const, options) as Promise<`0x${string}`>;
1417
+ }
1418
+
1419
+ /**
1420
+ * setRoyaltyReceiverForToken
1421
+ * nonpayable
1422
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1423
+ */
1424
+ async setRoyaltyReceiverForToken(_receiver: `0x${string}`, _tokenId: bigint, options?: {
1425
+ accessList?: import('viem').AccessList;
1426
+ authorizationList?: import('viem').AuthorizationList;
1427
+ chain?: import('viem').Chain | null;
1428
+ dataSuffix?: `0x${string}`;
1429
+ gas?: bigint;
1430
+ gasPrice?: bigint;
1431
+ maxFeePerGas?: bigint;
1432
+ maxPriorityFeePerGas?: bigint;
1433
+ nonce?: number;
1434
+ value?: bigint;
1435
+ }): Promise<`0x${string}`> {
1436
+ if (!this.contract.write) {
1437
+ throw new Error('Wallet client is required for write operations');
1438
+ }
1439
+ return this.contract.write.setRoyaltyReceiverForToken([_receiver, _tokenId] as const, options) as Promise<`0x${string}`>;
1440
+ }
1441
+
1442
+ /**
1443
+ * transferFrom
1444
+ * nonpayable
1445
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1446
+ */
1447
+ async transferFrom(from: `0x${string}`, to: `0x${string}`, tokenId: bigint, options?: {
1448
+ accessList?: import('viem').AccessList;
1449
+ authorizationList?: import('viem').AuthorizationList;
1450
+ chain?: import('viem').Chain | null;
1451
+ dataSuffix?: `0x${string}`;
1452
+ gas?: bigint;
1453
+ gasPrice?: bigint;
1454
+ maxFeePerGas?: bigint;
1455
+ maxPriorityFeePerGas?: bigint;
1456
+ nonce?: number;
1457
+ value?: bigint;
1458
+ }): Promise<`0x${string}`> {
1459
+ if (!this.contract.write) {
1460
+ throw new Error('Wallet client is required for write operations');
1461
+ }
1462
+ return this.contract.write.transferFrom([from, to, tokenId] as const, options) as Promise<`0x${string}`>;
1463
+ }
1464
+
1465
+ /**
1466
+ * transferOwnership
1467
+ * nonpayable
1468
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1469
+ */
1470
+ async transferOwnership(newOwner: `0x${string}`, options?: {
1471
+ accessList?: import('viem').AccessList;
1472
+ authorizationList?: import('viem').AuthorizationList;
1473
+ chain?: import('viem').Chain | null;
1474
+ dataSuffix?: `0x${string}`;
1475
+ gas?: bigint;
1476
+ gasPrice?: bigint;
1477
+ maxFeePerGas?: bigint;
1478
+ maxPriorityFeePerGas?: bigint;
1479
+ nonce?: number;
1480
+ value?: bigint;
1481
+ }): Promise<`0x${string}`> {
1482
+ if (!this.contract.write) {
1483
+ throw new Error('Wallet client is required for write operations');
1484
+ }
1485
+ return this.contract.write.transferOwnership([newOwner] as const, options) as Promise<`0x${string}`>;
1486
+ }
1487
+
1488
+ /**
1489
+ * updateBaseURI
1490
+ * nonpayable
1491
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1492
+ */
1493
+ async updateBaseURI(_baseURI: string, options?: {
1494
+ accessList?: import('viem').AccessList;
1495
+ authorizationList?: import('viem').AuthorizationList;
1496
+ chain?: import('viem').Chain | null;
1497
+ dataSuffix?: `0x${string}`;
1498
+ gas?: bigint;
1499
+ gasPrice?: bigint;
1500
+ maxFeePerGas?: bigint;
1501
+ maxPriorityFeePerGas?: bigint;
1502
+ nonce?: number;
1503
+ value?: bigint;
1504
+ }): Promise<`0x${string}`> {
1505
+ if (!this.contract.write) {
1506
+ throw new Error('Wallet client is required for write operations');
1507
+ }
1508
+ return this.contract.write.updateBaseURI([_baseURI] as const, options) as Promise<`0x${string}`>;
1509
+ }
1510
+
1511
+ /**
1512
+ * updateTokenURI
1513
+ * nonpayable
1514
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1515
+ */
1516
+ async updateTokenURI(_tokenId: bigint, _metadataUri: string, 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<`0x${string}`> {
1528
+ if (!this.contract.write) {
1529
+ throw new Error('Wallet client is required for write operations');
1530
+ }
1531
+ return this.contract.write.updateTokenURI([_tokenId, _metadataUri] as const, options) as Promise<`0x${string}`>;
1532
+ }
1533
+
1534
+
1535
+
1536
+ /**
1537
+ * Simulate contract write operations (dry-run without sending transaction)
1538
+ *
1539
+ * @example
1540
+ * const result = await contract.simulate.transfer('0x...', 1000n);
1541
+ * console.log('Gas estimate:', result.request.gas);
1542
+ * console.log('Would succeed:', result.result);
1543
+ */
1544
+ get simulate() {
1545
+ const contract = this.contract;
1546
+ if (!contract.simulate) {
1547
+ throw new Error('Public client is required for simulation');
1548
+ }
1549
+ return {
1550
+ /**
1551
+ * Simulate approve
1552
+ * Returns gas estimate and result without sending transaction
1553
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1554
+ */
1555
+ async approve(to: `0x${string}`, tokenId: bigint, options?: {
1556
+ accessList?: import('viem').AccessList;
1557
+ authorizationList?: import('viem').AuthorizationList;
1558
+ chain?: import('viem').Chain | null;
1559
+ dataSuffix?: `0x${string}`;
1560
+ gas?: bigint;
1561
+ gasPrice?: bigint;
1562
+ maxFeePerGas?: bigint;
1563
+ maxPriorityFeePerGas?: bigint;
1564
+ nonce?: number;
1565
+ value?: bigint;
1566
+ }): Promise<void> {
1567
+ return contract.simulate.approve([to, tokenId] as const, options) as Promise<void>;
1568
+ },
1569
+ /**
1570
+ * Simulate burn
1571
+ * Returns gas estimate and result without sending transaction
1572
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1573
+ */
1574
+ async burn(tokenId: bigint, options?: {
1575
+ accessList?: import('viem').AccessList;
1576
+ authorizationList?: import('viem').AuthorizationList;
1577
+ chain?: import('viem').Chain | null;
1578
+ dataSuffix?: `0x${string}`;
1579
+ gas?: bigint;
1580
+ gasPrice?: bigint;
1581
+ maxFeePerGas?: bigint;
1582
+ maxPriorityFeePerGas?: bigint;
1583
+ nonce?: number;
1584
+ value?: bigint;
1585
+ }): Promise<void> {
1586
+ return contract.simulate.burn([tokenId] as const, options) as Promise<void>;
1587
+ },
1588
+ /**
1589
+ * Simulate deleteToken
1590
+ * Returns gas estimate and result without sending transaction
1591
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1592
+ */
1593
+ async deleteToken(_tokenId: bigint, options?: {
1594
+ accessList?: import('viem').AccessList;
1595
+ authorizationList?: import('viem').AuthorizationList;
1596
+ chain?: import('viem').Chain | null;
1597
+ dataSuffix?: `0x${string}`;
1598
+ gas?: bigint;
1599
+ gasPrice?: bigint;
1600
+ maxFeePerGas?: bigint;
1601
+ maxPriorityFeePerGas?: bigint;
1602
+ nonce?: number;
1603
+ value?: bigint;
1604
+ }): Promise<void> {
1605
+ return contract.simulate.deleteToken([_tokenId] as const, options) as Promise<void>;
1606
+ },
1607
+ /**
1608
+ * Simulate disableContract
1609
+ * Returns gas estimate and result without sending transaction
1610
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1611
+ */
1612
+ async disableContract(options?: {
1613
+ accessList?: import('viem').AccessList;
1614
+ authorizationList?: import('viem').AuthorizationList;
1615
+ chain?: import('viem').Chain | null;
1616
+ dataSuffix?: `0x${string}`;
1617
+ gas?: bigint;
1618
+ gasPrice?: bigint;
1619
+ maxFeePerGas?: bigint;
1620
+ maxPriorityFeePerGas?: bigint;
1621
+ nonce?: number;
1622
+ value?: bigint;
1623
+ }): Promise<void> {
1624
+ return contract.simulate.disableContract(options) as Promise<void>;
1625
+ },
1626
+ /**
1627
+ * Simulate init
1628
+ * Returns gas estimate and result without sending transaction
1629
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1630
+ */
1631
+ async init(_name: string, _symbol: string, _creator: `0x${string}`, _maxTokens: bigint, options?: {
1632
+ accessList?: import('viem').AccessList;
1633
+ authorizationList?: import('viem').AuthorizationList;
1634
+ chain?: import('viem').Chain | null;
1635
+ dataSuffix?: `0x${string}`;
1636
+ gas?: bigint;
1637
+ gasPrice?: bigint;
1638
+ maxFeePerGas?: bigint;
1639
+ maxPriorityFeePerGas?: bigint;
1640
+ nonce?: number;
1641
+ value?: bigint;
1642
+ }): Promise<void> {
1643
+ return contract.simulate.init([_name, _symbol, _creator, _maxTokens] as const, options) as Promise<void>;
1644
+ },
1645
+ /**
1646
+ * Simulate lockBaseURI
1647
+ * Returns gas estimate and result without sending transaction
1648
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1649
+ */
1650
+ async lockBaseURI(options?: {
1651
+ accessList?: import('viem').AccessList;
1652
+ authorizationList?: import('viem').AuthorizationList;
1653
+ chain?: import('viem').Chain | null;
1654
+ dataSuffix?: `0x${string}`;
1655
+ gas?: bigint;
1656
+ gasPrice?: bigint;
1657
+ maxFeePerGas?: bigint;
1658
+ maxPriorityFeePerGas?: bigint;
1659
+ nonce?: number;
1660
+ value?: bigint;
1661
+ }): Promise<void> {
1662
+ return contract.simulate.lockBaseURI(options) as Promise<void>;
1663
+ },
1664
+ /**
1665
+ * Simulate mintTo
1666
+ * Returns gas estimate and result without sending transaction
1667
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1668
+ */
1669
+ async mintTo(_receiver: `0x${string}`, 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<bigint> {
1681
+ return contract.simulate.mintTo([_receiver] as const, options) as Promise<bigint>;
1682
+ },
1683
+ /**
1684
+ * Simulate prepareMint
1685
+ * Returns gas estimate and result without sending transaction
1686
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1687
+ */
1688
+ async prepareMint(_baseURI: string, _numberOfTokens: bigint, 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<void> {
1700
+ return contract.simulate.prepareMint([_baseURI, _numberOfTokens] as const, options) as Promise<void>;
1701
+ },
1702
+ /**
1703
+ * Simulate prepareMintWithMinter
1704
+ * Returns gas estimate and result without sending transaction
1705
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1706
+ */
1707
+ async prepareMintWithMinter(_baseURI: string, _numberOfTokens: bigint, _minter: `0x${string}`, options?: {
1708
+ accessList?: import('viem').AccessList;
1709
+ authorizationList?: import('viem').AuthorizationList;
1710
+ chain?: import('viem').Chain | null;
1711
+ dataSuffix?: `0x${string}`;
1712
+ gas?: bigint;
1713
+ gasPrice?: bigint;
1714
+ maxFeePerGas?: bigint;
1715
+ maxPriorityFeePerGas?: bigint;
1716
+ nonce?: number;
1717
+ value?: bigint;
1718
+ }): Promise<void> {
1719
+ return contract.simulate.prepareMintWithMinter([_baseURI, _numberOfTokens, _minter] as const, options) as Promise<void>;
1720
+ },
1721
+ /**
1722
+ * Simulate renounceOwnership
1723
+ * Returns gas estimate and result without sending transaction
1724
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1725
+ */
1726
+ async renounceOwnership(options?: {
1727
+ accessList?: import('viem').AccessList;
1728
+ authorizationList?: import('viem').AuthorizationList;
1729
+ chain?: import('viem').Chain | null;
1730
+ dataSuffix?: `0x${string}`;
1731
+ gas?: bigint;
1732
+ gasPrice?: bigint;
1733
+ maxFeePerGas?: bigint;
1734
+ maxPriorityFeePerGas?: bigint;
1735
+ nonce?: number;
1736
+ value?: bigint;
1737
+ }): Promise<void> {
1738
+ return contract.simulate.renounceOwnership(options) as Promise<void>;
1739
+ },
1740
+ /**
1741
+ * Simulate safeTransferFrom
1742
+ * Returns gas estimate and result without sending transaction
1743
+ * Supports multiple overloads: (address, address, uint256), (address, address, uint256, bytes)
1744
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1745
+ */
1746
+ async safeTransferFrom(...args: any[]): Promise<any> {
1747
+ return contract.simulate.safeTransferFrom(args as any) as Promise<any>;
1748
+ },
1749
+ /**
1750
+ * Simulate setApprovalForAll
1751
+ * Returns gas estimate and result without sending transaction
1752
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1753
+ */
1754
+ async setApprovalForAll(operator: `0x${string}`, approved: boolean, options?: {
1755
+ accessList?: import('viem').AccessList;
1756
+ authorizationList?: import('viem').AuthorizationList;
1757
+ chain?: import('viem').Chain | null;
1758
+ dataSuffix?: `0x${string}`;
1759
+ gas?: bigint;
1760
+ gasPrice?: bigint;
1761
+ maxFeePerGas?: bigint;
1762
+ maxPriorityFeePerGas?: bigint;
1763
+ nonce?: number;
1764
+ value?: bigint;
1765
+ }): Promise<void> {
1766
+ return contract.simulate.setApprovalForAll([operator, approved] as const, options) as Promise<void>;
1767
+ },
1768
+ /**
1769
+ * Simulate setDefaultRoyaltyReceiver
1770
+ * Returns gas estimate and result without sending transaction
1771
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1772
+ */
1773
+ async setDefaultRoyaltyReceiver(_receiver: `0x${string}`, options?: {
1774
+ accessList?: import('viem').AccessList;
1775
+ authorizationList?: import('viem').AuthorizationList;
1776
+ chain?: import('viem').Chain | null;
1777
+ dataSuffix?: `0x${string}`;
1778
+ gas?: bigint;
1779
+ gasPrice?: bigint;
1780
+ maxFeePerGas?: bigint;
1781
+ maxPriorityFeePerGas?: bigint;
1782
+ nonce?: number;
1783
+ value?: bigint;
1784
+ }): Promise<void> {
1785
+ return contract.simulate.setDefaultRoyaltyReceiver([_receiver] as const, options) as Promise<void>;
1786
+ },
1787
+ /**
1788
+ * Simulate setMinterApproval
1789
+ * Returns gas estimate and result without sending transaction
1790
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1791
+ */
1792
+ async setMinterApproval(_minter: `0x${string}`, _isMinter: boolean, options?: {
1793
+ accessList?: import('viem').AccessList;
1794
+ authorizationList?: import('viem').AuthorizationList;
1795
+ chain?: import('viem').Chain | null;
1796
+ dataSuffix?: `0x${string}`;
1797
+ gas?: bigint;
1798
+ gasPrice?: bigint;
1799
+ maxFeePerGas?: bigint;
1800
+ maxPriorityFeePerGas?: bigint;
1801
+ nonce?: number;
1802
+ value?: bigint;
1803
+ }): Promise<void> {
1804
+ return contract.simulate.setMinterApproval([_minter, _isMinter] as const, options) as Promise<void>;
1805
+ },
1806
+ /**
1807
+ * Simulate setRoyaltyReceiverForToken
1808
+ * Returns gas estimate and result without sending transaction
1809
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1810
+ */
1811
+ async setRoyaltyReceiverForToken(_receiver: `0x${string}`, _tokenId: bigint, options?: {
1812
+ accessList?: import('viem').AccessList;
1813
+ authorizationList?: import('viem').AuthorizationList;
1814
+ chain?: import('viem').Chain | null;
1815
+ dataSuffix?: `0x${string}`;
1816
+ gas?: bigint;
1817
+ gasPrice?: bigint;
1818
+ maxFeePerGas?: bigint;
1819
+ maxPriorityFeePerGas?: bigint;
1820
+ nonce?: number;
1821
+ value?: bigint;
1822
+ }): Promise<void> {
1823
+ return contract.simulate.setRoyaltyReceiverForToken([_receiver, _tokenId] as const, options) as Promise<void>;
1824
+ },
1825
+ /**
1826
+ * Simulate transferFrom
1827
+ * Returns gas estimate and result without sending transaction
1828
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1829
+ */
1830
+ async transferFrom(from: `0x${string}`, to: `0x${string}`, tokenId: bigint, options?: {
1831
+ accessList?: import('viem').AccessList;
1832
+ authorizationList?: import('viem').AuthorizationList;
1833
+ chain?: import('viem').Chain | null;
1834
+ dataSuffix?: `0x${string}`;
1835
+ gas?: bigint;
1836
+ gasPrice?: bigint;
1837
+ maxFeePerGas?: bigint;
1838
+ maxPriorityFeePerGas?: bigint;
1839
+ nonce?: number;
1840
+ value?: bigint;
1841
+ }): Promise<void> {
1842
+ return contract.simulate.transferFrom([from, to, tokenId] as const, options) as Promise<void>;
1843
+ },
1844
+ /**
1845
+ * Simulate transferOwnership
1846
+ * Returns gas estimate and result without sending transaction
1847
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1848
+ */
1849
+ async transferOwnership(newOwner: `0x${string}`, 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<void> {
1861
+ return contract.simulate.transferOwnership([newOwner] as const, options) as Promise<void>;
1862
+ },
1863
+ /**
1864
+ * Simulate updateBaseURI
1865
+ * Returns gas estimate and result without sending transaction
1866
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1867
+ */
1868
+ async updateBaseURI(_baseURI: string, options?: {
1869
+ accessList?: import('viem').AccessList;
1870
+ authorizationList?: import('viem').AuthorizationList;
1871
+ chain?: import('viem').Chain | null;
1872
+ dataSuffix?: `0x${string}`;
1873
+ gas?: bigint;
1874
+ gasPrice?: bigint;
1875
+ maxFeePerGas?: bigint;
1876
+ maxPriorityFeePerGas?: bigint;
1877
+ nonce?: number;
1878
+ value?: bigint;
1879
+ }): Promise<void> {
1880
+ return contract.simulate.updateBaseURI([_baseURI] as const, options) as Promise<void>;
1881
+ },
1882
+ /**
1883
+ * Simulate updateTokenURI
1884
+ * Returns gas estimate and result without sending transaction
1885
+ * @param options Optional transaction parameters (value, gas, nonce, etc.)
1886
+ */
1887
+ async updateTokenURI(_tokenId: bigint, _metadataUri: string, options?: {
1888
+ accessList?: import('viem').AccessList;
1889
+ authorizationList?: import('viem').AuthorizationList;
1890
+ chain?: import('viem').Chain | null;
1891
+ dataSuffix?: `0x${string}`;
1892
+ gas?: bigint;
1893
+ gasPrice?: bigint;
1894
+ maxFeePerGas?: bigint;
1895
+ maxPriorityFeePerGas?: bigint;
1896
+ nonce?: number;
1897
+ value?: bigint;
1898
+ }): Promise<void> {
1899
+ return contract.simulate.updateTokenURI([_tokenId, _metadataUri] as const, options) as Promise<void>;
1900
+ }
1901
+ };
1902
+ }
1903
+
1904
+ /**
1905
+ * Watch contract events
1906
+ *
1907
+ * @example
1908
+ * // Watch all Transfer events
1909
+ * const unwatch = contract.watch.Transfer((event) => {
1910
+ * console.log('Transfer:', event);
1911
+ * });
1912
+ *
1913
+ * // Stop watching
1914
+ * unwatch();
1915
+ */
1916
+ get watch() {
1917
+ return {
1918
+ /**
1919
+ * Watch Approval events
1920
+ * @param callback Function to call when event is emitted
1921
+ * @param filter Optional filter for indexed parameters
1922
+ * @returns Unwatch function to stop listening
1923
+ */
1924
+ Approval: (callback: (event: { owner: `0x${string}`; approved: `0x${string}`; tokenId: bigint }) => void, filter?: { owner: `0x${string}`; approved: `0x${string}`; tokenId: bigint }) => {
1925
+ return this.publicClient.watchContractEvent({
1926
+ address: this.contractAddress,
1927
+ abi: LazySovereignNFT_jsonAbi,
1928
+ eventName: 'Approval',
1929
+ args: filter,
1930
+ onLogs: (logs: any[]) => {
1931
+ logs.forEach((log: any) => {
1932
+ callback(log.args as any);
1933
+ });
1934
+ },
1935
+ }) as () => void;
1936
+ },
1937
+ /**
1938
+ * Watch ApprovalForAll events
1939
+ * @param callback Function to call when event is emitted
1940
+ * @param filter Optional filter for indexed parameters
1941
+ * @returns Unwatch function to stop listening
1942
+ */
1943
+ ApprovalForAll: (callback: (event: { owner: `0x${string}`; operator: `0x${string}`; approved: boolean }) => void, filter?: { owner: `0x${string}`; operator: `0x${string}` }) => {
1944
+ return this.publicClient.watchContractEvent({
1945
+ address: this.contractAddress,
1946
+ abi: LazySovereignNFT_jsonAbi,
1947
+ eventName: 'ApprovalForAll',
1948
+ args: filter,
1949
+ onLogs: (logs: any[]) => {
1950
+ logs.forEach((log: any) => {
1951
+ callback(log.args as any);
1952
+ });
1953
+ },
1954
+ }) as () => void;
1955
+ },
1956
+ /**
1957
+ * Watch ContractDisabled events
1958
+ * @param callback Function to call when event is emitted
1959
+ * @param filter Optional filter for indexed parameters
1960
+ * @returns Unwatch function to stop listening
1961
+ */
1962
+ ContractDisabled: (callback: (event: { user: `0x${string}` }) => void, filter?: { user: `0x${string}` }) => {
1963
+ return this.publicClient.watchContractEvent({
1964
+ address: this.contractAddress,
1965
+ abi: LazySovereignNFT_jsonAbi,
1966
+ eventName: 'ContractDisabled',
1967
+ args: filter,
1968
+ onLogs: (logs: any[]) => {
1969
+ logs.forEach((log: any) => {
1970
+ callback(log.args as any);
1971
+ });
1972
+ },
1973
+ }) as () => void;
1974
+ },
1975
+ /**
1976
+ * Watch Initialized events
1977
+ * @param callback Function to call when event is emitted
1978
+ * @param filter Optional filter for indexed parameters
1979
+ * @returns Unwatch function to stop listening
1980
+ */
1981
+ Initialized: (callback: (event: { version: bigint }) => void) => {
1982
+ return this.publicClient.watchContractEvent({
1983
+ address: this.contractAddress,
1984
+ abi: LazySovereignNFT_jsonAbi,
1985
+ eventName: 'Initialized',
1986
+
1987
+ onLogs: (logs: any[]) => {
1988
+ logs.forEach((log: any) => {
1989
+ callback(log.args as any);
1990
+ });
1991
+ },
1992
+ }) as () => void;
1993
+ },
1994
+ /**
1995
+ * Watch MetadataLocked events
1996
+ * @param callback Function to call when event is emitted
1997
+ * @param filter Optional filter for indexed parameters
1998
+ * @returns Unwatch function to stop listening
1999
+ */
2000
+ MetadataLocked: (callback: (event: { baseURI: string }) => void) => {
2001
+ return this.publicClient.watchContractEvent({
2002
+ address: this.contractAddress,
2003
+ abi: LazySovereignNFT_jsonAbi,
2004
+ eventName: 'MetadataLocked',
2005
+
2006
+ onLogs: (logs: any[]) => {
2007
+ logs.forEach((log: any) => {
2008
+ callback(log.args as any);
2009
+ });
2010
+ },
2011
+ }) as () => void;
2012
+ },
2013
+ /**
2014
+ * Watch MetadataUpdated events
2015
+ * @param callback Function to call when event is emitted
2016
+ * @param filter Optional filter for indexed parameters
2017
+ * @returns Unwatch function to stop listening
2018
+ */
2019
+ MetadataUpdated: (callback: (event: { baseURI: string }) => void) => {
2020
+ return this.publicClient.watchContractEvent({
2021
+ address: this.contractAddress,
2022
+ abi: LazySovereignNFT_jsonAbi,
2023
+ eventName: 'MetadataUpdated',
2024
+
2025
+ onLogs: (logs: any[]) => {
2026
+ logs.forEach((log: any) => {
2027
+ callback(log.args as any);
2028
+ });
2029
+ },
2030
+ }) as () => void;
2031
+ },
2032
+ /**
2033
+ * Watch OwnershipTransferred events
2034
+ * @param callback Function to call when event is emitted
2035
+ * @param filter Optional filter for indexed parameters
2036
+ * @returns Unwatch function to stop listening
2037
+ */
2038
+ OwnershipTransferred: (callback: (event: { previousOwner: `0x${string}`; newOwner: `0x${string}` }) => void, filter?: { previousOwner: `0x${string}`; newOwner: `0x${string}` }) => {
2039
+ return this.publicClient.watchContractEvent({
2040
+ address: this.contractAddress,
2041
+ abi: LazySovereignNFT_jsonAbi,
2042
+ eventName: 'OwnershipTransferred',
2043
+ args: filter,
2044
+ onLogs: (logs: any[]) => {
2045
+ logs.forEach((log: any) => {
2046
+ callback(log.args as any);
2047
+ });
2048
+ },
2049
+ }) as () => void;
2050
+ },
2051
+ /**
2052
+ * Watch PrepareMint events
2053
+ * @param callback Function to call when event is emitted
2054
+ * @param filter Optional filter for indexed parameters
2055
+ * @returns Unwatch function to stop listening
2056
+ */
2057
+ PrepareMint: (callback: (event: { numberOfTokens: bigint; baseURI: string }) => void, filter?: { numberOfTokens: bigint }) => {
2058
+ return this.publicClient.watchContractEvent({
2059
+ address: this.contractAddress,
2060
+ abi: LazySovereignNFT_jsonAbi,
2061
+ eventName: 'PrepareMint',
2062
+ args: filter,
2063
+ onLogs: (logs: any[]) => {
2064
+ logs.forEach((log: any) => {
2065
+ callback(log.args as any);
2066
+ });
2067
+ },
2068
+ }) as () => void;
2069
+ },
2070
+ /**
2071
+ * Watch TokenURIUpdated events
2072
+ * @param callback Function to call when event is emitted
2073
+ * @param filter Optional filter for indexed parameters
2074
+ * @returns Unwatch function to stop listening
2075
+ */
2076
+ TokenURIUpdated: (callback: (event: { tokenId: bigint; metadataUri: string }) => void, filter?: { tokenId: bigint }) => {
2077
+ return this.publicClient.watchContractEvent({
2078
+ address: this.contractAddress,
2079
+ abi: LazySovereignNFT_jsonAbi,
2080
+ eventName: 'TokenURIUpdated',
2081
+ args: filter,
2082
+ onLogs: (logs: any[]) => {
2083
+ logs.forEach((log: any) => {
2084
+ callback(log.args as any);
2085
+ });
2086
+ },
2087
+ }) as () => void;
2088
+ },
2089
+ /**
2090
+ * Watch Transfer events
2091
+ * @param callback Function to call when event is emitted
2092
+ * @param filter Optional filter for indexed parameters
2093
+ * @returns Unwatch function to stop listening
2094
+ */
2095
+ Transfer: (callback: (event: { from: `0x${string}`; to: `0x${string}`; tokenId: bigint }) => void, filter?: { from: `0x${string}`; to: `0x${string}`; tokenId: bigint }) => {
2096
+ return this.publicClient.watchContractEvent({
2097
+ address: this.contractAddress,
2098
+ abi: LazySovereignNFT_jsonAbi,
2099
+ eventName: 'Transfer',
2100
+ args: filter,
2101
+ onLogs: (logs: any[]) => {
2102
+ logs.forEach((log: any) => {
2103
+ callback(log.args as any);
2104
+ });
2105
+ },
2106
+ }) as () => void;
2107
+ }
2108
+ };
2109
+ }
2110
+ }