@gitmyabi/kernel 1.0.2 → 1.0.4

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