@pimlico/mock-paymaster 0.0.2

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.
Files changed (53) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/_cjs/helpers/abi.js +1049 -0
  3. package/_cjs/helpers/abi.js.map +1 -0
  4. package/_cjs/helpers/erc20-utils.js +52 -0
  5. package/_cjs/helpers/erc20-utils.js.map +1 -0
  6. package/_cjs/helpers/schema.js +263 -0
  7. package/_cjs/helpers/schema.js.map +1 -0
  8. package/_cjs/helpers/utils.js +38 -0
  9. package/_cjs/helpers/utils.js.map +1 -0
  10. package/_cjs/index.js +55 -0
  11. package/_cjs/index.js.map +1 -0
  12. package/_cjs/package.json +1 -0
  13. package/_cjs/relay.js +250 -0
  14. package/_cjs/relay.js.map +1 -0
  15. package/_cjs/singletonPaymasters.js +266 -0
  16. package/_cjs/singletonPaymasters.js.map +1 -0
  17. package/_esm/helpers/abi.js +1046 -0
  18. package/_esm/helpers/abi.js.map +1 -0
  19. package/_esm/helpers/erc20-utils.js +46 -0
  20. package/_esm/helpers/erc20-utils.js.map +1 -0
  21. package/_esm/helpers/schema.js +260 -0
  22. package/_esm/helpers/schema.js.map +1 -0
  23. package/_esm/helpers/utils.js +39 -0
  24. package/_esm/helpers/utils.js.map +1 -0
  25. package/_esm/index.js +52 -0
  26. package/_esm/index.js.map +1 -0
  27. package/_esm/package.json +1 -0
  28. package/_esm/relay.js +249 -0
  29. package/_esm/relay.js.map +1 -0
  30. package/_esm/singletonPaymasters.js +263 -0
  31. package/_esm/singletonPaymasters.js.map +1 -0
  32. package/_types/helpers/abi.d.ts +977 -0
  33. package/_types/helpers/abi.d.ts.map +1 -0
  34. package/_types/helpers/erc20-utils.d.ts +10 -0
  35. package/_types/helpers/erc20-utils.d.ts.map +1 -0
  36. package/_types/helpers/schema.d.ts +1091 -0
  37. package/_types/helpers/schema.d.ts.map +1 -0
  38. package/_types/helpers/utils.d.ts +15 -0
  39. package/_types/helpers/utils.d.ts.map +1 -0
  40. package/_types/index.d.ts +6 -0
  41. package/_types/index.d.ts.map +1 -0
  42. package/_types/relay.d.ts +86 -0
  43. package/_types/relay.d.ts.map +1 -0
  44. package/_types/singletonPaymasters.d.ts +93267 -0
  45. package/_types/singletonPaymasters.d.ts.map +1 -0
  46. package/helpers/abi.ts +1046 -0
  47. package/helpers/erc20-utils.ts +80 -0
  48. package/helpers/schema.ts +272 -0
  49. package/helpers/utils.ts +77 -0
  50. package/index.ts +78 -0
  51. package/package.json +38 -0
  52. package/relay.ts +430 -0
  53. package/singletonPaymasters.ts +381 -0
package/helpers/abi.ts ADDED
@@ -0,0 +1,1046 @@
1
+ export const SINGLETON_PAYMASTER_V07_ABI = [
2
+ {
3
+ type: "constructor",
4
+ inputs: [
5
+ {
6
+ name: "_entryPoint",
7
+ type: "address",
8
+ internalType: "address"
9
+ },
10
+ {
11
+ name: "_owner",
12
+ type: "address",
13
+ internalType: "address"
14
+ },
15
+ {
16
+ name: "_signers",
17
+ type: "address[]",
18
+ internalType: "address[]"
19
+ }
20
+ ],
21
+ stateMutability: "nonpayable"
22
+ },
23
+ {
24
+ type: "function",
25
+ name: "addSigner",
26
+ inputs: [
27
+ {
28
+ name: "_signer",
29
+ type: "address",
30
+ internalType: "address"
31
+ }
32
+ ],
33
+ outputs: [],
34
+ stateMutability: "nonpayable"
35
+ },
36
+ {
37
+ type: "function",
38
+ name: "addStake",
39
+ inputs: [
40
+ {
41
+ name: "unstakeDelaySec",
42
+ type: "uint32",
43
+ internalType: "uint32"
44
+ }
45
+ ],
46
+ outputs: [],
47
+ stateMutability: "payable"
48
+ },
49
+ {
50
+ type: "function",
51
+ name: "deposit",
52
+ inputs: [],
53
+ outputs: [],
54
+ stateMutability: "payable"
55
+ },
56
+ {
57
+ type: "function",
58
+ name: "entryPoint",
59
+ inputs: [],
60
+ outputs: [
61
+ {
62
+ name: "",
63
+ type: "address",
64
+ internalType: "contract IEntryPoint"
65
+ }
66
+ ],
67
+ stateMutability: "view"
68
+ },
69
+ {
70
+ type: "function",
71
+ name: "getCostInToken",
72
+ inputs: [
73
+ {
74
+ name: "_actualGasCost",
75
+ type: "uint256",
76
+ internalType: "uint256"
77
+ },
78
+ {
79
+ name: "_postOpGas",
80
+ type: "uint256",
81
+ internalType: "uint256"
82
+ },
83
+ {
84
+ name: "_actualUserOpFeePerGas",
85
+ type: "uint256",
86
+ internalType: "uint256"
87
+ },
88
+ {
89
+ name: "_exchangeRate",
90
+ type: "uint256",
91
+ internalType: "uint256"
92
+ }
93
+ ],
94
+ outputs: [
95
+ {
96
+ name: "",
97
+ type: "uint256",
98
+ internalType: "uint256"
99
+ }
100
+ ],
101
+ stateMutability: "pure"
102
+ },
103
+ {
104
+ type: "function",
105
+ name: "getDeposit",
106
+ inputs: [],
107
+ outputs: [
108
+ {
109
+ name: "",
110
+ type: "uint256",
111
+ internalType: "uint256"
112
+ }
113
+ ],
114
+ stateMutability: "view"
115
+ },
116
+ {
117
+ type: "function",
118
+ name: "getHash",
119
+ inputs: [
120
+ {
121
+ name: "_mode",
122
+ type: "uint8",
123
+ internalType: "uint8"
124
+ },
125
+ {
126
+ name: "_userOp",
127
+ type: "tuple",
128
+ internalType: "struct PackedUserOperation",
129
+ components: [
130
+ {
131
+ name: "sender",
132
+ type: "address",
133
+ internalType: "address"
134
+ },
135
+ {
136
+ name: "nonce",
137
+ type: "uint256",
138
+ internalType: "uint256"
139
+ },
140
+ {
141
+ name: "initCode",
142
+ type: "bytes",
143
+ internalType: "bytes"
144
+ },
145
+ {
146
+ name: "callData",
147
+ type: "bytes",
148
+ internalType: "bytes"
149
+ },
150
+ {
151
+ name: "accountGasLimits",
152
+ type: "bytes32",
153
+ internalType: "bytes32"
154
+ },
155
+ {
156
+ name: "preVerificationGas",
157
+ type: "uint256",
158
+ internalType: "uint256"
159
+ },
160
+ {
161
+ name: "gasFees",
162
+ type: "bytes32",
163
+ internalType: "bytes32"
164
+ },
165
+ {
166
+ name: "paymasterAndData",
167
+ type: "bytes",
168
+ internalType: "bytes"
169
+ },
170
+ {
171
+ name: "signature",
172
+ type: "bytes",
173
+ internalType: "bytes"
174
+ }
175
+ ]
176
+ }
177
+ ],
178
+ outputs: [
179
+ {
180
+ name: "",
181
+ type: "bytes32",
182
+ internalType: "bytes32"
183
+ }
184
+ ],
185
+ stateMutability: "view"
186
+ },
187
+ {
188
+ type: "function",
189
+ name: "owner",
190
+ inputs: [],
191
+ outputs: [
192
+ {
193
+ name: "",
194
+ type: "address",
195
+ internalType: "address"
196
+ }
197
+ ],
198
+ stateMutability: "view"
199
+ },
200
+ {
201
+ type: "function",
202
+ name: "postOp",
203
+ inputs: [
204
+ {
205
+ name: "mode",
206
+ type: "uint8",
207
+ internalType: "enum PostOpMode"
208
+ },
209
+ {
210
+ name: "context",
211
+ type: "bytes",
212
+ internalType: "bytes"
213
+ },
214
+ {
215
+ name: "actualGasCost",
216
+ type: "uint256",
217
+ internalType: "uint256"
218
+ },
219
+ {
220
+ name: "actualUserOpFeePerGas",
221
+ type: "uint256",
222
+ internalType: "uint256"
223
+ }
224
+ ],
225
+ outputs: [],
226
+ stateMutability: "nonpayable"
227
+ },
228
+ {
229
+ type: "function",
230
+ name: "removeSigner",
231
+ inputs: [
232
+ {
233
+ name: "_signer",
234
+ type: "address",
235
+ internalType: "address"
236
+ }
237
+ ],
238
+ outputs: [],
239
+ stateMutability: "nonpayable"
240
+ },
241
+ {
242
+ type: "function",
243
+ name: "renounceOwnership",
244
+ inputs: [],
245
+ outputs: [],
246
+ stateMutability: "nonpayable"
247
+ },
248
+ {
249
+ type: "function",
250
+ name: "setTreasury",
251
+ inputs: [
252
+ {
253
+ name: "_treasury",
254
+ type: "address",
255
+ internalType: "address"
256
+ }
257
+ ],
258
+ outputs: [],
259
+ stateMutability: "nonpayable"
260
+ },
261
+ {
262
+ type: "function",
263
+ name: "signers",
264
+ inputs: [
265
+ {
266
+ name: "account",
267
+ type: "address",
268
+ internalType: "address"
269
+ }
270
+ ],
271
+ outputs: [
272
+ {
273
+ name: "isValidSigner",
274
+ type: "bool",
275
+ internalType: "bool"
276
+ }
277
+ ],
278
+ stateMutability: "view"
279
+ },
280
+ {
281
+ type: "function",
282
+ name: "transferOwnership",
283
+ inputs: [
284
+ {
285
+ name: "newOwner",
286
+ type: "address",
287
+ internalType: "address"
288
+ }
289
+ ],
290
+ outputs: [],
291
+ stateMutability: "nonpayable"
292
+ },
293
+ {
294
+ type: "function",
295
+ name: "treasury",
296
+ inputs: [],
297
+ outputs: [
298
+ {
299
+ name: "",
300
+ type: "address",
301
+ internalType: "address"
302
+ }
303
+ ],
304
+ stateMutability: "view"
305
+ },
306
+ {
307
+ type: "function",
308
+ name: "unlockStake",
309
+ inputs: [],
310
+ outputs: [],
311
+ stateMutability: "nonpayable"
312
+ },
313
+ {
314
+ type: "function",
315
+ name: "validatePaymasterUserOp",
316
+ inputs: [
317
+ {
318
+ name: "userOp",
319
+ type: "tuple",
320
+ internalType: "struct PackedUserOperation",
321
+ components: [
322
+ {
323
+ name: "sender",
324
+ type: "address",
325
+ internalType: "address"
326
+ },
327
+ {
328
+ name: "nonce",
329
+ type: "uint256",
330
+ internalType: "uint256"
331
+ },
332
+ {
333
+ name: "initCode",
334
+ type: "bytes",
335
+ internalType: "bytes"
336
+ },
337
+ {
338
+ name: "callData",
339
+ type: "bytes",
340
+ internalType: "bytes"
341
+ },
342
+ {
343
+ name: "accountGasLimits",
344
+ type: "bytes32",
345
+ internalType: "bytes32"
346
+ },
347
+ {
348
+ name: "preVerificationGas",
349
+ type: "uint256",
350
+ internalType: "uint256"
351
+ },
352
+ {
353
+ name: "gasFees",
354
+ type: "bytes32",
355
+ internalType: "bytes32"
356
+ },
357
+ {
358
+ name: "paymasterAndData",
359
+ type: "bytes",
360
+ internalType: "bytes"
361
+ },
362
+ {
363
+ name: "signature",
364
+ type: "bytes",
365
+ internalType: "bytes"
366
+ }
367
+ ]
368
+ },
369
+ {
370
+ name: "userOpHash",
371
+ type: "bytes32",
372
+ internalType: "bytes32"
373
+ },
374
+ {
375
+ name: "maxCost",
376
+ type: "uint256",
377
+ internalType: "uint256"
378
+ }
379
+ ],
380
+ outputs: [
381
+ {
382
+ name: "context",
383
+ type: "bytes",
384
+ internalType: "bytes"
385
+ },
386
+ {
387
+ name: "validationData",
388
+ type: "uint256",
389
+ internalType: "uint256"
390
+ }
391
+ ],
392
+ stateMutability: "nonpayable"
393
+ },
394
+ {
395
+ type: "function",
396
+ name: "withdrawStake",
397
+ inputs: [
398
+ {
399
+ name: "withdrawAddress",
400
+ type: "address",
401
+ internalType: "address payable"
402
+ }
403
+ ],
404
+ outputs: [],
405
+ stateMutability: "nonpayable"
406
+ },
407
+ {
408
+ type: "function",
409
+ name: "withdrawTo",
410
+ inputs: [
411
+ {
412
+ name: "withdrawAddress",
413
+ type: "address",
414
+ internalType: "address payable"
415
+ },
416
+ {
417
+ name: "amount",
418
+ type: "uint256",
419
+ internalType: "uint256"
420
+ }
421
+ ],
422
+ outputs: [],
423
+ stateMutability: "nonpayable"
424
+ },
425
+ {
426
+ type: "event",
427
+ name: "OwnershipTransferred",
428
+ inputs: [
429
+ {
430
+ name: "previousOwner",
431
+ type: "address",
432
+ indexed: true,
433
+ internalType: "address"
434
+ },
435
+ {
436
+ name: "newOwner",
437
+ type: "address",
438
+ indexed: true,
439
+ internalType: "address"
440
+ }
441
+ ],
442
+ anonymous: false
443
+ },
444
+ {
445
+ type: "event",
446
+ name: "SignerAdded",
447
+ inputs: [
448
+ {
449
+ name: "signer",
450
+ type: "address",
451
+ indexed: false,
452
+ internalType: "address"
453
+ }
454
+ ],
455
+ anonymous: false
456
+ },
457
+ {
458
+ type: "event",
459
+ name: "SignerRemoved",
460
+ inputs: [
461
+ {
462
+ name: "signer",
463
+ type: "address",
464
+ indexed: false,
465
+ internalType: "address"
466
+ }
467
+ ],
468
+ anonymous: false
469
+ },
470
+ {
471
+ type: "event",
472
+ name: "TreasuryUpdated",
473
+ inputs: [
474
+ {
475
+ name: "oldTreasury",
476
+ type: "address",
477
+ indexed: false,
478
+ internalType: "address"
479
+ },
480
+ {
481
+ name: "newTreasury",
482
+ type: "address",
483
+ indexed: false,
484
+ internalType: "address"
485
+ }
486
+ ],
487
+ anonymous: false
488
+ },
489
+ {
490
+ type: "event",
491
+ name: "UserOperationSponsored",
492
+ inputs: [
493
+ {
494
+ name: "userOpHash",
495
+ type: "bytes32",
496
+ indexed: true,
497
+ internalType: "bytes32"
498
+ },
499
+ {
500
+ name: "user",
501
+ type: "address",
502
+ indexed: true,
503
+ internalType: "address"
504
+ },
505
+ {
506
+ name: "paymasterMode",
507
+ type: "uint8",
508
+ indexed: false,
509
+ internalType: "uint8"
510
+ },
511
+ {
512
+ name: "token",
513
+ type: "address",
514
+ indexed: false,
515
+ internalType: "address"
516
+ },
517
+ {
518
+ name: "tokenAmountPaid",
519
+ type: "uint256",
520
+ indexed: false,
521
+ internalType: "uint256"
522
+ },
523
+ {
524
+ name: "exchangeRate",
525
+ type: "uint256",
526
+ indexed: false,
527
+ internalType: "uint256"
528
+ }
529
+ ],
530
+ anonymous: false
531
+ },
532
+ {
533
+ type: "error",
534
+ name: "ECDSAInvalidSignature",
535
+ inputs: []
536
+ },
537
+ {
538
+ type: "error",
539
+ name: "ECDSAInvalidSignatureLength",
540
+ inputs: [
541
+ {
542
+ name: "length",
543
+ type: "uint256",
544
+ internalType: "uint256"
545
+ }
546
+ ]
547
+ },
548
+ {
549
+ type: "error",
550
+ name: "ECDSAInvalidSignatureS",
551
+ inputs: [
552
+ {
553
+ name: "s",
554
+ type: "bytes32",
555
+ internalType: "bytes32"
556
+ }
557
+ ]
558
+ },
559
+ {
560
+ type: "error",
561
+ name: "ExchangeRateInvalid",
562
+ inputs: []
563
+ },
564
+ {
565
+ type: "error",
566
+ name: "OwnableInvalidOwner",
567
+ inputs: [
568
+ {
569
+ name: "owner",
570
+ type: "address",
571
+ internalType: "address"
572
+ }
573
+ ]
574
+ },
575
+ {
576
+ type: "error",
577
+ name: "OwnableUnauthorizedAccount",
578
+ inputs: [
579
+ {
580
+ name: "account",
581
+ type: "address",
582
+ internalType: "address"
583
+ }
584
+ ]
585
+ },
586
+ {
587
+ type: "error",
588
+ name: "PaymasterAndDataLengthInvalid",
589
+ inputs: []
590
+ },
591
+ {
592
+ type: "error",
593
+ name: "PaymasterConfigLengthInvalid",
594
+ inputs: []
595
+ },
596
+ {
597
+ type: "error",
598
+ name: "PaymasterModeInvalid",
599
+ inputs: []
600
+ },
601
+ {
602
+ type: "error",
603
+ name: "PaymasterSignatureLengthInvalid",
604
+ inputs: []
605
+ },
606
+ {
607
+ type: "error",
608
+ name: "PostOpTransferFromFailed",
609
+ inputs: [
610
+ {
611
+ name: "msg",
612
+ type: "string",
613
+ internalType: "string"
614
+ }
615
+ ]
616
+ },
617
+ {
618
+ type: "error",
619
+ name: "TokenAddressInvalid",
620
+ inputs: []
621
+ }
622
+ ] as const
623
+
624
+ export const SINGLETON_PAYMASTER_V06_ABI = [
625
+ {
626
+ inputs: [
627
+ { internalType: "address", name: "_entryPoint", type: "address" },
628
+ { internalType: "address", name: "_owner", type: "address" },
629
+ { internalType: "address[]", name: "_signers", type: "address[]" }
630
+ ],
631
+ stateMutability: "nonpayable",
632
+ type: "constructor"
633
+ },
634
+ { inputs: [], name: "ECDSAInvalidSignature", type: "error" },
635
+ {
636
+ inputs: [{ internalType: "uint256", name: "length", type: "uint256" }],
637
+ name: "ECDSAInvalidSignatureLength",
638
+ type: "error"
639
+ },
640
+ {
641
+ inputs: [{ internalType: "bytes32", name: "s", type: "bytes32" }],
642
+ name: "ECDSAInvalidSignatureS",
643
+ type: "error"
644
+ },
645
+ { inputs: [], name: "ExchangeRateInvalid", type: "error" },
646
+ {
647
+ inputs: [{ internalType: "address", name: "owner", type: "address" }],
648
+ name: "OwnableInvalidOwner",
649
+ type: "error"
650
+ },
651
+ {
652
+ inputs: [{ internalType: "address", name: "account", type: "address" }],
653
+ name: "OwnableUnauthorizedAccount",
654
+ type: "error"
655
+ },
656
+ { inputs: [], name: "PaymasterAndDataLengthInvalid", type: "error" },
657
+ { inputs: [], name: "PaymasterConfigLengthInvalid", type: "error" },
658
+ { inputs: [], name: "PaymasterModeInvalid", type: "error" },
659
+ { inputs: [], name: "PaymasterSignatureLengthInvalid", type: "error" },
660
+ {
661
+ inputs: [{ internalType: "string", name: "msg", type: "string" }],
662
+ name: "PostOpTransferFromFailed",
663
+ type: "error"
664
+ },
665
+ { inputs: [], name: "TokenAddressInvalid", type: "error" },
666
+ {
667
+ anonymous: false,
668
+ inputs: [
669
+ {
670
+ indexed: true,
671
+ internalType: "address",
672
+ name: "previousOwner",
673
+ type: "address"
674
+ },
675
+ {
676
+ indexed: true,
677
+ internalType: "address",
678
+ name: "newOwner",
679
+ type: "address"
680
+ }
681
+ ],
682
+ name: "OwnershipTransferred",
683
+ type: "event"
684
+ },
685
+ {
686
+ anonymous: false,
687
+ inputs: [
688
+ {
689
+ indexed: false,
690
+ internalType: "address",
691
+ name: "signer",
692
+ type: "address"
693
+ }
694
+ ],
695
+ name: "SignerAdded",
696
+ type: "event"
697
+ },
698
+ {
699
+ anonymous: false,
700
+ inputs: [
701
+ {
702
+ indexed: false,
703
+ internalType: "address",
704
+ name: "signer",
705
+ type: "address"
706
+ }
707
+ ],
708
+ name: "SignerRemoved",
709
+ type: "event"
710
+ },
711
+ {
712
+ anonymous: false,
713
+ inputs: [
714
+ {
715
+ indexed: false,
716
+ internalType: "address",
717
+ name: "oldTreasury",
718
+ type: "address"
719
+ },
720
+ {
721
+ indexed: false,
722
+ internalType: "address",
723
+ name: "newTreasury",
724
+ type: "address"
725
+ }
726
+ ],
727
+ name: "TreasuryUpdated",
728
+ type: "event"
729
+ },
730
+ {
731
+ anonymous: false,
732
+ inputs: [
733
+ {
734
+ indexed: true,
735
+ internalType: "bytes32",
736
+ name: "userOpHash",
737
+ type: "bytes32"
738
+ },
739
+ {
740
+ indexed: true,
741
+ internalType: "address",
742
+ name: "user",
743
+ type: "address"
744
+ },
745
+ {
746
+ indexed: false,
747
+ internalType: "uint8",
748
+ name: "paymasterMode",
749
+ type: "uint8"
750
+ },
751
+ {
752
+ indexed: false,
753
+ internalType: "address",
754
+ name: "token",
755
+ type: "address"
756
+ },
757
+ {
758
+ indexed: false,
759
+ internalType: "uint256",
760
+ name: "tokenAmountPaid",
761
+ type: "uint256"
762
+ },
763
+ {
764
+ indexed: false,
765
+ internalType: "uint256",
766
+ name: "exchangeRate",
767
+ type: "uint256"
768
+ }
769
+ ],
770
+ name: "UserOperationSponsored",
771
+ type: "event"
772
+ },
773
+ {
774
+ inputs: [{ internalType: "address", name: "_signer", type: "address" }],
775
+ name: "addSigner",
776
+ outputs: [],
777
+ stateMutability: "nonpayable",
778
+ type: "function"
779
+ },
780
+ {
781
+ inputs: [
782
+ { internalType: "uint32", name: "unstakeDelaySec", type: "uint32" }
783
+ ],
784
+ name: "addStake",
785
+ outputs: [],
786
+ stateMutability: "payable",
787
+ type: "function"
788
+ },
789
+ {
790
+ inputs: [],
791
+ name: "deposit",
792
+ outputs: [],
793
+ stateMutability: "payable",
794
+ type: "function"
795
+ },
796
+ {
797
+ inputs: [],
798
+ name: "entryPoint",
799
+ outputs: [
800
+ { internalType: "contract IEntryPoint", name: "", type: "address" }
801
+ ],
802
+ stateMutability: "view",
803
+ type: "function"
804
+ },
805
+ {
806
+ inputs: [
807
+ {
808
+ internalType: "uint256",
809
+ name: "_actualGasCost",
810
+ type: "uint256"
811
+ },
812
+ { internalType: "uint256", name: "_postOpGas", type: "uint256" },
813
+ {
814
+ internalType: "uint256",
815
+ name: "_actualUserOpFeePerGas",
816
+ type: "uint256"
817
+ },
818
+ { internalType: "uint256", name: "_exchangeRate", type: "uint256" }
819
+ ],
820
+ name: "getCostInToken",
821
+ outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
822
+ stateMutability: "pure",
823
+ type: "function"
824
+ },
825
+ {
826
+ inputs: [],
827
+ name: "getDeposit",
828
+ outputs: [{ internalType: "uint256", name: "", type: "uint256" }],
829
+ stateMutability: "view",
830
+ type: "function"
831
+ },
832
+ {
833
+ inputs: [
834
+ { internalType: "uint8", name: "_mode", type: "uint8" },
835
+ {
836
+ components: [
837
+ {
838
+ internalType: "address",
839
+ name: "sender",
840
+ type: "address"
841
+ },
842
+ { internalType: "uint256", name: "nonce", type: "uint256" },
843
+ { internalType: "bytes", name: "initCode", type: "bytes" },
844
+ { internalType: "bytes", name: "callData", type: "bytes" },
845
+ {
846
+ internalType: "uint256",
847
+ name: "callGasLimit",
848
+ type: "uint256"
849
+ },
850
+ {
851
+ internalType: "uint256",
852
+ name: "verificationGasLimit",
853
+ type: "uint256"
854
+ },
855
+ {
856
+ internalType: "uint256",
857
+ name: "preVerificationGas",
858
+ type: "uint256"
859
+ },
860
+ {
861
+ internalType: "uint256",
862
+ name: "maxFeePerGas",
863
+ type: "uint256"
864
+ },
865
+ {
866
+ internalType: "uint256",
867
+ name: "maxPriorityFeePerGas",
868
+ type: "uint256"
869
+ },
870
+ {
871
+ internalType: "bytes",
872
+ name: "paymasterAndData",
873
+ type: "bytes"
874
+ },
875
+ { internalType: "bytes", name: "signature", type: "bytes" }
876
+ ],
877
+ internalType: "struct UserOperation",
878
+ name: "_userOp",
879
+ type: "tuple"
880
+ }
881
+ ],
882
+ name: "getHash",
883
+ outputs: [{ internalType: "bytes32", name: "", type: "bytes32" }],
884
+ stateMutability: "view",
885
+ type: "function"
886
+ },
887
+ {
888
+ inputs: [],
889
+ name: "owner",
890
+ outputs: [{ internalType: "address", name: "", type: "address" }],
891
+ stateMutability: "view",
892
+ type: "function"
893
+ },
894
+ {
895
+ inputs: [
896
+ { internalType: "enum PostOpMode", name: "mode", type: "uint8" },
897
+ { internalType: "bytes", name: "context", type: "bytes" },
898
+ { internalType: "uint256", name: "actualGasCost", type: "uint256" }
899
+ ],
900
+ name: "postOp",
901
+ outputs: [],
902
+ stateMutability: "nonpayable",
903
+ type: "function"
904
+ },
905
+ {
906
+ inputs: [{ internalType: "address", name: "_signer", type: "address" }],
907
+ name: "removeSigner",
908
+ outputs: [],
909
+ stateMutability: "nonpayable",
910
+ type: "function"
911
+ },
912
+ {
913
+ inputs: [],
914
+ name: "renounceOwnership",
915
+ outputs: [],
916
+ stateMutability: "nonpayable",
917
+ type: "function"
918
+ },
919
+ {
920
+ inputs: [
921
+ { internalType: "address", name: "_treasury", type: "address" }
922
+ ],
923
+ name: "setTreasury",
924
+ outputs: [],
925
+ stateMutability: "nonpayable",
926
+ type: "function"
927
+ },
928
+ {
929
+ inputs: [{ internalType: "address", name: "account", type: "address" }],
930
+ name: "signers",
931
+ outputs: [
932
+ { internalType: "bool", name: "isValidSigner", type: "bool" }
933
+ ],
934
+ stateMutability: "view",
935
+ type: "function"
936
+ },
937
+ {
938
+ inputs: [
939
+ { internalType: "address", name: "newOwner", type: "address" }
940
+ ],
941
+ name: "transferOwnership",
942
+ outputs: [],
943
+ stateMutability: "nonpayable",
944
+ type: "function"
945
+ },
946
+ {
947
+ inputs: [],
948
+ name: "treasury",
949
+ outputs: [{ internalType: "address", name: "", type: "address" }],
950
+ stateMutability: "view",
951
+ type: "function"
952
+ },
953
+ {
954
+ inputs: [],
955
+ name: "unlockStake",
956
+ outputs: [],
957
+ stateMutability: "nonpayable",
958
+ type: "function"
959
+ },
960
+ {
961
+ inputs: [
962
+ {
963
+ components: [
964
+ {
965
+ internalType: "address",
966
+ name: "sender",
967
+ type: "address"
968
+ },
969
+ { internalType: "uint256", name: "nonce", type: "uint256" },
970
+ { internalType: "bytes", name: "initCode", type: "bytes" },
971
+ { internalType: "bytes", name: "callData", type: "bytes" },
972
+ {
973
+ internalType: "uint256",
974
+ name: "callGasLimit",
975
+ type: "uint256"
976
+ },
977
+ {
978
+ internalType: "uint256",
979
+ name: "verificationGasLimit",
980
+ type: "uint256"
981
+ },
982
+ {
983
+ internalType: "uint256",
984
+ name: "preVerificationGas",
985
+ type: "uint256"
986
+ },
987
+ {
988
+ internalType: "uint256",
989
+ name: "maxFeePerGas",
990
+ type: "uint256"
991
+ },
992
+ {
993
+ internalType: "uint256",
994
+ name: "maxPriorityFeePerGas",
995
+ type: "uint256"
996
+ },
997
+ {
998
+ internalType: "bytes",
999
+ name: "paymasterAndData",
1000
+ type: "bytes"
1001
+ },
1002
+ { internalType: "bytes", name: "signature", type: "bytes" }
1003
+ ],
1004
+ internalType: "struct UserOperation",
1005
+ name: "userOp",
1006
+ type: "tuple"
1007
+ },
1008
+ { internalType: "bytes32", name: "userOpHash", type: "bytes32" },
1009
+ { internalType: "uint256", name: "maxCost", type: "uint256" }
1010
+ ],
1011
+ name: "validatePaymasterUserOp",
1012
+ outputs: [
1013
+ { internalType: "bytes", name: "context", type: "bytes" },
1014
+ { internalType: "uint256", name: "validationData", type: "uint256" }
1015
+ ],
1016
+ stateMutability: "nonpayable",
1017
+ type: "function"
1018
+ },
1019
+ {
1020
+ inputs: [
1021
+ {
1022
+ internalType: "address payable",
1023
+ name: "withdrawAddress",
1024
+ type: "address"
1025
+ }
1026
+ ],
1027
+ name: "withdrawStake",
1028
+ outputs: [],
1029
+ stateMutability: "nonpayable",
1030
+ type: "function"
1031
+ },
1032
+ {
1033
+ inputs: [
1034
+ {
1035
+ internalType: "address payable",
1036
+ name: "withdrawAddress",
1037
+ type: "address"
1038
+ },
1039
+ { internalType: "uint256", name: "amount", type: "uint256" }
1040
+ ],
1041
+ name: "withdrawTo",
1042
+ outputs: [],
1043
+ stateMutability: "nonpayable",
1044
+ type: "function"
1045
+ }
1046
+ ] as const