@pepu-chain/sdk 0.0.0-stage → 0.2.1

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 (244) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +590 -2
  3. package/dist/aa/kernel.cjs +41 -0
  4. package/dist/aa/kernel.cjs.map +1 -0
  5. package/dist/aa/kernel.d.cts +88 -0
  6. package/dist/aa/kernel.d.ts +88 -0
  7. package/dist/aa/kernel.guard.js +15 -0
  8. package/dist/aa/kernel.js +11 -0
  9. package/dist/aa/kernel.js.map +1 -0
  10. package/dist/aa/react-direct.cjs +111 -0
  11. package/dist/aa/react-direct.cjs.map +1 -0
  12. package/dist/aa/react-direct.d.cts +42 -0
  13. package/dist/aa/react-direct.d.ts +42 -0
  14. package/dist/aa/react-direct.guard.js +15 -0
  15. package/dist/aa/react-direct.js +107 -0
  16. package/dist/aa/react-direct.js.map +1 -0
  17. package/dist/aa/react.cjs +152 -0
  18. package/dist/aa/react.cjs.map +1 -0
  19. package/dist/aa/react.d.cts +62 -0
  20. package/dist/aa/react.d.ts +62 -0
  21. package/dist/aa/react.guard.js +15 -0
  22. package/dist/aa/react.js +147 -0
  23. package/dist/aa/react.js.map +1 -0
  24. package/dist/aa.cjs +84 -0
  25. package/dist/aa.cjs.map +1 -0
  26. package/dist/aa.d.cts +85 -0
  27. package/dist/aa.d.ts +85 -0
  28. package/dist/aa.js +11 -0
  29. package/dist/aa.js.map +1 -0
  30. package/dist/api-Dz4sCHH_.d.cts +654 -0
  31. package/dist/api-Dz4sCHH_.d.ts +654 -0
  32. package/dist/calls-BRPjKgjl.d.cts +70 -0
  33. package/dist/calls-z_EQOtFb.d.ts +70 -0
  34. package/dist/chains-DK13zGIp.d.cts +235 -0
  35. package/dist/chains-DK13zGIp.d.ts +235 -0
  36. package/dist/chunk-3XUGQODR.js +194 -0
  37. package/dist/chunk-3XUGQODR.js.map +1 -0
  38. package/dist/chunk-45KSZH26.cjs +145 -0
  39. package/dist/chunk-45KSZH26.cjs.map +1 -0
  40. package/dist/chunk-4GINFJO6.cjs +44 -0
  41. package/dist/chunk-4GINFJO6.cjs.map +1 -0
  42. package/dist/chunk-62M2LKQW.js +136 -0
  43. package/dist/chunk-62M2LKQW.js.map +1 -0
  44. package/dist/chunk-6DSZ4Z2N.js +498 -0
  45. package/dist/chunk-6DSZ4Z2N.js.map +1 -0
  46. package/dist/chunk-7MNJF2OB.cjs +72 -0
  47. package/dist/chunk-7MNJF2OB.cjs.map +1 -0
  48. package/dist/chunk-7PVR7QSE.js +45 -0
  49. package/dist/chunk-7PVR7QSE.js.map +1 -0
  50. package/dist/chunk-A5LP2UCS.cjs +2729 -0
  51. package/dist/chunk-A5LP2UCS.cjs.map +1 -0
  52. package/dist/chunk-AJS4UFQX.cjs +121 -0
  53. package/dist/chunk-AJS4UFQX.cjs.map +1 -0
  54. package/dist/chunk-BGALSKAF.cjs +315 -0
  55. package/dist/chunk-BGALSKAF.cjs.map +1 -0
  56. package/dist/chunk-C2XW44FI.cjs +200 -0
  57. package/dist/chunk-C2XW44FI.cjs.map +1 -0
  58. package/dist/chunk-C7IC36XS.cjs +13 -0
  59. package/dist/chunk-C7IC36XS.cjs.map +1 -0
  60. package/dist/chunk-D52PADVY.js +84 -0
  61. package/dist/chunk-D52PADVY.js.map +1 -0
  62. package/dist/chunk-DH6BFNVJ.cjs +272 -0
  63. package/dist/chunk-DH6BFNVJ.cjs.map +1 -0
  64. package/dist/chunk-DPCZJLB3.cjs +87 -0
  65. package/dist/chunk-DPCZJLB3.cjs.map +1 -0
  66. package/dist/chunk-EHBPIYY4.js +262 -0
  67. package/dist/chunk-EHBPIYY4.js.map +1 -0
  68. package/dist/chunk-ESMNAXUI.js +86 -0
  69. package/dist/chunk-ESMNAXUI.js.map +1 -0
  70. package/dist/chunk-F2R473FR.js +304 -0
  71. package/dist/chunk-F2R473FR.js.map +1 -0
  72. package/dist/chunk-IB2FSPMJ.js +66 -0
  73. package/dist/chunk-IB2FSPMJ.js.map +1 -0
  74. package/dist/chunk-IG7RSL2Y.cjs +178 -0
  75. package/dist/chunk-IG7RSL2Y.cjs.map +1 -0
  76. package/dist/chunk-IY3ALPUJ.js +2716 -0
  77. package/dist/chunk-IY3ALPUJ.js.map +1 -0
  78. package/dist/chunk-J3O2ZGG3.cjs +93 -0
  79. package/dist/chunk-J3O2ZGG3.cjs.map +1 -0
  80. package/dist/chunk-J6UXXHBE.js +37 -0
  81. package/dist/chunk-J6UXXHBE.js.map +1 -0
  82. package/dist/chunk-JLZ4LZ4Z.js +22 -0
  83. package/dist/chunk-JLZ4LZ4Z.js.map +1 -0
  84. package/dist/chunk-K7JSQPZO.cjs +231 -0
  85. package/dist/chunk-K7JSQPZO.cjs.map +1 -0
  86. package/dist/chunk-KJYNF5KH.js +224 -0
  87. package/dist/chunk-KJYNF5KH.js.map +1 -0
  88. package/dist/chunk-KVG3AYYR.js +99 -0
  89. package/dist/chunk-KVG3AYYR.js.map +1 -0
  90. package/dist/chunk-NE3QKDOB.cjs +24 -0
  91. package/dist/chunk-NE3QKDOB.cjs.map +1 -0
  92. package/dist/chunk-NVOPDXTA.cjs +95 -0
  93. package/dist/chunk-NVOPDXTA.cjs.map +1 -0
  94. package/dist/chunk-OH3QMAIB.js +11 -0
  95. package/dist/chunk-OH3QMAIB.js.map +1 -0
  96. package/dist/chunk-PHM3ZORG.cjs +110 -0
  97. package/dist/chunk-PHM3ZORG.cjs.map +1 -0
  98. package/dist/chunk-R5PXQNO3.cjs +209 -0
  99. package/dist/chunk-R5PXQNO3.cjs.map +1 -0
  100. package/dist/chunk-RCMKPJZO.cjs +49 -0
  101. package/dist/chunk-RCMKPJZO.cjs.map +1 -0
  102. package/dist/chunk-SVWRRALU.cjs +17 -0
  103. package/dist/chunk-SVWRRALU.cjs.map +1 -0
  104. package/dist/chunk-T43PQXJD.js +202 -0
  105. package/dist/chunk-T43PQXJD.js.map +1 -0
  106. package/dist/chunk-VBH3JLQ5.js +116 -0
  107. package/dist/chunk-VBH3JLQ5.js.map +1 -0
  108. package/dist/chunk-VF3D6KLQ.cjs +94 -0
  109. package/dist/chunk-VF3D6KLQ.cjs.map +1 -0
  110. package/dist/chunk-VTQIHMF3.js +82 -0
  111. package/dist/chunk-VTQIHMF3.js.map +1 -0
  112. package/dist/chunk-W3JN3YIW.js +15 -0
  113. package/dist/chunk-W3JN3YIW.js.map +1 -0
  114. package/dist/chunk-WANILJZQ.cjs +87 -0
  115. package/dist/chunk-WANILJZQ.cjs.map +1 -0
  116. package/dist/chunk-XC4IBCI2.js +86 -0
  117. package/dist/chunk-XC4IBCI2.js.map +1 -0
  118. package/dist/chunk-YKEWWQEJ.js +165 -0
  119. package/dist/chunk-YKEWWQEJ.js.map +1 -0
  120. package/dist/chunk-YQL7NISX.cjs +515 -0
  121. package/dist/chunk-YQL7NISX.cjs.map +1 -0
  122. package/dist/chunk-ZB6SVBK4.js +89 -0
  123. package/dist/chunk-ZB6SVBK4.js.map +1 -0
  124. package/dist/combo/react.cjs +236 -0
  125. package/dist/combo/react.cjs.map +1 -0
  126. package/dist/combo/react.d.cts +148 -0
  127. package/dist/combo/react.d.ts +148 -0
  128. package/dist/combo/react.guard.js +15 -0
  129. package/dist/combo/react.js +230 -0
  130. package/dist/combo/react.js.map +1 -0
  131. package/dist/combo.cjs +263 -0
  132. package/dist/combo.cjs.map +1 -0
  133. package/dist/combo.d.cts +139 -0
  134. package/dist/combo.d.ts +139 -0
  135. package/dist/combo.guard.js +15 -0
  136. package/dist/combo.js +249 -0
  137. package/dist/combo.js.map +1 -0
  138. package/dist/config-CHjz7ZjZ.d.cts +57 -0
  139. package/dist/config-COjhIZTh.d.ts +57 -0
  140. package/dist/doctor.cjs +354 -0
  141. package/dist/doctor.cjs.map +1 -0
  142. package/dist/doctor.d.cts +177 -0
  143. package/dist/doctor.d.ts +177 -0
  144. package/dist/doctor.js +345 -0
  145. package/dist/doctor.js.map +1 -0
  146. package/dist/erc7677-DOW58QBE.d.cts +111 -0
  147. package/dist/erc7677-DOW58QBE.d.ts +111 -0
  148. package/dist/errors-CgX1vNj7.d.cts +100 -0
  149. package/dist/errors-CgX1vNj7.d.ts +100 -0
  150. package/dist/index.cjs +806 -0
  151. package/dist/index.cjs.map +1 -0
  152. package/dist/index.d.cts +2398 -0
  153. package/dist/index.d.ts +2398 -0
  154. package/dist/index.js +559 -0
  155. package/dist/index.js.map +1 -0
  156. package/dist/paymaster/server.cjs +38 -0
  157. package/dist/paymaster/server.cjs.map +1 -0
  158. package/dist/paymaster/server.d.cts +57 -0
  159. package/dist/paymaster/server.d.ts +57 -0
  160. package/dist/paymaster/server.js +36 -0
  161. package/dist/paymaster/server.js.map +1 -0
  162. package/dist/paymaster.cjs +356 -0
  163. package/dist/paymaster.cjs.map +1 -0
  164. package/dist/paymaster.d.cts +1851 -0
  165. package/dist/paymaster.d.ts +1851 -0
  166. package/dist/paymaster.js +289 -0
  167. package/dist/paymaster.js.map +1 -0
  168. package/dist/privy/react.cjs +49 -0
  169. package/dist/privy/react.cjs.map +1 -0
  170. package/dist/privy/react.d.cts +194 -0
  171. package/dist/privy/react.d.ts +194 -0
  172. package/dist/privy/react.guard.js +15 -0
  173. package/dist/privy/react.js +7 -0
  174. package/dist/privy/react.js.map +1 -0
  175. package/dist/privy/server.cjs +44 -0
  176. package/dist/privy/server.cjs.map +1 -0
  177. package/dist/privy/server.d.cts +192 -0
  178. package/dist/privy/server.d.ts +192 -0
  179. package/dist/privy/server.guard.js +15 -0
  180. package/dist/privy/server.js +6 -0
  181. package/dist/privy/server.js.map +1 -0
  182. package/dist/privy/wagmi.d.ts +90 -0
  183. package/dist/privy/wagmi.guard.js +15 -0
  184. package/dist/privy/wagmi.js +55 -0
  185. package/dist/privy/wagmi.js.map +1 -0
  186. package/dist/privy.cjs +34 -0
  187. package/dist/privy.cjs.map +1 -0
  188. package/dist/privy.d.cts +4 -0
  189. package/dist/privy.d.ts +4 -0
  190. package/dist/privy.js +5 -0
  191. package/dist/privy.js.map +1 -0
  192. package/dist/react.cjs +73 -0
  193. package/dist/react.cjs.map +1 -0
  194. package/dist/react.d.cts +66 -0
  195. package/dist/react.d.ts +66 -0
  196. package/dist/react.guard.js +15 -0
  197. package/dist/react.js +68 -0
  198. package/dist/react.js.map +1 -0
  199. package/dist/requirements-C-QiJkL9.d.cts +134 -0
  200. package/dist/requirements-C-QiJkL9.d.ts +134 -0
  201. package/dist/scope-DBRkN7bR.d.cts +94 -0
  202. package/dist/scope-DBRkN7bR.d.ts +94 -0
  203. package/dist/server.cjs +59 -0
  204. package/dist/server.cjs.map +1 -0
  205. package/dist/server.d.cts +208 -0
  206. package/dist/server.d.ts +208 -0
  207. package/dist/server.js +8 -0
  208. package/dist/server.js.map +1 -0
  209. package/dist/session/kernel.cjs +83 -0
  210. package/dist/session/kernel.cjs.map +1 -0
  211. package/dist/session/kernel.d.cts +131 -0
  212. package/dist/session/kernel.d.ts +131 -0
  213. package/dist/session/kernel.guard.js +15 -0
  214. package/dist/session/kernel.js +13 -0
  215. package/dist/session/kernel.js.map +1 -0
  216. package/dist/session/react.cjs +38 -0
  217. package/dist/session/react.cjs.map +1 -0
  218. package/dist/session/react.d.cts +119 -0
  219. package/dist/session/react.d.ts +119 -0
  220. package/dist/session/react.guard.js +15 -0
  221. package/dist/session/react.js +8 -0
  222. package/dist/session/react.js.map +1 -0
  223. package/dist/session/server.cjs +268 -0
  224. package/dist/session/server.cjs.map +1 -0
  225. package/dist/session/server.d.cts +151 -0
  226. package/dist/session/server.d.ts +151 -0
  227. package/dist/session/server.guard.js +15 -0
  228. package/dist/session/server.js +252 -0
  229. package/dist/session/server.js.map +1 -0
  230. package/dist/session.cjs +74 -0
  231. package/dist/session.cjs.map +1 -0
  232. package/dist/session.d.cts +3 -0
  233. package/dist/session.d.ts +3 -0
  234. package/dist/session.js +5 -0
  235. package/dist/session.js.map +1 -0
  236. package/dist/status-Dx9zAFo9.d.ts +327 -0
  237. package/dist/status-wgTM26V7.d.cts +327 -0
  238. package/dist/store-CjmLgp9g.d.cts +64 -0
  239. package/dist/store-CjmLgp9g.d.ts +64 -0
  240. package/dist/types-BEEM7WdG.d.cts +25 -0
  241. package/dist/types-BEEM7WdG.d.ts +25 -0
  242. package/dist/types-BilBTDqK.d.cts +27 -0
  243. package/dist/types-BilBTDqK.d.ts +27 -0
  244. package/package.json +245 -3
@@ -0,0 +1,2716 @@
1
+ import { PEPU_HOSTED, resolvePepuEndpoints } from './chunk-XC4IBCI2.js';
2
+ import { pepuMainnet } from './chunk-VTQIHMF3.js';
3
+ import { PepuPaymasterError, PepuConfigError } from './chunk-6DSZ4Z2N.js';
4
+ import { decodeErrorResult, isAddress, toHex } from 'viem';
5
+ import { createSiweMessage } from 'viem/siwe';
6
+
7
+ // src/paymaster/abi.ts
8
+ var pepuSponsoredPaymasterV2Abi = [
9
+ {
10
+ "type": "constructor",
11
+ "inputs": [
12
+ {
13
+ "name": "_entryPoint",
14
+ "type": "address",
15
+ "internalType": "address"
16
+ },
17
+ {
18
+ "name": "_owner",
19
+ "type": "address",
20
+ "internalType": "address"
21
+ },
22
+ {
23
+ "name": "_manager",
24
+ "type": "address",
25
+ "internalType": "address"
26
+ },
27
+ {
28
+ "name": "_signers",
29
+ "type": "address[]",
30
+ "internalType": "address[]"
31
+ },
32
+ {
33
+ "name": "_bundlers",
34
+ "type": "address[]",
35
+ "internalType": "address[]"
36
+ },
37
+ {
38
+ "name": "_adminChangeDelay",
39
+ "type": "uint32",
40
+ "internalType": "uint32"
41
+ },
42
+ {
43
+ "name": "_postOpOverheadGas",
44
+ "type": "uint32",
45
+ "internalType": "uint32"
46
+ },
47
+ {
48
+ "name": "_defaultMaxFeePerGas",
49
+ "type": "uint128",
50
+ "internalType": "uint128"
51
+ }
52
+ ],
53
+ "stateMutability": "nonpayable"
54
+ },
55
+ {
56
+ "type": "function",
57
+ "name": "MAX_ADMIN_CHANGE_DELAY",
58
+ "inputs": [],
59
+ "outputs": [
60
+ {
61
+ "name": "",
62
+ "type": "uint32",
63
+ "internalType": "uint32"
64
+ }
65
+ ],
66
+ "stateMutability": "view"
67
+ },
68
+ {
69
+ "type": "function",
70
+ "name": "MIN_ADMIN_CHANGE_DELAY",
71
+ "inputs": [],
72
+ "outputs": [
73
+ {
74
+ "name": "",
75
+ "type": "uint32",
76
+ "internalType": "uint32"
77
+ }
78
+ ],
79
+ "stateMutability": "view"
80
+ },
81
+ {
82
+ "type": "function",
83
+ "name": "MIN_POSTOP_GAS_LIMIT",
84
+ "inputs": [],
85
+ "outputs": [
86
+ {
87
+ "name": "",
88
+ "type": "uint256",
89
+ "internalType": "uint256"
90
+ }
91
+ ],
92
+ "stateMutability": "view"
93
+ },
94
+ {
95
+ "type": "function",
96
+ "name": "MIN_POSTOP_OVERHEAD_GAS",
97
+ "inputs": [],
98
+ "outputs": [
99
+ {
100
+ "name": "",
101
+ "type": "uint32",
102
+ "internalType": "uint32"
103
+ }
104
+ ],
105
+ "stateMutability": "view"
106
+ },
107
+ {
108
+ "type": "function",
109
+ "name": "PENDING_EXPIRY",
110
+ "inputs": [],
111
+ "outputs": [
112
+ {
113
+ "name": "",
114
+ "type": "uint32",
115
+ "internalType": "uint32"
116
+ }
117
+ ],
118
+ "stateMutability": "view"
119
+ },
120
+ {
121
+ "type": "function",
122
+ "name": "SURPLUS_RESERVE",
123
+ "inputs": [],
124
+ "outputs": [
125
+ {
126
+ "name": "",
127
+ "type": "uint256",
128
+ "internalType": "uint256"
129
+ }
130
+ ],
131
+ "stateMutability": "view"
132
+ },
133
+ {
134
+ "type": "function",
135
+ "name": "acceptOwnership",
136
+ "inputs": [],
137
+ "outputs": [],
138
+ "stateMutability": "nonpayable"
139
+ },
140
+ {
141
+ "type": "function",
142
+ "name": "acceptProjectOwnership",
143
+ "inputs": [
144
+ {
145
+ "name": "projectId",
146
+ "type": "bytes32",
147
+ "internalType": "bytes32"
148
+ }
149
+ ],
150
+ "outputs": [],
151
+ "stateMutability": "nonpayable"
152
+ },
153
+ {
154
+ "type": "function",
155
+ "name": "addStake",
156
+ "inputs": [
157
+ {
158
+ "name": "unstakeDelaySec",
159
+ "type": "uint32",
160
+ "internalType": "uint32"
161
+ }
162
+ ],
163
+ "outputs": [],
164
+ "stateMutability": "payable"
165
+ },
166
+ {
167
+ "type": "function",
168
+ "name": "adminChangeDelay",
169
+ "inputs": [],
170
+ "outputs": [
171
+ {
172
+ "name": "",
173
+ "type": "uint48",
174
+ "internalType": "uint48"
175
+ }
176
+ ],
177
+ "stateMutability": "view"
178
+ },
179
+ {
180
+ "type": "function",
181
+ "name": "cancelAdminChange",
182
+ "inputs": [
183
+ {
184
+ "name": "kind",
185
+ "type": "uint8",
186
+ "internalType": "uint8"
187
+ },
188
+ {
189
+ "name": "account",
190
+ "type": "address",
191
+ "internalType": "address"
192
+ }
193
+ ],
194
+ "outputs": [],
195
+ "stateMutability": "nonpayable"
196
+ },
197
+ {
198
+ "type": "function",
199
+ "name": "cancelReclaim",
200
+ "inputs": [
201
+ {
202
+ "name": "projectId",
203
+ "type": "bytes32",
204
+ "internalType": "bytes32"
205
+ }
206
+ ],
207
+ "outputs": [],
208
+ "stateMutability": "nonpayable"
209
+ },
210
+ {
211
+ "type": "function",
212
+ "name": "claimDigest",
213
+ "inputs": [
214
+ {
215
+ "name": "appId",
216
+ "type": "string",
217
+ "internalType": "string"
218
+ },
219
+ {
220
+ "name": "newOwner",
221
+ "type": "address",
222
+ "internalType": "address"
223
+ },
224
+ {
225
+ "name": "nonce",
226
+ "type": "uint256",
227
+ "internalType": "uint256"
228
+ },
229
+ {
230
+ "name": "deadline",
231
+ "type": "uint256",
232
+ "internalType": "uint256"
233
+ }
234
+ ],
235
+ "outputs": [
236
+ {
237
+ "name": "",
238
+ "type": "bytes32",
239
+ "internalType": "bytes32"
240
+ }
241
+ ],
242
+ "stateMutability": "view"
243
+ },
244
+ {
245
+ "type": "function",
246
+ "name": "claimProject",
247
+ "inputs": [
248
+ {
249
+ "name": "c",
250
+ "type": "tuple",
251
+ "internalType": "struct PepuSponsoredPaymasterV7.Claim",
252
+ "components": [
253
+ {
254
+ "name": "appId",
255
+ "type": "string",
256
+ "internalType": "string"
257
+ },
258
+ {
259
+ "name": "newOwner",
260
+ "type": "address",
261
+ "internalType": "address"
262
+ },
263
+ {
264
+ "name": "nonce",
265
+ "type": "uint256",
266
+ "internalType": "uint256"
267
+ },
268
+ {
269
+ "name": "deadline",
270
+ "type": "uint256",
271
+ "internalType": "uint256"
272
+ },
273
+ {
274
+ "name": "signature",
275
+ "type": "bytes",
276
+ "internalType": "bytes"
277
+ }
278
+ ]
279
+ }
280
+ ],
281
+ "outputs": [
282
+ {
283
+ "name": "projectId",
284
+ "type": "bytes32",
285
+ "internalType": "bytes32"
286
+ }
287
+ ],
288
+ "stateMutability": "nonpayable"
289
+ },
290
+ {
291
+ "type": "function",
292
+ "name": "claimUsed",
293
+ "inputs": [
294
+ {
295
+ "name": "digest",
296
+ "type": "bytes32",
297
+ "internalType": "bytes32"
298
+ }
299
+ ],
300
+ "outputs": [
301
+ {
302
+ "name": "used",
303
+ "type": "bool",
304
+ "internalType": "bool"
305
+ }
306
+ ],
307
+ "stateMutability": "view"
308
+ },
309
+ {
310
+ "type": "function",
311
+ "name": "creditSurplusToFreePool",
312
+ "inputs": [],
313
+ "outputs": [
314
+ {
315
+ "name": "credited",
316
+ "type": "uint256",
317
+ "internalType": "uint256"
318
+ }
319
+ ],
320
+ "stateMutability": "nonpayable"
321
+ },
322
+ {
323
+ "type": "function",
324
+ "name": "defaultMaxFeePerGas",
325
+ "inputs": [],
326
+ "outputs": [
327
+ {
328
+ "name": "",
329
+ "type": "uint128",
330
+ "internalType": "uint128"
331
+ }
332
+ ],
333
+ "stateMutability": "view"
334
+ },
335
+ {
336
+ "type": "function",
337
+ "name": "depositFor",
338
+ "inputs": [
339
+ {
340
+ "name": "projectId",
341
+ "type": "bytes32",
342
+ "internalType": "bytes32"
343
+ }
344
+ ],
345
+ "outputs": [],
346
+ "stateMutability": "payable"
347
+ },
348
+ {
349
+ "type": "function",
350
+ "name": "domainSeparator",
351
+ "inputs": [],
352
+ "outputs": [
353
+ {
354
+ "name": "",
355
+ "type": "bytes32",
356
+ "internalType": "bytes32"
357
+ }
358
+ ],
359
+ "stateMutability": "view"
360
+ },
361
+ {
362
+ "type": "function",
363
+ "name": "effectiveMaxFeePerGas",
364
+ "inputs": [
365
+ {
366
+ "name": "sponsorId",
367
+ "type": "bytes32",
368
+ "internalType": "bytes32"
369
+ }
370
+ ],
371
+ "outputs": [
372
+ {
373
+ "name": "",
374
+ "type": "uint256",
375
+ "internalType": "uint256"
376
+ }
377
+ ],
378
+ "stateMutability": "view"
379
+ },
380
+ {
381
+ "type": "function",
382
+ "name": "entryPoint",
383
+ "inputs": [],
384
+ "outputs": [
385
+ {
386
+ "name": "",
387
+ "type": "address",
388
+ "internalType": "contract IEntryPoint"
389
+ }
390
+ ],
391
+ "stateMutability": "view"
392
+ },
393
+ {
394
+ "type": "function",
395
+ "name": "executeAdminChange",
396
+ "inputs": [
397
+ {
398
+ "name": "kind",
399
+ "type": "uint8",
400
+ "internalType": "uint8"
401
+ },
402
+ {
403
+ "name": "account",
404
+ "type": "address",
405
+ "internalType": "address"
406
+ }
407
+ ],
408
+ "outputs": [],
409
+ "stateMutability": "nonpayable"
410
+ },
411
+ {
412
+ "type": "function",
413
+ "name": "executeReclaim",
414
+ "inputs": [
415
+ {
416
+ "name": "projectId",
417
+ "type": "bytes32",
418
+ "internalType": "bytes32"
419
+ }
420
+ ],
421
+ "outputs": [],
422
+ "stateMutability": "nonpayable"
423
+ },
424
+ {
425
+ "type": "function",
426
+ "name": "freeEnabled",
427
+ "inputs": [],
428
+ "outputs": [
429
+ {
430
+ "name": "",
431
+ "type": "bool",
432
+ "internalType": "bool"
433
+ }
434
+ ],
435
+ "stateMutability": "view"
436
+ },
437
+ {
438
+ "type": "function",
439
+ "name": "freeMaxOpCost",
440
+ "inputs": [],
441
+ "outputs": [
442
+ {
443
+ "name": "",
444
+ "type": "uint128",
445
+ "internalType": "uint128"
446
+ }
447
+ ],
448
+ "stateMutability": "view"
449
+ },
450
+ {
451
+ "type": "function",
452
+ "name": "fundFreePool",
453
+ "inputs": [],
454
+ "outputs": [],
455
+ "stateMutability": "payable"
456
+ },
457
+ {
458
+ "type": "function",
459
+ "name": "getHash",
460
+ "inputs": [
461
+ {
462
+ "name": "_mode",
463
+ "type": "uint8",
464
+ "internalType": "uint8"
465
+ },
466
+ {
467
+ "name": "_userOp",
468
+ "type": "tuple",
469
+ "internalType": "struct PackedUserOperation",
470
+ "components": [
471
+ {
472
+ "name": "sender",
473
+ "type": "address",
474
+ "internalType": "address"
475
+ },
476
+ {
477
+ "name": "nonce",
478
+ "type": "uint256",
479
+ "internalType": "uint256"
480
+ },
481
+ {
482
+ "name": "initCode",
483
+ "type": "bytes",
484
+ "internalType": "bytes"
485
+ },
486
+ {
487
+ "name": "callData",
488
+ "type": "bytes",
489
+ "internalType": "bytes"
490
+ },
491
+ {
492
+ "name": "accountGasLimits",
493
+ "type": "bytes32",
494
+ "internalType": "bytes32"
495
+ },
496
+ {
497
+ "name": "preVerificationGas",
498
+ "type": "uint256",
499
+ "internalType": "uint256"
500
+ },
501
+ {
502
+ "name": "gasFees",
503
+ "type": "bytes32",
504
+ "internalType": "bytes32"
505
+ },
506
+ {
507
+ "name": "paymasterAndData",
508
+ "type": "bytes",
509
+ "internalType": "bytes"
510
+ },
511
+ {
512
+ "name": "signature",
513
+ "type": "bytes",
514
+ "internalType": "bytes"
515
+ }
516
+ ]
517
+ }
518
+ ],
519
+ "outputs": [
520
+ {
521
+ "name": "",
522
+ "type": "bytes32",
523
+ "internalType": "bytes32"
524
+ }
525
+ ],
526
+ "stateMutability": "view"
527
+ },
528
+ {
529
+ "type": "function",
530
+ "name": "getProject",
531
+ "inputs": [
532
+ {
533
+ "name": "sponsorId",
534
+ "type": "bytes32",
535
+ "internalType": "bytes32"
536
+ }
537
+ ],
538
+ "outputs": [
539
+ {
540
+ "name": "projectOwner",
541
+ "type": "address",
542
+ "internalType": "address"
543
+ },
544
+ {
545
+ "name": "paused",
546
+ "type": "bool",
547
+ "internalType": "bool"
548
+ },
549
+ {
550
+ "name": "senderDailyLimit",
551
+ "type": "uint112",
552
+ "internalType": "uint112"
553
+ },
554
+ {
555
+ "name": "balance",
556
+ "type": "uint128",
557
+ "internalType": "uint128"
558
+ },
559
+ {
560
+ "name": "dailyLimit",
561
+ "type": "uint112",
562
+ "internalType": "uint112"
563
+ },
564
+ {
565
+ "name": "spentToday",
566
+ "type": "uint112",
567
+ "internalType": "uint112"
568
+ },
569
+ {
570
+ "name": "spentDay",
571
+ "type": "uint32",
572
+ "internalType": "uint32"
573
+ }
574
+ ],
575
+ "stateMutability": "view"
576
+ },
577
+ {
578
+ "type": "function",
579
+ "name": "getSenderSpend",
580
+ "inputs": [
581
+ {
582
+ "name": "sponsorId",
583
+ "type": "bytes32",
584
+ "internalType": "bytes32"
585
+ },
586
+ {
587
+ "name": "sender",
588
+ "type": "address",
589
+ "internalType": "address"
590
+ }
591
+ ],
592
+ "outputs": [
593
+ {
594
+ "name": "day",
595
+ "type": "uint32",
596
+ "internalType": "uint32"
597
+ },
598
+ {
599
+ "name": "spent",
600
+ "type": "uint112",
601
+ "internalType": "uint112"
602
+ }
603
+ ],
604
+ "stateMutability": "view"
605
+ },
606
+ {
607
+ "type": "function",
608
+ "name": "isBundlerAllowed",
609
+ "inputs": [
610
+ {
611
+ "name": "bundler",
612
+ "type": "address",
613
+ "internalType": "address"
614
+ }
615
+ ],
616
+ "outputs": [
617
+ {
618
+ "name": "allowed",
619
+ "type": "bool",
620
+ "internalType": "bool"
621
+ }
622
+ ],
623
+ "stateMutability": "view"
624
+ },
625
+ {
626
+ "type": "function",
627
+ "name": "isTargetAllowed",
628
+ "inputs": [
629
+ {
630
+ "name": "sponsorId",
631
+ "type": "bytes32",
632
+ "internalType": "bytes32"
633
+ },
634
+ {
635
+ "name": "target",
636
+ "type": "address",
637
+ "internalType": "address"
638
+ }
639
+ ],
640
+ "outputs": [
641
+ {
642
+ "name": "",
643
+ "type": "bool",
644
+ "internalType": "bool"
645
+ }
646
+ ],
647
+ "stateMutability": "view"
648
+ },
649
+ {
650
+ "type": "function",
651
+ "name": "manager",
652
+ "inputs": [],
653
+ "outputs": [
654
+ {
655
+ "name": "",
656
+ "type": "address",
657
+ "internalType": "address"
658
+ }
659
+ ],
660
+ "stateMutability": "view"
661
+ },
662
+ {
663
+ "type": "function",
664
+ "name": "maxPostOpOverheadGas",
665
+ "inputs": [],
666
+ "outputs": [
667
+ {
668
+ "name": "",
669
+ "type": "uint32",
670
+ "internalType": "uint32"
671
+ }
672
+ ],
673
+ "stateMutability": "view"
674
+ },
675
+ {
676
+ "type": "function",
677
+ "name": "owner",
678
+ "inputs": [],
679
+ "outputs": [
680
+ {
681
+ "name": "",
682
+ "type": "address",
683
+ "internalType": "address"
684
+ }
685
+ ],
686
+ "stateMutability": "view"
687
+ },
688
+ {
689
+ "type": "function",
690
+ "name": "pauseFreePool",
691
+ "inputs": [],
692
+ "outputs": [],
693
+ "stateMutability": "nonpayable"
694
+ },
695
+ {
696
+ "type": "function",
697
+ "name": "pendingAdminChange",
698
+ "inputs": [
699
+ {
700
+ "name": "key",
701
+ "type": "bytes32",
702
+ "internalType": "bytes32"
703
+ }
704
+ ],
705
+ "outputs": [
706
+ {
707
+ "name": "executableAt",
708
+ "type": "uint48",
709
+ "internalType": "uint48"
710
+ }
711
+ ],
712
+ "stateMutability": "view"
713
+ },
714
+ {
715
+ "type": "function",
716
+ "name": "pendingOwner",
717
+ "inputs": [],
718
+ "outputs": [
719
+ {
720
+ "name": "",
721
+ "type": "address",
722
+ "internalType": "address"
723
+ }
724
+ ],
725
+ "stateMutability": "view"
726
+ },
727
+ {
728
+ "type": "function",
729
+ "name": "pendingProjectOwner",
730
+ "inputs": [
731
+ {
732
+ "name": "projectId",
733
+ "type": "bytes32",
734
+ "internalType": "bytes32"
735
+ }
736
+ ],
737
+ "outputs": [
738
+ {
739
+ "name": "",
740
+ "type": "address",
741
+ "internalType": "address"
742
+ }
743
+ ],
744
+ "stateMutability": "view"
745
+ },
746
+ {
747
+ "type": "function",
748
+ "name": "pendingReclaim",
749
+ "inputs": [
750
+ {
751
+ "name": "projectId",
752
+ "type": "bytes32",
753
+ "internalType": "bytes32"
754
+ }
755
+ ],
756
+ "outputs": [
757
+ {
758
+ "name": "newOwner",
759
+ "type": "address",
760
+ "internalType": "address"
761
+ },
762
+ {
763
+ "name": "executableAt",
764
+ "type": "uint48",
765
+ "internalType": "uint48"
766
+ },
767
+ {
768
+ "name": "signer",
769
+ "type": "address",
770
+ "internalType": "address"
771
+ }
772
+ ],
773
+ "stateMutability": "view"
774
+ },
775
+ {
776
+ "type": "function",
777
+ "name": "postOp",
778
+ "inputs": [
779
+ {
780
+ "name": "",
781
+ "type": "uint8",
782
+ "internalType": "enum PostOpMode"
783
+ },
784
+ {
785
+ "name": "context",
786
+ "type": "bytes",
787
+ "internalType": "bytes"
788
+ },
789
+ {
790
+ "name": "actualGasCost",
791
+ "type": "uint256",
792
+ "internalType": "uint256"
793
+ },
794
+ {
795
+ "name": "actualUserOpFeePerGas",
796
+ "type": "uint256",
797
+ "internalType": "uint256"
798
+ }
799
+ ],
800
+ "outputs": [],
801
+ "stateMutability": "nonpayable"
802
+ },
803
+ {
804
+ "type": "function",
805
+ "name": "postOpOverheadGas",
806
+ "inputs": [],
807
+ "outputs": [
808
+ {
809
+ "name": "",
810
+ "type": "uint32",
811
+ "internalType": "uint32"
812
+ }
813
+ ],
814
+ "stateMutability": "view"
815
+ },
816
+ {
817
+ "type": "function",
818
+ "name": "projectIdOf",
819
+ "inputs": [
820
+ {
821
+ "name": "appId",
822
+ "type": "string",
823
+ "internalType": "string"
824
+ }
825
+ ],
826
+ "outputs": [
827
+ {
828
+ "name": "",
829
+ "type": "bytes32",
830
+ "internalType": "bytes32"
831
+ }
832
+ ],
833
+ "stateMutability": "pure"
834
+ },
835
+ {
836
+ "type": "function",
837
+ "name": "proposeAdminChange",
838
+ "inputs": [
839
+ {
840
+ "name": "kind",
841
+ "type": "uint8",
842
+ "internalType": "uint8"
843
+ },
844
+ {
845
+ "name": "account",
846
+ "type": "address",
847
+ "internalType": "address"
848
+ }
849
+ ],
850
+ "outputs": [],
851
+ "stateMutability": "nonpayable"
852
+ },
853
+ {
854
+ "type": "function",
855
+ "name": "proposeProjectOwner",
856
+ "inputs": [
857
+ {
858
+ "name": "projectId",
859
+ "type": "bytes32",
860
+ "internalType": "bytes32"
861
+ },
862
+ {
863
+ "name": "newOwner",
864
+ "type": "address",
865
+ "internalType": "address"
866
+ }
867
+ ],
868
+ "outputs": [],
869
+ "stateMutability": "nonpayable"
870
+ },
871
+ {
872
+ "type": "function",
873
+ "name": "reclaimProject",
874
+ "inputs": [
875
+ {
876
+ "name": "c",
877
+ "type": "tuple",
878
+ "internalType": "struct PepuSponsoredPaymasterV7.Claim",
879
+ "components": [
880
+ {
881
+ "name": "appId",
882
+ "type": "string",
883
+ "internalType": "string"
884
+ },
885
+ {
886
+ "name": "newOwner",
887
+ "type": "address",
888
+ "internalType": "address"
889
+ },
890
+ {
891
+ "name": "nonce",
892
+ "type": "uint256",
893
+ "internalType": "uint256"
894
+ },
895
+ {
896
+ "name": "deadline",
897
+ "type": "uint256",
898
+ "internalType": "uint256"
899
+ },
900
+ {
901
+ "name": "signature",
902
+ "type": "bytes",
903
+ "internalType": "bytes"
904
+ }
905
+ ]
906
+ }
907
+ ],
908
+ "outputs": [],
909
+ "stateMutability": "nonpayable"
910
+ },
911
+ {
912
+ "type": "function",
913
+ "name": "removeBundlers",
914
+ "inputs": [
915
+ {
916
+ "name": "bundlers",
917
+ "type": "address[]",
918
+ "internalType": "address[]"
919
+ }
920
+ ],
921
+ "outputs": [],
922
+ "stateMutability": "nonpayable"
923
+ },
924
+ {
925
+ "type": "function",
926
+ "name": "removeSigner",
927
+ "inputs": [
928
+ {
929
+ "name": "_signer",
930
+ "type": "address",
931
+ "internalType": "address"
932
+ }
933
+ ],
934
+ "outputs": [],
935
+ "stateMutability": "nonpayable"
936
+ },
937
+ {
938
+ "type": "function",
939
+ "name": "renounceOwnership",
940
+ "inputs": [],
941
+ "outputs": [],
942
+ "stateMutability": "nonpayable"
943
+ },
944
+ {
945
+ "type": "function",
946
+ "name": "requiredAccountCodehash",
947
+ "inputs": [
948
+ {
949
+ "name": "sponsorId",
950
+ "type": "bytes32",
951
+ "internalType": "bytes32"
952
+ }
953
+ ],
954
+ "outputs": [
955
+ {
956
+ "name": "codehash",
957
+ "type": "bytes32",
958
+ "internalType": "bytes32"
959
+ }
960
+ ],
961
+ "stateMutability": "view"
962
+ },
963
+ {
964
+ "type": "function",
965
+ "name": "setDailyLimit",
966
+ "inputs": [
967
+ {
968
+ "name": "projectId",
969
+ "type": "bytes32",
970
+ "internalType": "bytes32"
971
+ },
972
+ {
973
+ "name": "limit",
974
+ "type": "uint112",
975
+ "internalType": "uint112"
976
+ }
977
+ ],
978
+ "outputs": [],
979
+ "stateMutability": "nonpayable"
980
+ },
981
+ {
982
+ "type": "function",
983
+ "name": "setFreeMaxFeePerGas",
984
+ "inputs": [
985
+ {
986
+ "name": "cap",
987
+ "type": "uint128",
988
+ "internalType": "uint128"
989
+ }
990
+ ],
991
+ "outputs": [],
992
+ "stateMutability": "nonpayable"
993
+ },
994
+ {
995
+ "type": "function",
996
+ "name": "setFreeTargets",
997
+ "inputs": [
998
+ {
999
+ "name": "targets",
1000
+ "type": "address[]",
1001
+ "internalType": "address[]"
1002
+ },
1003
+ {
1004
+ "name": "allowed",
1005
+ "type": "bool",
1006
+ "internalType": "bool"
1007
+ }
1008
+ ],
1009
+ "outputs": [],
1010
+ "stateMutability": "nonpayable"
1011
+ },
1012
+ {
1013
+ "type": "function",
1014
+ "name": "setFreeTier",
1015
+ "inputs": [
1016
+ {
1017
+ "name": "maxOpCost",
1018
+ "type": "uint128",
1019
+ "internalType": "uint128"
1020
+ },
1021
+ {
1022
+ "name": "senderDailyLimit",
1023
+ "type": "uint112",
1024
+ "internalType": "uint112"
1025
+ },
1026
+ {
1027
+ "name": "enabled",
1028
+ "type": "bool",
1029
+ "internalType": "bool"
1030
+ }
1031
+ ],
1032
+ "outputs": [],
1033
+ "stateMutability": "nonpayable"
1034
+ },
1035
+ {
1036
+ "type": "function",
1037
+ "name": "setManager",
1038
+ "inputs": [
1039
+ {
1040
+ "name": "newManager",
1041
+ "type": "address",
1042
+ "internalType": "address"
1043
+ }
1044
+ ],
1045
+ "outputs": [],
1046
+ "stateMutability": "nonpayable"
1047
+ },
1048
+ {
1049
+ "type": "function",
1050
+ "name": "setMaxFeePerGas",
1051
+ "inputs": [
1052
+ {
1053
+ "name": "projectId",
1054
+ "type": "bytes32",
1055
+ "internalType": "bytes32"
1056
+ },
1057
+ {
1058
+ "name": "cap",
1059
+ "type": "uint128",
1060
+ "internalType": "uint128"
1061
+ }
1062
+ ],
1063
+ "outputs": [],
1064
+ "stateMutability": "nonpayable"
1065
+ },
1066
+ {
1067
+ "type": "function",
1068
+ "name": "setPaused",
1069
+ "inputs": [
1070
+ {
1071
+ "name": "projectId",
1072
+ "type": "bytes32",
1073
+ "internalType": "bytes32"
1074
+ },
1075
+ {
1076
+ "name": "paused",
1077
+ "type": "bool",
1078
+ "internalType": "bool"
1079
+ }
1080
+ ],
1081
+ "outputs": [],
1082
+ "stateMutability": "nonpayable"
1083
+ },
1084
+ {
1085
+ "type": "function",
1086
+ "name": "setPostOpOverheadGas",
1087
+ "inputs": [
1088
+ {
1089
+ "name": "gas",
1090
+ "type": "uint32",
1091
+ "internalType": "uint32"
1092
+ }
1093
+ ],
1094
+ "outputs": [],
1095
+ "stateMutability": "nonpayable"
1096
+ },
1097
+ {
1098
+ "type": "function",
1099
+ "name": "setRequiredAccountCodehash",
1100
+ "inputs": [
1101
+ {
1102
+ "name": "projectId",
1103
+ "type": "bytes32",
1104
+ "internalType": "bytes32"
1105
+ },
1106
+ {
1107
+ "name": "codehash",
1108
+ "type": "bytes32",
1109
+ "internalType": "bytes32"
1110
+ }
1111
+ ],
1112
+ "outputs": [],
1113
+ "stateMutability": "nonpayable"
1114
+ },
1115
+ {
1116
+ "type": "function",
1117
+ "name": "setSenderDailyLimit",
1118
+ "inputs": [
1119
+ {
1120
+ "name": "projectId",
1121
+ "type": "bytes32",
1122
+ "internalType": "bytes32"
1123
+ },
1124
+ {
1125
+ "name": "limit",
1126
+ "type": "uint112",
1127
+ "internalType": "uint112"
1128
+ }
1129
+ ],
1130
+ "outputs": [],
1131
+ "stateMutability": "nonpayable"
1132
+ },
1133
+ {
1134
+ "type": "function",
1135
+ "name": "setTargets",
1136
+ "inputs": [
1137
+ {
1138
+ "name": "projectId",
1139
+ "type": "bytes32",
1140
+ "internalType": "bytes32"
1141
+ },
1142
+ {
1143
+ "name": "targets",
1144
+ "type": "address[]",
1145
+ "internalType": "address[]"
1146
+ },
1147
+ {
1148
+ "name": "allowed",
1149
+ "type": "bool",
1150
+ "internalType": "bool"
1151
+ }
1152
+ ],
1153
+ "outputs": [],
1154
+ "stateMutability": "nonpayable"
1155
+ },
1156
+ {
1157
+ "type": "function",
1158
+ "name": "signerRemovedAt",
1159
+ "inputs": [
1160
+ {
1161
+ "name": "signer",
1162
+ "type": "address",
1163
+ "internalType": "address"
1164
+ }
1165
+ ],
1166
+ "outputs": [
1167
+ {
1168
+ "name": "removedAt",
1169
+ "type": "uint48",
1170
+ "internalType": "uint48"
1171
+ }
1172
+ ],
1173
+ "stateMutability": "view"
1174
+ },
1175
+ {
1176
+ "type": "function",
1177
+ "name": "signers",
1178
+ "inputs": [
1179
+ {
1180
+ "name": "account",
1181
+ "type": "address",
1182
+ "internalType": "address"
1183
+ }
1184
+ ],
1185
+ "outputs": [
1186
+ {
1187
+ "name": "isValidSigner",
1188
+ "type": "bool",
1189
+ "internalType": "bool"
1190
+ }
1191
+ ],
1192
+ "stateMutability": "view"
1193
+ },
1194
+ {
1195
+ "type": "function",
1196
+ "name": "surplus",
1197
+ "inputs": [],
1198
+ "outputs": [
1199
+ {
1200
+ "name": "",
1201
+ "type": "uint256",
1202
+ "internalType": "uint256"
1203
+ }
1204
+ ],
1205
+ "stateMutability": "view"
1206
+ },
1207
+ {
1208
+ "type": "function",
1209
+ "name": "totalLiabilities",
1210
+ "inputs": [],
1211
+ "outputs": [
1212
+ {
1213
+ "name": "",
1214
+ "type": "uint256",
1215
+ "internalType": "uint256"
1216
+ }
1217
+ ],
1218
+ "stateMutability": "view"
1219
+ },
1220
+ {
1221
+ "type": "function",
1222
+ "name": "transferOwnership",
1223
+ "inputs": [
1224
+ {
1225
+ "name": "newOwner",
1226
+ "type": "address",
1227
+ "internalType": "address"
1228
+ }
1229
+ ],
1230
+ "outputs": [],
1231
+ "stateMutability": "nonpayable"
1232
+ },
1233
+ {
1234
+ "type": "function",
1235
+ "name": "unlockStake",
1236
+ "inputs": [],
1237
+ "outputs": [],
1238
+ "stateMutability": "nonpayable"
1239
+ },
1240
+ {
1241
+ "type": "function",
1242
+ "name": "validatePaymasterUserOp",
1243
+ "inputs": [
1244
+ {
1245
+ "name": "userOp",
1246
+ "type": "tuple",
1247
+ "internalType": "struct PackedUserOperation",
1248
+ "components": [
1249
+ {
1250
+ "name": "sender",
1251
+ "type": "address",
1252
+ "internalType": "address"
1253
+ },
1254
+ {
1255
+ "name": "nonce",
1256
+ "type": "uint256",
1257
+ "internalType": "uint256"
1258
+ },
1259
+ {
1260
+ "name": "initCode",
1261
+ "type": "bytes",
1262
+ "internalType": "bytes"
1263
+ },
1264
+ {
1265
+ "name": "callData",
1266
+ "type": "bytes",
1267
+ "internalType": "bytes"
1268
+ },
1269
+ {
1270
+ "name": "accountGasLimits",
1271
+ "type": "bytes32",
1272
+ "internalType": "bytes32"
1273
+ },
1274
+ {
1275
+ "name": "preVerificationGas",
1276
+ "type": "uint256",
1277
+ "internalType": "uint256"
1278
+ },
1279
+ {
1280
+ "name": "gasFees",
1281
+ "type": "bytes32",
1282
+ "internalType": "bytes32"
1283
+ },
1284
+ {
1285
+ "name": "paymasterAndData",
1286
+ "type": "bytes",
1287
+ "internalType": "bytes"
1288
+ },
1289
+ {
1290
+ "name": "signature",
1291
+ "type": "bytes",
1292
+ "internalType": "bytes"
1293
+ }
1294
+ ]
1295
+ },
1296
+ {
1297
+ "name": "userOpHash",
1298
+ "type": "bytes32",
1299
+ "internalType": "bytes32"
1300
+ },
1301
+ {
1302
+ "name": "maxCost",
1303
+ "type": "uint256",
1304
+ "internalType": "uint256"
1305
+ }
1306
+ ],
1307
+ "outputs": [
1308
+ {
1309
+ "name": "context",
1310
+ "type": "bytes",
1311
+ "internalType": "bytes"
1312
+ },
1313
+ {
1314
+ "name": "validationData",
1315
+ "type": "uint256",
1316
+ "internalType": "uint256"
1317
+ }
1318
+ ],
1319
+ "stateMutability": "nonpayable"
1320
+ },
1321
+ {
1322
+ "type": "function",
1323
+ "name": "vetoedReclaimant",
1324
+ "inputs": [
1325
+ {
1326
+ "name": "projectId",
1327
+ "type": "bytes32",
1328
+ "internalType": "bytes32"
1329
+ }
1330
+ ],
1331
+ "outputs": [
1332
+ {
1333
+ "name": "newOwner",
1334
+ "type": "address",
1335
+ "internalType": "address"
1336
+ }
1337
+ ],
1338
+ "stateMutability": "view"
1339
+ },
1340
+ {
1341
+ "type": "function",
1342
+ "name": "withdrawStake",
1343
+ "inputs": [
1344
+ {
1345
+ "name": "to",
1346
+ "type": "address",
1347
+ "internalType": "address payable"
1348
+ }
1349
+ ],
1350
+ "outputs": [],
1351
+ "stateMutability": "nonpayable"
1352
+ },
1353
+ {
1354
+ "type": "event",
1355
+ "name": "AdminChangeCancelled",
1356
+ "inputs": [
1357
+ {
1358
+ "name": "key",
1359
+ "type": "bytes32",
1360
+ "indexed": true,
1361
+ "internalType": "bytes32"
1362
+ },
1363
+ {
1364
+ "name": "kind",
1365
+ "type": "uint8",
1366
+ "indexed": false,
1367
+ "internalType": "uint8"
1368
+ },
1369
+ {
1370
+ "name": "account",
1371
+ "type": "address",
1372
+ "indexed": true,
1373
+ "internalType": "address"
1374
+ }
1375
+ ],
1376
+ "anonymous": false
1377
+ },
1378
+ {
1379
+ "type": "event",
1380
+ "name": "AdminChangeProposed",
1381
+ "inputs": [
1382
+ {
1383
+ "name": "key",
1384
+ "type": "bytes32",
1385
+ "indexed": true,
1386
+ "internalType": "bytes32"
1387
+ },
1388
+ {
1389
+ "name": "kind",
1390
+ "type": "uint8",
1391
+ "indexed": false,
1392
+ "internalType": "uint8"
1393
+ },
1394
+ {
1395
+ "name": "account",
1396
+ "type": "address",
1397
+ "indexed": true,
1398
+ "internalType": "address"
1399
+ },
1400
+ {
1401
+ "name": "executableAt",
1402
+ "type": "uint48",
1403
+ "indexed": false,
1404
+ "internalType": "uint48"
1405
+ }
1406
+ ],
1407
+ "anonymous": false
1408
+ },
1409
+ {
1410
+ "type": "event",
1411
+ "name": "BundlerAllowlistUpdated",
1412
+ "inputs": [
1413
+ {
1414
+ "name": "bundler",
1415
+ "type": "address",
1416
+ "indexed": false,
1417
+ "internalType": "address"
1418
+ },
1419
+ {
1420
+ "name": "allowed",
1421
+ "type": "bool",
1422
+ "indexed": false,
1423
+ "internalType": "bool"
1424
+ }
1425
+ ],
1426
+ "anonymous": false
1427
+ },
1428
+ {
1429
+ "type": "event",
1430
+ "name": "DailyLimitSet",
1431
+ "inputs": [
1432
+ {
1433
+ "name": "sponsorId",
1434
+ "type": "bytes32",
1435
+ "indexed": true,
1436
+ "internalType": "bytes32"
1437
+ },
1438
+ {
1439
+ "name": "limit",
1440
+ "type": "uint256",
1441
+ "indexed": false,
1442
+ "internalType": "uint256"
1443
+ }
1444
+ ],
1445
+ "anonymous": false
1446
+ },
1447
+ {
1448
+ "type": "event",
1449
+ "name": "Deposited",
1450
+ "inputs": [
1451
+ {
1452
+ "name": "sponsorId",
1453
+ "type": "bytes32",
1454
+ "indexed": true,
1455
+ "internalType": "bytes32"
1456
+ },
1457
+ {
1458
+ "name": "from",
1459
+ "type": "address",
1460
+ "indexed": true,
1461
+ "internalType": "address"
1462
+ },
1463
+ {
1464
+ "name": "amount",
1465
+ "type": "uint256",
1466
+ "indexed": false,
1467
+ "internalType": "uint256"
1468
+ },
1469
+ {
1470
+ "name": "newBalance",
1471
+ "type": "uint256",
1472
+ "indexed": false,
1473
+ "internalType": "uint256"
1474
+ }
1475
+ ],
1476
+ "anonymous": false
1477
+ },
1478
+ {
1479
+ "type": "event",
1480
+ "name": "FreeTierConfigured",
1481
+ "inputs": [
1482
+ {
1483
+ "name": "maxOpCost",
1484
+ "type": "uint256",
1485
+ "indexed": false,
1486
+ "internalType": "uint256"
1487
+ },
1488
+ {
1489
+ "name": "senderDailyLimit",
1490
+ "type": "uint256",
1491
+ "indexed": false,
1492
+ "internalType": "uint256"
1493
+ },
1494
+ {
1495
+ "name": "enabled",
1496
+ "type": "bool",
1497
+ "indexed": false,
1498
+ "internalType": "bool"
1499
+ }
1500
+ ],
1501
+ "anonymous": false
1502
+ },
1503
+ {
1504
+ "type": "event",
1505
+ "name": "ManagerSet",
1506
+ "inputs": [
1507
+ {
1508
+ "name": "manager",
1509
+ "type": "address",
1510
+ "indexed": true,
1511
+ "internalType": "address"
1512
+ }
1513
+ ],
1514
+ "anonymous": false
1515
+ },
1516
+ {
1517
+ "type": "event",
1518
+ "name": "MaxFeePerGasSet",
1519
+ "inputs": [
1520
+ {
1521
+ "name": "sponsorId",
1522
+ "type": "bytes32",
1523
+ "indexed": true,
1524
+ "internalType": "bytes32"
1525
+ },
1526
+ {
1527
+ "name": "cap",
1528
+ "type": "uint256",
1529
+ "indexed": false,
1530
+ "internalType": "uint256"
1531
+ }
1532
+ ],
1533
+ "anonymous": false
1534
+ },
1535
+ {
1536
+ "type": "event",
1537
+ "name": "OwnershipTransferStarted",
1538
+ "inputs": [
1539
+ {
1540
+ "name": "previousOwner",
1541
+ "type": "address",
1542
+ "indexed": true,
1543
+ "internalType": "address"
1544
+ },
1545
+ {
1546
+ "name": "newOwner",
1547
+ "type": "address",
1548
+ "indexed": true,
1549
+ "internalType": "address"
1550
+ }
1551
+ ],
1552
+ "anonymous": false
1553
+ },
1554
+ {
1555
+ "type": "event",
1556
+ "name": "OwnershipTransferred",
1557
+ "inputs": [
1558
+ {
1559
+ "name": "previousOwner",
1560
+ "type": "address",
1561
+ "indexed": true,
1562
+ "internalType": "address"
1563
+ },
1564
+ {
1565
+ "name": "newOwner",
1566
+ "type": "address",
1567
+ "indexed": true,
1568
+ "internalType": "address"
1569
+ }
1570
+ ],
1571
+ "anonymous": false
1572
+ },
1573
+ {
1574
+ "type": "event",
1575
+ "name": "PausedSet",
1576
+ "inputs": [
1577
+ {
1578
+ "name": "projectId",
1579
+ "type": "bytes32",
1580
+ "indexed": true,
1581
+ "internalType": "bytes32"
1582
+ },
1583
+ {
1584
+ "name": "paused",
1585
+ "type": "bool",
1586
+ "indexed": false,
1587
+ "internalType": "bool"
1588
+ }
1589
+ ],
1590
+ "anonymous": false
1591
+ },
1592
+ {
1593
+ "type": "event",
1594
+ "name": "PostOpOverheadGasSet",
1595
+ "inputs": [
1596
+ {
1597
+ "name": "gas",
1598
+ "type": "uint32",
1599
+ "indexed": false,
1600
+ "internalType": "uint32"
1601
+ }
1602
+ ],
1603
+ "anonymous": false
1604
+ },
1605
+ {
1606
+ "type": "event",
1607
+ "name": "ProjectClaimProposed",
1608
+ "inputs": [
1609
+ {
1610
+ "name": "projectId",
1611
+ "type": "bytes32",
1612
+ "indexed": true,
1613
+ "internalType": "bytes32"
1614
+ },
1615
+ {
1616
+ "name": "newOwner",
1617
+ "type": "address",
1618
+ "indexed": true,
1619
+ "internalType": "address"
1620
+ },
1621
+ {
1622
+ "name": "executableAt",
1623
+ "type": "uint48",
1624
+ "indexed": false,
1625
+ "internalType": "uint48"
1626
+ },
1627
+ {
1628
+ "name": "appId",
1629
+ "type": "string",
1630
+ "indexed": false,
1631
+ "internalType": "string"
1632
+ }
1633
+ ],
1634
+ "anonymous": false
1635
+ },
1636
+ {
1637
+ "type": "event",
1638
+ "name": "ProjectClaimed",
1639
+ "inputs": [
1640
+ {
1641
+ "name": "projectId",
1642
+ "type": "bytes32",
1643
+ "indexed": true,
1644
+ "internalType": "bytes32"
1645
+ },
1646
+ {
1647
+ "name": "owner",
1648
+ "type": "address",
1649
+ "indexed": true,
1650
+ "internalType": "address"
1651
+ },
1652
+ {
1653
+ "name": "appId",
1654
+ "type": "string",
1655
+ "indexed": false,
1656
+ "internalType": "string"
1657
+ }
1658
+ ],
1659
+ "anonymous": false
1660
+ },
1661
+ {
1662
+ "type": "event",
1663
+ "name": "ProjectOwnershipTransferStarted",
1664
+ "inputs": [
1665
+ {
1666
+ "name": "projectId",
1667
+ "type": "bytes32",
1668
+ "indexed": true,
1669
+ "internalType": "bytes32"
1670
+ },
1671
+ {
1672
+ "name": "newOwner",
1673
+ "type": "address",
1674
+ "indexed": true,
1675
+ "internalType": "address"
1676
+ }
1677
+ ],
1678
+ "anonymous": false
1679
+ },
1680
+ {
1681
+ "type": "event",
1682
+ "name": "ProjectOwnershipTransferred",
1683
+ "inputs": [
1684
+ {
1685
+ "name": "projectId",
1686
+ "type": "bytes32",
1687
+ "indexed": true,
1688
+ "internalType": "bytes32"
1689
+ },
1690
+ {
1691
+ "name": "oldOwner",
1692
+ "type": "address",
1693
+ "indexed": true,
1694
+ "internalType": "address"
1695
+ },
1696
+ {
1697
+ "name": "newOwner",
1698
+ "type": "address",
1699
+ "indexed": true,
1700
+ "internalType": "address"
1701
+ }
1702
+ ],
1703
+ "anonymous": false
1704
+ },
1705
+ {
1706
+ "type": "event",
1707
+ "name": "ProjectReclaimCancelled",
1708
+ "inputs": [
1709
+ {
1710
+ "name": "projectId",
1711
+ "type": "bytes32",
1712
+ "indexed": true,
1713
+ "internalType": "bytes32"
1714
+ }
1715
+ ],
1716
+ "anonymous": false
1717
+ },
1718
+ {
1719
+ "type": "event",
1720
+ "name": "ProjectReclaimProposed",
1721
+ "inputs": [
1722
+ {
1723
+ "name": "projectId",
1724
+ "type": "bytes32",
1725
+ "indexed": true,
1726
+ "internalType": "bytes32"
1727
+ },
1728
+ {
1729
+ "name": "currentOwner",
1730
+ "type": "address",
1731
+ "indexed": true,
1732
+ "internalType": "address"
1733
+ },
1734
+ {
1735
+ "name": "newOwner",
1736
+ "type": "address",
1737
+ "indexed": true,
1738
+ "internalType": "address"
1739
+ },
1740
+ {
1741
+ "name": "executableAt",
1742
+ "type": "uint48",
1743
+ "indexed": false,
1744
+ "internalType": "uint48"
1745
+ }
1746
+ ],
1747
+ "anonymous": false
1748
+ },
1749
+ {
1750
+ "type": "event",
1751
+ "name": "RequiredAccountCodehashSet",
1752
+ "inputs": [
1753
+ {
1754
+ "name": "sponsorId",
1755
+ "type": "bytes32",
1756
+ "indexed": true,
1757
+ "internalType": "bytes32"
1758
+ },
1759
+ {
1760
+ "name": "codehash",
1761
+ "type": "bytes32",
1762
+ "indexed": false,
1763
+ "internalType": "bytes32"
1764
+ }
1765
+ ],
1766
+ "anonymous": false
1767
+ },
1768
+ {
1769
+ "type": "event",
1770
+ "name": "SenderDailyLimitSet",
1771
+ "inputs": [
1772
+ {
1773
+ "name": "sponsorId",
1774
+ "type": "bytes32",
1775
+ "indexed": true,
1776
+ "internalType": "bytes32"
1777
+ },
1778
+ {
1779
+ "name": "limit",
1780
+ "type": "uint256",
1781
+ "indexed": false,
1782
+ "internalType": "uint256"
1783
+ }
1784
+ ],
1785
+ "anonymous": false
1786
+ },
1787
+ {
1788
+ "type": "event",
1789
+ "name": "SignerAdded",
1790
+ "inputs": [
1791
+ {
1792
+ "name": "signer",
1793
+ "type": "address",
1794
+ "indexed": false,
1795
+ "internalType": "address"
1796
+ }
1797
+ ],
1798
+ "anonymous": false
1799
+ },
1800
+ {
1801
+ "type": "event",
1802
+ "name": "SignerRemoved",
1803
+ "inputs": [
1804
+ {
1805
+ "name": "signer",
1806
+ "type": "address",
1807
+ "indexed": false,
1808
+ "internalType": "address"
1809
+ }
1810
+ ],
1811
+ "anonymous": false
1812
+ },
1813
+ {
1814
+ "type": "event",
1815
+ "name": "SponsorReserved",
1816
+ "inputs": [
1817
+ {
1818
+ "name": "sponsorId",
1819
+ "type": "bytes32",
1820
+ "indexed": true,
1821
+ "internalType": "bytes32"
1822
+ },
1823
+ {
1824
+ "name": "userOpHash",
1825
+ "type": "bytes32",
1826
+ "indexed": true,
1827
+ "internalType": "bytes32"
1828
+ },
1829
+ {
1830
+ "name": "sender",
1831
+ "type": "address",
1832
+ "indexed": true,
1833
+ "internalType": "address"
1834
+ },
1835
+ {
1836
+ "name": "amount",
1837
+ "type": "uint256",
1838
+ "indexed": false,
1839
+ "internalType": "uint256"
1840
+ }
1841
+ ],
1842
+ "anonymous": false
1843
+ },
1844
+ {
1845
+ "type": "event",
1846
+ "name": "SurplusCreditedToFreePool",
1847
+ "inputs": [
1848
+ {
1849
+ "name": "amount",
1850
+ "type": "uint256",
1851
+ "indexed": false,
1852
+ "internalType": "uint256"
1853
+ }
1854
+ ],
1855
+ "anonymous": false
1856
+ },
1857
+ {
1858
+ "type": "event",
1859
+ "name": "TargetSet",
1860
+ "inputs": [
1861
+ {
1862
+ "name": "sponsorId",
1863
+ "type": "bytes32",
1864
+ "indexed": true,
1865
+ "internalType": "bytes32"
1866
+ },
1867
+ {
1868
+ "name": "target",
1869
+ "type": "address",
1870
+ "indexed": true,
1871
+ "internalType": "address"
1872
+ },
1873
+ {
1874
+ "name": "allowed",
1875
+ "type": "bool",
1876
+ "indexed": false,
1877
+ "internalType": "bool"
1878
+ }
1879
+ ],
1880
+ "anonymous": false
1881
+ },
1882
+ {
1883
+ "type": "event",
1884
+ "name": "UserOpSettled",
1885
+ "inputs": [
1886
+ {
1887
+ "name": "sponsorId",
1888
+ "type": "bytes32",
1889
+ "indexed": true,
1890
+ "internalType": "bytes32"
1891
+ },
1892
+ {
1893
+ "name": "userOpHash",
1894
+ "type": "bytes32",
1895
+ "indexed": true,
1896
+ "internalType": "bytes32"
1897
+ },
1898
+ {
1899
+ "name": "sender",
1900
+ "type": "address",
1901
+ "indexed": true,
1902
+ "internalType": "address"
1903
+ },
1904
+ {
1905
+ "name": "reserved",
1906
+ "type": "uint256",
1907
+ "indexed": false,
1908
+ "internalType": "uint256"
1909
+ },
1910
+ {
1911
+ "name": "charged",
1912
+ "type": "uint256",
1913
+ "indexed": false,
1914
+ "internalType": "uint256"
1915
+ }
1916
+ ],
1917
+ "anonymous": false
1918
+ },
1919
+ {
1920
+ "type": "error",
1921
+ "name": "AccountCodehashMismatch",
1922
+ "inputs": [
1923
+ {
1924
+ "name": "sender",
1925
+ "type": "address",
1926
+ "internalType": "address"
1927
+ },
1928
+ {
1929
+ "name": "codehash",
1930
+ "type": "bytes32",
1931
+ "internalType": "bytes32"
1932
+ }
1933
+ ]
1934
+ },
1935
+ {
1936
+ "type": "error",
1937
+ "name": "AdminChangeAlreadyProposed",
1938
+ "inputs": []
1939
+ },
1940
+ {
1941
+ "type": "error",
1942
+ "name": "AdminChangeNotProposed",
1943
+ "inputs": []
1944
+ },
1945
+ {
1946
+ "type": "error",
1947
+ "name": "AdminChangeNotReady",
1948
+ "inputs": [
1949
+ {
1950
+ "name": "executableAt",
1951
+ "type": "uint48",
1952
+ "internalType": "uint48"
1953
+ }
1954
+ ]
1955
+ },
1956
+ {
1957
+ "type": "error",
1958
+ "name": "BundlerNotAllowed",
1959
+ "inputs": [
1960
+ {
1961
+ "name": "bundler",
1962
+ "type": "address",
1963
+ "internalType": "address"
1964
+ }
1965
+ ]
1966
+ },
1967
+ {
1968
+ "type": "error",
1969
+ "name": "ClaimAlreadyUsed",
1970
+ "inputs": [
1971
+ {
1972
+ "name": "digest",
1973
+ "type": "bytes32",
1974
+ "internalType": "bytes32"
1975
+ }
1976
+ ]
1977
+ },
1978
+ {
1979
+ "type": "error",
1980
+ "name": "ClaimDeadlineTooFar",
1981
+ "inputs": [
1982
+ {
1983
+ "name": "deadline",
1984
+ "type": "uint256",
1985
+ "internalType": "uint256"
1986
+ }
1987
+ ]
1988
+ },
1989
+ {
1990
+ "type": "error",
1991
+ "name": "ClaimExpired",
1992
+ "inputs": [
1993
+ {
1994
+ "name": "deadline",
1995
+ "type": "uint256",
1996
+ "internalType": "uint256"
1997
+ }
1998
+ ]
1999
+ },
2000
+ {
2001
+ "type": "error",
2002
+ "name": "CostTooLarge",
2003
+ "inputs": []
2004
+ },
2005
+ {
2006
+ "type": "error",
2007
+ "name": "DailyLimitExceeded",
2008
+ "inputs": [
2009
+ {
2010
+ "name": "sponsorId",
2011
+ "type": "bytes32",
2012
+ "internalType": "bytes32"
2013
+ }
2014
+ ]
2015
+ },
2016
+ {
2017
+ "type": "error",
2018
+ "name": "DelayTooLong",
2019
+ "inputs": []
2020
+ },
2021
+ {
2022
+ "type": "error",
2023
+ "name": "DelayTooShort",
2024
+ "inputs": []
2025
+ },
2026
+ {
2027
+ "type": "error",
2028
+ "name": "FreeTierDisabled",
2029
+ "inputs": []
2030
+ },
2031
+ {
2032
+ "type": "error",
2033
+ "name": "InsufficientSponsorBalance",
2034
+ "inputs": [
2035
+ {
2036
+ "name": "sponsorId",
2037
+ "type": "bytes32",
2038
+ "internalType": "bytes32"
2039
+ },
2040
+ {
2041
+ "name": "balance",
2042
+ "type": "uint256",
2043
+ "internalType": "uint256"
2044
+ },
2045
+ {
2046
+ "name": "maxCost",
2047
+ "type": "uint256",
2048
+ "internalType": "uint256"
2049
+ }
2050
+ ]
2051
+ },
2052
+ {
2053
+ "type": "error",
2054
+ "name": "InvalidAdminChange",
2055
+ "inputs": []
2056
+ },
2057
+ {
2058
+ "type": "error",
2059
+ "name": "InvalidAppId",
2060
+ "inputs": []
2061
+ },
2062
+ {
2063
+ "type": "error",
2064
+ "name": "InvalidClaimSignature",
2065
+ "inputs": []
2066
+ },
2067
+ {
2068
+ "type": "error",
2069
+ "name": "InvalidFreeTierConfig",
2070
+ "inputs": []
2071
+ },
2072
+ {
2073
+ "type": "error",
2074
+ "name": "InvalidOwner",
2075
+ "inputs": []
2076
+ },
2077
+ {
2078
+ "type": "error",
2079
+ "name": "InvalidValidityWindow",
2080
+ "inputs": []
2081
+ },
2082
+ {
2083
+ "type": "error",
2084
+ "name": "MaxFeePerGasTooHigh",
2085
+ "inputs": [
2086
+ {
2087
+ "name": "maxFeePerGas",
2088
+ "type": "uint256",
2089
+ "internalType": "uint256"
2090
+ },
2091
+ {
2092
+ "name": "cap",
2093
+ "type": "uint256",
2094
+ "internalType": "uint256"
2095
+ }
2096
+ ]
2097
+ },
2098
+ {
2099
+ "type": "error",
2100
+ "name": "NoPendingReclaim",
2101
+ "inputs": [
2102
+ {
2103
+ "name": "projectId",
2104
+ "type": "bytes32",
2105
+ "internalType": "bytes32"
2106
+ }
2107
+ ]
2108
+ },
2109
+ {
2110
+ "type": "error",
2111
+ "name": "NotEntryPoint",
2112
+ "inputs": []
2113
+ },
2114
+ {
2115
+ "type": "error",
2116
+ "name": "NotOwnerOrManager",
2117
+ "inputs": []
2118
+ },
2119
+ {
2120
+ "type": "error",
2121
+ "name": "NotPendingProjectOwner",
2122
+ "inputs": []
2123
+ },
2124
+ {
2125
+ "type": "error",
2126
+ "name": "NotProjectOwner",
2127
+ "inputs": []
2128
+ },
2129
+ {
2130
+ "type": "error",
2131
+ "name": "NothingToCredit",
2132
+ "inputs": []
2133
+ },
2134
+ {
2135
+ "type": "error",
2136
+ "name": "OpCostTooHigh",
2137
+ "inputs": [
2138
+ {
2139
+ "name": "maxCost",
2140
+ "type": "uint256",
2141
+ "internalType": "uint256"
2142
+ },
2143
+ {
2144
+ "name": "limit",
2145
+ "type": "uint256",
2146
+ "internalType": "uint256"
2147
+ }
2148
+ ]
2149
+ },
2150
+ {
2151
+ "type": "error",
2152
+ "name": "OverheadOutOfBounds",
2153
+ "inputs": []
2154
+ },
2155
+ {
2156
+ "type": "error",
2157
+ "name": "OwnableInvalidOwner",
2158
+ "inputs": [
2159
+ {
2160
+ "name": "owner",
2161
+ "type": "address",
2162
+ "internalType": "address"
2163
+ }
2164
+ ]
2165
+ },
2166
+ {
2167
+ "type": "error",
2168
+ "name": "OwnableUnauthorizedAccount",
2169
+ "inputs": [
2170
+ {
2171
+ "name": "account",
2172
+ "type": "address",
2173
+ "internalType": "address"
2174
+ }
2175
+ ]
2176
+ },
2177
+ {
2178
+ "type": "error",
2179
+ "name": "PaymasterAndDataLengthInvalid",
2180
+ "inputs": []
2181
+ },
2182
+ {
2183
+ "type": "error",
2184
+ "name": "PaymasterConfigLengthInvalid",
2185
+ "inputs": []
2186
+ },
2187
+ {
2188
+ "type": "error",
2189
+ "name": "PaymasterModeInvalid",
2190
+ "inputs": []
2191
+ },
2192
+ {
2193
+ "type": "error",
2194
+ "name": "PaymasterSignatureLengthInvalid",
2195
+ "inputs": []
2196
+ },
2197
+ {
2198
+ "type": "error",
2199
+ "name": "PostOpGasLimitTooLow",
2200
+ "inputs": []
2201
+ },
2202
+ {
2203
+ "type": "error",
2204
+ "name": "ProjectAlreadyClaimed",
2205
+ "inputs": [
2206
+ {
2207
+ "name": "projectId",
2208
+ "type": "bytes32",
2209
+ "internalType": "bytes32"
2210
+ }
2211
+ ]
2212
+ },
2213
+ {
2214
+ "type": "error",
2215
+ "name": "ProjectNotClaimed",
2216
+ "inputs": [
2217
+ {
2218
+ "name": "projectId",
2219
+ "type": "bytes32",
2220
+ "internalType": "bytes32"
2221
+ }
2222
+ ]
2223
+ },
2224
+ {
2225
+ "type": "error",
2226
+ "name": "ReclaimNotCancellable",
2227
+ "inputs": [
2228
+ {
2229
+ "name": "projectId",
2230
+ "type": "bytes32",
2231
+ "internalType": "bytes32"
2232
+ }
2233
+ ]
2234
+ },
2235
+ {
2236
+ "type": "error",
2237
+ "name": "ReclaimNotReady",
2238
+ "inputs": [
2239
+ {
2240
+ "name": "executableAt",
2241
+ "type": "uint48",
2242
+ "internalType": "uint48"
2243
+ }
2244
+ ]
2245
+ },
2246
+ {
2247
+ "type": "error",
2248
+ "name": "ReclaimSignerRemoved",
2249
+ "inputs": [
2250
+ {
2251
+ "name": "signer",
2252
+ "type": "address",
2253
+ "internalType": "address"
2254
+ }
2255
+ ]
2256
+ },
2257
+ {
2258
+ "type": "error",
2259
+ "name": "ReentrancyGuardReentrantCall",
2260
+ "inputs": []
2261
+ },
2262
+ {
2263
+ "type": "error",
2264
+ "name": "SenderDailyLimitExceeded",
2265
+ "inputs": [
2266
+ {
2267
+ "name": "sponsorId",
2268
+ "type": "bytes32",
2269
+ "internalType": "bytes32"
2270
+ },
2271
+ {
2272
+ "name": "sender",
2273
+ "type": "address",
2274
+ "internalType": "address"
2275
+ }
2276
+ ]
2277
+ },
2278
+ {
2279
+ "type": "error",
2280
+ "name": "SponsorPaused",
2281
+ "inputs": [
2282
+ {
2283
+ "name": "sponsorId",
2284
+ "type": "bytes32",
2285
+ "internalType": "bytes32"
2286
+ }
2287
+ ]
2288
+ },
2289
+ {
2290
+ "type": "error",
2291
+ "name": "TargetNotAllowed",
2292
+ "inputs": [
2293
+ {
2294
+ "name": "target",
2295
+ "type": "address",
2296
+ "internalType": "address"
2297
+ }
2298
+ ]
2299
+ },
2300
+ {
2301
+ "type": "error",
2302
+ "name": "UnknownSponsor",
2303
+ "inputs": [
2304
+ {
2305
+ "name": "sponsorId",
2306
+ "type": "bytes32",
2307
+ "internalType": "bytes32"
2308
+ }
2309
+ ]
2310
+ },
2311
+ {
2312
+ "type": "error",
2313
+ "name": "UnsupportedCallData",
2314
+ "inputs": []
2315
+ },
2316
+ {
2317
+ "type": "error",
2318
+ "name": "ZeroAmount",
2319
+ "inputs": []
2320
+ },
2321
+ {
2322
+ "type": "error",
2323
+ "name": "ZeroDailyLimit",
2324
+ "inputs": []
2325
+ },
2326
+ {
2327
+ "type": "error",
2328
+ "name": "ZeroFeeCap",
2329
+ "inputs": []
2330
+ }
2331
+ ];
2332
+ var PAYMASTER_DENIAL_REASONS = [
2333
+ // v2
2334
+ "unknown_or_invalid_app_credential",
2335
+ "app_suspended",
2336
+ "invalid_or_expired_token",
2337
+ "sender_not_owned_by_token_user",
2338
+ "calldata_decode_failed",
2339
+ "project_not_claimed_onchain",
2340
+ "project_owner_changed",
2341
+ "project_paused",
2342
+ "project_balance_exhausted",
2343
+ "project_daily_limit_reached",
2344
+ "project_user_cap_exceeded",
2345
+ "project_identity_required",
2346
+ "project_origin_not_allowed",
2347
+ "project_sender_limit_reached",
2348
+ "project_sender_limit_not_set",
2349
+ "account_deployment_disabled",
2350
+ "target_not_allowed_onchain",
2351
+ "destination_not_allowed_for_app",
2352
+ "free_tier_disabled",
2353
+ "free_tier_identity_required",
2354
+ "free_tier_user_daily_exceeded",
2355
+ "free_tier_user_hourly_exceeded",
2356
+ "free_tier_count_exceeded",
2357
+ "free_tier_sender_limit_reached",
2358
+ "free_pool_empty",
2359
+ "free_pool_op_too_large",
2360
+ "chain_read_failed",
2361
+ "gas_limits_out_of_bounds",
2362
+ "fee_out_of_bounds",
2363
+ "fee_above_onchain_cap",
2364
+ "reservation_cap_exceeded",
2365
+ "rate_limited",
2366
+ "malformed_request",
2367
+ // v1 only
2368
+ "destination_not_globally_allowed",
2369
+ "user_hourly_count_cap_exceeded",
2370
+ "user_daily_count_cap_exceeded",
2371
+ "user_lifetime_count_cap_exceeded",
2372
+ "user_hourly_spend_cap_exceeded",
2373
+ "user_daily_spend_cap_exceeded",
2374
+ "user_lifetime_spend_cap_exceeded",
2375
+ "app_daily_spend_cap_exceeded",
2376
+ "app_lifetime_spend_cap_exceeded",
2377
+ "global_circuit_breaker_tripped"
2378
+ ];
2379
+ var PAYMASTER_REASON_CODES = {
2380
+ unknown_or_invalid_app_credential: "PAYMASTER_DENIED",
2381
+ app_suspended: "PAYMASTER_DENIED",
2382
+ invalid_or_expired_token: "AUTH_INVALID_TOKEN",
2383
+ sender_not_owned_by_token_user: "PAYMASTER_DENIED",
2384
+ calldata_decode_failed: "PAYMASTER_DENIED",
2385
+ project_not_claimed_onchain: "PAYMASTER_PROJECT_NOT_CLAIMED",
2386
+ project_owner_changed: "PAYMASTER_PROJECT_OWNER_CHANGED",
2387
+ project_paused: "PAYMASTER_PROJECT_PAUSED",
2388
+ project_balance_exhausted: "PAYMASTER_NO_BALANCE",
2389
+ project_daily_limit_reached: "PAYMASTER_CAP",
2390
+ project_user_cap_exceeded: "PAYMASTER_CAP",
2391
+ project_identity_required: "PAYMASTER_IDENTITY_REQUIRED",
2392
+ project_origin_not_allowed: "PAYMASTER_ORIGIN_NOT_ALLOWED",
2393
+ project_sender_limit_reached: "PAYMASTER_CAP",
2394
+ project_sender_limit_not_set: "PAYMASTER_DENIED",
2395
+ account_deployment_disabled: "PAYMASTER_DENIED",
2396
+ target_not_allowed_onchain: "PAYMASTER_DESTINATION_NOT_ALLOWED",
2397
+ destination_not_allowed_for_app: "PAYMASTER_DESTINATION_NOT_ALLOWED",
2398
+ free_tier_disabled: "PAYMASTER_FREE_TIER_UNAVAILABLE",
2399
+ free_tier_identity_required: "PAYMASTER_IDENTITY_REQUIRED",
2400
+ free_tier_user_daily_exceeded: "PAYMASTER_CAP",
2401
+ free_tier_user_hourly_exceeded: "PAYMASTER_CAP",
2402
+ free_tier_count_exceeded: "PAYMASTER_CAP",
2403
+ free_tier_sender_limit_reached: "PAYMASTER_CAP",
2404
+ free_pool_empty: "PAYMASTER_FREE_TIER_UNAVAILABLE",
2405
+ free_pool_op_too_large: "PAYMASTER_FREE_TIER_UNAVAILABLE",
2406
+ chain_read_failed: "PAYMASTER_API_ERROR",
2407
+ gas_limits_out_of_bounds: "PAYMASTER_DENIED",
2408
+ fee_out_of_bounds: "PAYMASTER_DENIED",
2409
+ fee_above_onchain_cap: "PAYMASTER_CAP",
2410
+ reservation_cap_exceeded: "PAYMASTER_CAP",
2411
+ rate_limited: "PAYMASTER_RATE_LIMITED",
2412
+ malformed_request: "PAYMASTER_DENIED",
2413
+ destination_not_globally_allowed: "PAYMASTER_DESTINATION_NOT_ALLOWED",
2414
+ user_hourly_count_cap_exceeded: "PAYMASTER_CAP",
2415
+ user_daily_count_cap_exceeded: "PAYMASTER_CAP",
2416
+ user_lifetime_count_cap_exceeded: "PAYMASTER_CAP",
2417
+ user_hourly_spend_cap_exceeded: "PAYMASTER_CAP",
2418
+ user_daily_spend_cap_exceeded: "PAYMASTER_CAP",
2419
+ user_lifetime_spend_cap_exceeded: "PAYMASTER_CAP",
2420
+ app_daily_spend_cap_exceeded: "PAYMASTER_CAP",
2421
+ app_lifetime_spend_cap_exceeded: "PAYMASTER_CAP",
2422
+ global_circuit_breaker_tripped: "PAYMASTER_CAP"
2423
+ };
2424
+ var RETRYABLE_REASONS = /* @__PURE__ */ new Set(["chain_read_failed", "rate_limited"]);
2425
+ function mapPaymasterReason(reason) {
2426
+ if (reason !== void 0 && Object.prototype.hasOwnProperty.call(PAYMASTER_REASON_CODES, reason)) {
2427
+ return PAYMASTER_REASON_CODES[reason];
2428
+ }
2429
+ return "PAYMASTER_DENIED";
2430
+ }
2431
+ function paymasterReasonToError(reason, message, details) {
2432
+ const code = mapPaymasterReason(reason);
2433
+ const text = `Paymaster denied the operation${reason ? ` (${reason})` : ""}${message ? `: ${message}` : "."}`;
2434
+ const retryable = reason !== void 0 && RETRYABLE_REASONS.has(reason) ? true : void 0;
2435
+ return new PepuPaymasterError(code, text, {
2436
+ details: { reason, ...details && typeof details === "object" ? details : {} },
2437
+ ...retryable === void 0 ? {} : { retryable }
2438
+ });
2439
+ }
2440
+ function decodePaymasterRevert(data) {
2441
+ try {
2442
+ const d = decodeErrorResult({ abi: pepuSponsoredPaymasterV2Abi, data });
2443
+ return { errorName: d.errorName, args: d.args };
2444
+ } catch {
2445
+ return null;
2446
+ }
2447
+ }
2448
+ var CLIENT_TOKEN_PREFIX = "ppt_";
2449
+ var SERVER_KEY_PREFIX = "ppk_";
2450
+ function credentialKind(credential) {
2451
+ if (credential.startsWith(CLIENT_TOKEN_PREFIX)) return "client";
2452
+ if (credential.startsWith(SERVER_KEY_PREFIX)) return "server";
2453
+ return null;
2454
+ }
2455
+ function trimBase(url) {
2456
+ return url.replace(/\/+$/, "");
2457
+ }
2458
+ function buildErc7677Url(options) {
2459
+ const token = options.token.trim();
2460
+ if (token === "") {
2461
+ throw new PepuConfigError("CONFIG_MISSING_ENV", "buildErc7677Url needs a project client token or server key.");
2462
+ }
2463
+ if (credentialKind(token) === "server" && globalThis.window !== void 0) {
2464
+ throw new PepuConfigError(
2465
+ "CONFIG_SERVER_ONLY",
2466
+ "Refusing to build an ERC-7677 URL from a server key (ppk_) in a browser: the URL embeds the secret. Use the client token (ppt_)."
2467
+ );
2468
+ }
2469
+ let base;
2470
+ try {
2471
+ base = new URL(options.baseUrl);
2472
+ } catch {
2473
+ throw new PepuConfigError("CONFIG_BAD_URL", "buildErc7677Url: baseUrl is not a valid URL.");
2474
+ }
2475
+ if (base.protocol !== "http:" && base.protocol !== "https:") {
2476
+ throw new PepuConfigError("CONFIG_BAD_URL", "buildErc7677Url: baseUrl must be an http(s) URL.");
2477
+ }
2478
+ const prefix = (options.version ?? 2) === 2 ? "/v2/paymaster/" : "/paymaster/";
2479
+ return `${trimBase(options.baseUrl)}${prefix}${encodeURIComponent(token)}`;
2480
+ }
2481
+ function hostedErc7677Url(token) {
2482
+ if (PEPU_HOSTED.paymasterBaseUrl === null) {
2483
+ throw new PepuConfigError("CONFIG_MISSING_ENV", "No hosted paymaster base URL is set.");
2484
+ }
2485
+ return buildErc7677Url({ baseUrl: PEPU_HOSTED.paymasterBaseUrl, token });
2486
+ }
2487
+ function toQuantity(v) {
2488
+ return typeof v === "bigint" ? toHex(v) : v;
2489
+ }
2490
+ function serializeUserOp(op) {
2491
+ const out = {
2492
+ sender: op.sender,
2493
+ nonce: toQuantity(op.nonce),
2494
+ callData: op.callData,
2495
+ callGasLimit: toQuantity(op.callGasLimit),
2496
+ verificationGasLimit: toQuantity(op.verificationGasLimit),
2497
+ preVerificationGas: toQuantity(op.preVerificationGas),
2498
+ maxFeePerGas: toQuantity(op.maxFeePerGas),
2499
+ maxPriorityFeePerGas: toQuantity(op.maxPriorityFeePerGas)
2500
+ };
2501
+ if (op.factory !== void 0) out["factory"] = op.factory;
2502
+ if (op.factoryData !== void 0) out["factoryData"] = op.factoryData;
2503
+ return out;
2504
+ }
2505
+ function assertApproved(result) {
2506
+ if (result.status === "approved") return result;
2507
+ throw paymasterReasonToError(result.reason, result.message, result.detail ? { detail: result.detail } : void 0);
2508
+ }
2509
+ function retryAfter(res) {
2510
+ const raw = res.headers.get("retry-after");
2511
+ const n = raw === null ? NaN : Number(raw);
2512
+ return Number.isFinite(n) ? n : void 0;
2513
+ }
2514
+ function isRecord(v) {
2515
+ return typeof v === "object" && v !== null && !Array.isArray(v);
2516
+ }
2517
+ function missingBaseUrl() {
2518
+ return new PepuConfigError(
2519
+ "CONFIG_MISSING_ENV",
2520
+ "No paymaster URL configured. Set PEPU_PAYMASTER_URL (or NEXT_PUBLIC_PEPU_PAYMASTER_URL), or pass baseUrl to createPaymasterApi."
2521
+ );
2522
+ }
2523
+ function createPaymasterApi(options = {}) {
2524
+ const resolved = options.baseUrl ?? resolvePepuEndpoints(options.env ? { env: options.env } : {}).paymasterBaseUrl;
2525
+ if (resolved === null || resolved === void 0 || resolved.trim() === "") throw missingBaseUrl();
2526
+ try {
2527
+ const u = new URL(resolved);
2528
+ if (u.protocol !== "http:" && u.protocol !== "https:") throw new Error("protocol");
2529
+ } catch {
2530
+ throw new PepuConfigError("CONFIG_BAD_URL", "The paymaster baseUrl is not a valid http(s) URL.");
2531
+ }
2532
+ const baseUrl = trimBase(resolved.trim());
2533
+ const doFetch = options.fetch ?? ((...args) => fetch(...args));
2534
+ const timeoutMs = options.timeoutMs ?? 15e3;
2535
+ let sessionToken = options.sessionToken ?? null;
2536
+ async function send(url, init) {
2537
+ try {
2538
+ return await doFetch(url, { ...init, signal: AbortSignal.timeout(timeoutMs) });
2539
+ } catch (e) {
2540
+ const timedOut = e instanceof Error && (e.name === "TimeoutError" || e.name === "AbortError");
2541
+ throw new PepuPaymasterError(
2542
+ "BUNDLER_UNREACHABLE",
2543
+ timedOut ? "The paymaster did not answer in time." : "Could not reach the paymaster service.",
2544
+ { details: { path: new URL(url).pathname.replace(/\/(ppt_|ppk_)[^/]*/, "/<credential>") } }
2545
+ );
2546
+ }
2547
+ }
2548
+ async function readJson(res) {
2549
+ const text = await res.text().catch(() => "");
2550
+ if (text === "") return void 0;
2551
+ try {
2552
+ return JSON.parse(text);
2553
+ } catch {
2554
+ return void 0;
2555
+ }
2556
+ }
2557
+ function apiError(res, body, quiet) {
2558
+ const rec = isRecord(body) ? body : {};
2559
+ const errorCode = typeof rec["error"] === "string" ? rec["error"] : void 0;
2560
+ const reason = typeof rec["reason"] === "string" ? rec["reason"] : void 0;
2561
+ const serverMessage = typeof rec["message"] === "string" && !quiet ? rec["message"] : void 0;
2562
+ const details = { status: res.status, error: errorCode, reason, retryAfterSeconds: retryAfter(res) };
2563
+ const tagged = reason ?? errorCode;
2564
+ let code;
2565
+ if (res.status === 401 && errorCode === "unauthenticated") code = "PAYMASTER_SESSION_REQUIRED";
2566
+ else if (tagged !== void 0 && mapPaymasterReason(tagged) !== "PAYMASTER_DENIED") code = mapPaymasterReason(tagged);
2567
+ else if (res.status === 401 && errorCode !== "login_failed") code = "PAYMASTER_SESSION_REQUIRED";
2568
+ else if (res.status === 401) code = "PAYMASTER_DENIED";
2569
+ else if (res.status === 429) code = "PAYMASTER_RATE_LIMITED";
2570
+ else if (res.status === 403) code = "PAYMASTER_DENIED";
2571
+ else code = "PAYMASTER_API_ERROR";
2572
+ const label = `Paymaster API ${res.status}${errorCode ? ` ${errorCode}` : ""}${reason && reason !== errorCode ? ` (${reason})` : ""}`;
2573
+ return new PepuPaymasterError(code, serverMessage ? `${label}: ${serverMessage}` : `${label}.`, {
2574
+ details,
2575
+ ...res.status === 429 || res.status === 503 ? { retryable: true } : {}
2576
+ });
2577
+ }
2578
+ async function request(method, path, o = {}) {
2579
+ const headers = { accept: "application/json" };
2580
+ if (o.body !== void 0) headers["content-type"] = "application/json";
2581
+ if (o.session) {
2582
+ if (!sessionToken) {
2583
+ throw new PepuPaymasterError("PAYMASTER_SESSION_REQUIRED", "This call needs a SIWE session. Call loginWithWallet() first.");
2584
+ }
2585
+ headers["authorization"] = `Bearer ${sessionToken}`;
2586
+ }
2587
+ let url = `${baseUrl}${path}`;
2588
+ if (o.query) {
2589
+ const qs = new URLSearchParams();
2590
+ for (const [k, v] of Object.entries(o.query)) if (v !== void 0) qs.set(k, String(v));
2591
+ const s = qs.toString();
2592
+ if (s) url += `?${s}`;
2593
+ }
2594
+ const res = await send(url, { method, headers, ...o.body !== void 0 ? { body: JSON.stringify(o.body) } : {} });
2595
+ const body = await readJson(res);
2596
+ if (!res.ok) throw apiError(res, body, o.quietErrors === true);
2597
+ return body;
2598
+ }
2599
+ async function sponsor(path, userOp, auth) {
2600
+ if (!auth.apiKey) {
2601
+ throw new PepuConfigError("CONFIG_MISSING_ENV", "sponsor needs auth.apiKey (the project server key or client token).");
2602
+ }
2603
+ const headers = {
2604
+ accept: "application/json",
2605
+ "content-type": "application/json",
2606
+ "x-api-key": auth.apiKey
2607
+ };
2608
+ if (auth.privyAccessToken) headers["authorization"] = `Bearer ${auth.privyAccessToken}`;
2609
+ if (auth.origin) headers["origin"] = auth.origin;
2610
+ const res = await send(`${baseUrl}${path}`, {
2611
+ method: "POST",
2612
+ headers,
2613
+ body: JSON.stringify({ userOp: serializeUserOp(userOp) })
2614
+ });
2615
+ const body = await readJson(res);
2616
+ if (isRecord(body) && (body["status"] === "approved" || body["status"] === "denied")) {
2617
+ return body;
2618
+ }
2619
+ throw apiError(res, body, false);
2620
+ }
2621
+ const projectPath = (id, sub = "") => {
2622
+ if (!/^0x[0-9a-fA-F]{64}$/.test(id)) {
2623
+ throw new PepuPaymasterError("PAYMASTER_DENIED", "projectId must be a 0x-prefixed 32-byte hex string.");
2624
+ }
2625
+ return `/v2/projects/${id}${sub}`;
2626
+ };
2627
+ const v1 = {
2628
+ sponsor: async (userOp, auth) => {
2629
+ if (!auth.privyAccessToken) {
2630
+ throw new PepuPaymasterError(
2631
+ "PAYMASTER_IDENTITY_REQUIRED",
2632
+ "The v1 /sponsor endpoint requires the user's Privy access token (auth.privyAccessToken)."
2633
+ );
2634
+ }
2635
+ return sponsor("/sponsor", userOp, auth);
2636
+ },
2637
+ health: async () => {
2638
+ const res = await send(`${baseUrl}/health`, { method: "GET" });
2639
+ const body = await readJson(res);
2640
+ if (!res.ok) throw apiError(res, body, false);
2641
+ return isRecord(body) ? body : { status: "ok" };
2642
+ },
2643
+ erc7677Url: (token) => buildErc7677Url({ baseUrl, token, version: 1 })
2644
+ };
2645
+ const v2 = {
2646
+ sponsor: (userOp, auth) => sponsor("/v2/sponsor", userOp, auth),
2647
+ erc7677Url: (token) => buildErc7677Url({ baseUrl, token, version: 2 }),
2648
+ config: () => request("GET", "/v2/config"),
2649
+ contract: () => request("GET", "/v2/contract"),
2650
+ freeTier: () => request("GET", "/v2/free-tier"),
2651
+ auth: {
2652
+ nonce: () => request("GET", "/v2/auth/nonce"),
2653
+ login: async (message, signature) => {
2654
+ const r = await request("POST", "/v2/auth/login", { body: { message, signature } });
2655
+ sessionToken = r.token;
2656
+ return r;
2657
+ },
2658
+ logout: async () => {
2659
+ await request("POST", "/v2/auth/logout", { session: true });
2660
+ sessionToken = null;
2661
+ }
2662
+ },
2663
+ me: () => request("GET", "/v2/me", { session: true }),
2664
+ loginWithWallet: async (sign, o) => {
2665
+ if (!isAddress(o.address, { strict: false })) {
2666
+ throw new PepuPaymasterError("PAYMASTER_DENIED", "loginWithWallet: address is not a valid address.");
2667
+ }
2668
+ const { nonce } = await v2.auth.nonce();
2669
+ const now = (o.now ?? Date.now)();
2670
+ const message = createSiweMessage({
2671
+ address: o.address,
2672
+ chainId: o.chainId ?? pepuMainnet.id,
2673
+ domain: o.domain,
2674
+ nonce,
2675
+ uri: o.uri ?? `https://${o.domain}`,
2676
+ version: "1",
2677
+ statement: o.statement ?? "Sign in to manage your PEPU gas sponsorship project. This does not move any funds.",
2678
+ issuedAt: new Date(now),
2679
+ expirationTime: new Date(now + (o.lifetimeSeconds ?? 300) * 1e3)
2680
+ });
2681
+ const signature = await sign(message);
2682
+ return v2.auth.login(message, signature);
2683
+ },
2684
+ getSessionToken: () => sessionToken,
2685
+ setSessionToken: (t) => {
2686
+ sessionToken = t;
2687
+ },
2688
+ projects: {
2689
+ prepare: (body) => request("POST", "/v2/projects/prepare", { session: true, body }),
2690
+ register: (body) => request("POST", "/v2/projects", { session: true, body }),
2691
+ list: () => request("GET", "/v2/projects", { session: true }),
2692
+ get: async (id) => request("GET", projectPath(id), { session: true }),
2693
+ rotateClientToken: async (id) => request("POST", projectPath(id, "/token/rotate"), { session: true }),
2694
+ rotateServerKey: async (id) => request("POST", projectPath(id, "/server-key/rotate"), { session: true }),
2695
+ updateSettings: async (id, body) => request("PATCH", projectPath(id, "/settings"), { session: true, body }),
2696
+ usage: async (id, q = {}) => request("GET", projectPath(id, "/usage"), { session: true, query: { ...q } }),
2697
+ events: async (id, q = {}) => request("GET", projectPath(id, "/events"), { session: true, query: { ...q } }),
2698
+ allowlist: async (id) => request("GET", projectPath(id, "/allowlist"), { session: true })
2699
+ },
2700
+ request
2701
+ };
2702
+ return { baseUrl, v1, v2 };
2703
+ }
2704
+ function serializeAttestation(a) {
2705
+ return {
2706
+ appId: a.appId,
2707
+ newOwner: a.newOwner,
2708
+ nonce: a.nonce.toString(),
2709
+ deadline: a.deadline.toString(),
2710
+ signature: a.signature
2711
+ };
2712
+ }
2713
+
2714
+ export { PAYMASTER_DENIAL_REASONS, PAYMASTER_REASON_CODES, assertApproved, buildErc7677Url, createPaymasterApi, credentialKind, decodePaymasterRevert, hostedErc7677Url, mapPaymasterReason, paymasterReasonToError, pepuSponsoredPaymasterV2Abi, serializeAttestation };
2715
+ //# sourceMappingURL=chunk-IY3ALPUJ.js.map
2716
+ //# sourceMappingURL=chunk-IY3ALPUJ.js.map