@zoralabs/limit-orders 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (208) hide show
  1. package/.turbo/turbo-build$colon$js.log +85 -0
  2. package/AUDIT_NOTES.md +33 -0
  3. package/AUDIT_RFP.md +408 -0
  4. package/CHANGELOG.md +25 -0
  5. package/GAS_COMPARISON_RESULTS.md +194 -0
  6. package/LICENSE +21 -0
  7. package/README.md +650 -0
  8. package/SPEC.md +291 -0
  9. package/abis/BalanceDeltaLibrary.json +15 -0
  10. package/abis/BeforeSwapDeltaLibrary.json +15 -0
  11. package/abis/CurrencyLibrary.json +25 -0
  12. package/abis/CustomRevert.json +28 -0
  13. package/abis/IAllowanceTransfer.json +486 -0
  14. package/abis/IAuthority.json +31 -0
  15. package/abis/ICoin.json +1074 -0
  16. package/abis/IDeployedCoinVersionLookup.json +21 -0
  17. package/abis/IDopplerErrors.json +44 -0
  18. package/abis/IEIP712.json +15 -0
  19. package/abis/IERC1363.json +373 -0
  20. package/abis/IERC165.json +21 -0
  21. package/abis/IERC20.json +185 -0
  22. package/abis/IERC20Minimal.json +172 -0
  23. package/abis/IERC6909Claims.json +288 -0
  24. package/abis/IERC7572.json +21 -0
  25. package/abis/IExtsload.json +64 -0
  26. package/abis/IExttload.json +40 -0
  27. package/abis/IHasCoinType.json +15 -0
  28. package/abis/IHasPoolKey.json +42 -0
  29. package/abis/IHasRewardsRecipients.json +54 -0
  30. package/abis/IHasSwapPath.json +60 -0
  31. package/abis/IHasTotalSupplyForPositions.json +15 -0
  32. package/abis/IHooks.json +789 -0
  33. package/abis/IMsgSender.json +15 -0
  34. package/abis/IPoolManager.json +1286 -0
  35. package/abis/IProtocolFees.json +174 -0
  36. package/abis/ISupportsLimitOrderFill.json +15 -0
  37. package/abis/ISwapPathRouter.json +92 -0
  38. package/abis/ISwapRouter.json +219 -0
  39. package/abis/IUniswapV3SwapCallback.json +25 -0
  40. package/abis/IUpgradeableDestinationV4Hook.json +84 -0
  41. package/abis/IUpgradeableDestinationV4HookWithUpdateableFee.json +95 -0
  42. package/abis/IUpgradeableV4Hook.json +112 -0
  43. package/abis/IZoraHookRegistry.json +188 -0
  44. package/abis/IZoraLimitOrderBook.json +623 -0
  45. package/abis/IZoraLimitOrderBookCoinsInterface.json +67 -0
  46. package/abis/IZoraV4CoinHook.json +610 -0
  47. package/abis/Permit2Payments.json +7 -0
  48. package/abis/Position.json +7 -0
  49. package/abis/SafeCast.json +7 -0
  50. package/abis/SafeCast160.json +7 -0
  51. package/abis/SafeERC20.json +34 -0
  52. package/abis/SimpleAccessManaged.json +57 -0
  53. package/abis/SimpleAccessManager.json +351 -0
  54. package/abis/SqrtPriceMath.json +22 -0
  55. package/abis/StateLibrary.json +80 -0
  56. package/abis/SwapLimitOrders.json +22 -0
  57. package/abis/SwapWithLimitOrders.json +457 -0
  58. package/abis/TickBitmap.json +18 -0
  59. package/abis/TickMath.json +24 -0
  60. package/abis/V3ToV4SwapLib.json +28 -0
  61. package/abis/ZoraLimitOrderBook.json +771 -0
  62. package/cache/solidity-files-cache.json +1 -0
  63. package/dist/index.cjs +760 -0
  64. package/dist/index.cjs.map +1 -0
  65. package/dist/index.d.ts +2 -0
  66. package/dist/index.d.ts.map +1 -0
  67. package/dist/index.js +731 -0
  68. package/dist/index.js.map +1 -0
  69. package/dist/wagmiGenerated.d.ts +1012 -0
  70. package/dist/wagmiGenerated.d.ts.map +1 -0
  71. package/foundry.toml +29 -0
  72. package/gas_comparison.py +49 -0
  73. package/out/BalanceDelta.sol/BalanceDeltaLibrary.json +1 -0
  74. package/out/BeforeSwapDelta.sol/BeforeSwapDeltaLibrary.json +1 -0
  75. package/out/BitMath.sol/BitMath.json +1 -0
  76. package/out/BytesLib.sol/BytesLib.json +1 -0
  77. package/out/CoinCommon.sol/CoinCommon.json +1 -0
  78. package/out/CoinConfigurationVersions.sol/CoinConfigurationVersions.json +1 -0
  79. package/out/CoinConstants.sol/CoinConstants.json +1 -0
  80. package/out/Context.sol/Context.json +1 -0
  81. package/out/Currency.sol/CurrencyLibrary.json +1 -0
  82. package/out/CurrencyReserves.sol/CurrencyReserves.json +1 -0
  83. package/out/CustomRevert.sol/CustomRevert.json +1 -0
  84. package/out/DopplerMath.sol/DopplerMath.json +1 -0
  85. package/out/FixedPoint128.sol/FixedPoint128.json +1 -0
  86. package/out/FixedPoint96.sol/FixedPoint96.json +1 -0
  87. package/out/FullMath.sol/FullMath.json +1 -0
  88. package/out/IAllowanceTransfer.sol/IAllowanceTransfer.json +1 -0
  89. package/out/IAuthority.sol/IAuthority.json +1 -0
  90. package/out/ICoin.sol/ICoin.json +1 -0
  91. package/out/ICoin.sol/IHasCoinType.json +1 -0
  92. package/out/ICoin.sol/IHasPoolKey.json +1 -0
  93. package/out/ICoin.sol/IHasSwapPath.json +1 -0
  94. package/out/ICoin.sol/IHasTotalSupplyForPositions.json +1 -0
  95. package/out/IDeployedCoinVersionLookup.sol/IDeployedCoinVersionLookup.json +1 -0
  96. package/out/IDopplerErrors.sol/IDopplerErrors.json +1 -0
  97. package/out/IEIP712.sol/IEIP712.json +1 -0
  98. package/out/IERC1363.sol/IERC1363.json +1 -0
  99. package/out/IERC165.sol/IERC165.json +1 -0
  100. package/out/IERC20.sol/IERC20.json +1 -0
  101. package/out/IERC20Minimal.sol/IERC20Minimal.json +1 -0
  102. package/out/IERC6909Claims.sol/IERC6909Claims.json +1 -0
  103. package/out/IERC7572.sol/IERC7572.json +1 -0
  104. package/out/IExtsload.sol/IExtsload.json +1 -0
  105. package/out/IExttload.sol/IExttload.json +1 -0
  106. package/out/IHasRewardsRecipients.sol/IHasRewardsRecipients.json +1 -0
  107. package/out/IHooks.sol/IHooks.json +1 -0
  108. package/out/IMsgSender.sol/IMsgSender.json +1 -0
  109. package/out/IPoolManager.sol/IPoolManager.json +1 -0
  110. package/out/IProtocolFees.sol/IProtocolFees.json +1 -0
  111. package/out/ISupportsLimitOrderFill.sol/ISupportsLimitOrderFill.json +1 -0
  112. package/out/ISwapPathRouter.sol/ISwapPathRouter.json +1 -0
  113. package/out/ISwapRouter.sol/ISwapRouter.json +1 -0
  114. package/out/IUniswapV3SwapCallback.sol/IUniswapV3SwapCallback.json +1 -0
  115. package/out/IUpgradeableV4Hook.sol/IUpgradeableDestinationV4Hook.json +1 -0
  116. package/out/IUpgradeableV4Hook.sol/IUpgradeableDestinationV4HookWithUpdateableFee.json +1 -0
  117. package/out/IUpgradeableV4Hook.sol/IUpgradeableV4Hook.json +1 -0
  118. package/out/IZoraHookRegistry.sol/IZoraHookRegistry.json +1 -0
  119. package/out/IZoraLimitOrderBook.sol/IZoraLimitOrderBook.json +1 -0
  120. package/out/IZoraLimitOrderBookCoinsInterface.sol/IZoraLimitOrderBookCoinsInterface.json +1 -0
  121. package/out/IZoraV4CoinHook.sol/IZoraV4CoinHook.json +1 -0
  122. package/out/LimitOrderBitmap.sol/LimitOrderBitmap.json +1 -0
  123. package/out/LimitOrderCommon.sol/LimitOrderCommon.json +1 -0
  124. package/out/LimitOrderCreate.sol/LimitOrderCreate.json +1 -0
  125. package/out/LimitOrderFill.sol/LimitOrderFill.json +1 -0
  126. package/out/LimitOrderLiquidity.sol/LimitOrderLiquidity.json +1 -0
  127. package/out/LimitOrderQueues.sol/LimitOrderQueues.json +1 -0
  128. package/out/LimitOrderStorage.sol/LimitOrderStorage.json +1 -0
  129. package/out/LimitOrderTypes.sol/LimitOrderTypes.json +1 -0
  130. package/out/LimitOrderWithdraw.sol/LimitOrderWithdraw.json +1 -0
  131. package/out/LiquidityAmounts.sol/LiquidityAmounts.json +1 -0
  132. package/out/LiquidityMath.sol/LiquidityMath.json +1 -0
  133. package/out/Lock.sol/Lock.json +1 -0
  134. package/out/NonzeroDeltaCount.sol/NonzeroDeltaCount.json +1 -0
  135. package/out/Path.sol/Path.json +1 -0
  136. package/out/PathKey.sol/PathKeyLibrary.json +1 -0
  137. package/out/Permit2Payments.sol/Permit2Payments.json +1 -0
  138. package/out/PoolId.sol/PoolIdLibrary.json +1 -0
  139. package/out/Position.sol/Position.json +1 -0
  140. package/out/SafeCast.sol/SafeCast.json +1 -0
  141. package/out/SafeCast160.sol/SafeCast160.json +1 -0
  142. package/out/SafeERC20.sol/SafeERC20.json +1 -0
  143. package/out/SimpleAccessManaged.sol/SimpleAccessManaged.json +1 -0
  144. package/out/SimpleAccessManager.sol/SimpleAccessManager.json +1 -0
  145. package/out/SqrtPriceMath.sol/SqrtPriceMath.json +1 -0
  146. package/out/StateLibrary.sol/StateLibrary.json +1 -0
  147. package/out/SwapLimitOrders.sol/SwapLimitOrders.json +1 -0
  148. package/out/SwapWithLimitOrders.sol/SwapWithLimitOrders.json +1 -0
  149. package/out/TickBitmap.sol/TickBitmap.json +1 -0
  150. package/out/TickMath.sol/TickMath.json +1 -0
  151. package/out/TransientSlot.sol/TransientSlot.json +1 -0
  152. package/out/TransientStateLibrary.sol/TransientStateLibrary.json +1 -0
  153. package/out/UniV4SwapToCurrency.sol/UniV4SwapToCurrency.json +1 -0
  154. package/out/UnsafeMath.sol/UnsafeMath.json +1 -0
  155. package/out/V3ToV4SwapLib.sol/V3ToV4SwapLib.json +1 -0
  156. package/out/ZoraLimitOrderBook.sol/ZoraLimitOrderBook.json +1 -0
  157. package/out/build-info/69718f10d1dc37f0.json +1 -0
  158. package/out/uniswap/BitMath.sol/BitMath.json +1 -0
  159. package/out/uniswap/CustomRevert.sol/CustomRevert.json +1 -0
  160. package/out/uniswap/FullMath.sol/FullMath.json +1 -0
  161. package/out/uniswap/SafeCast.sol/SafeCast.json +1 -0
  162. package/out/uniswap/TickMath.sol/TickMath.json +1 -0
  163. package/package/index.ts +1 -0
  164. package/package/wagmiGenerated.ts +738 -0
  165. package/package.json +57 -0
  166. package/remappings.txt +11 -0
  167. package/src/IZoraLimitOrderBook.sol +195 -0
  168. package/src/ZoraLimitOrderBook.sol +220 -0
  169. package/src/access/SimpleAccessManaged.sol +76 -0
  170. package/src/access/SimpleAccessManager.sol +268 -0
  171. package/src/libs/LimitOrderBitmap.sol +84 -0
  172. package/src/libs/LimitOrderCommon.sol +91 -0
  173. package/src/libs/LimitOrderCreate.sol +277 -0
  174. package/src/libs/LimitOrderFill.sol +362 -0
  175. package/src/libs/LimitOrderLiquidity.sol +222 -0
  176. package/src/libs/LimitOrderQueues.sol +101 -0
  177. package/src/libs/LimitOrderStorage.sol +34 -0
  178. package/src/libs/LimitOrderTypes.sol +41 -0
  179. package/src/libs/LimitOrderWithdraw.sol +100 -0
  180. package/src/libs/Permit2Payments.sol +41 -0
  181. package/src/libs/SwapLimitOrders.sol +209 -0
  182. package/src/router/SwapWithLimitOrders.sol +454 -0
  183. package/test/LimitOrderAccessControl.t.sol +461 -0
  184. package/test/LimitOrderBitmap.t.sol +194 -0
  185. package/test/LimitOrderCreate.t.sol +348 -0
  186. package/test/LimitOrderFill.t.sol +1005 -0
  187. package/test/LimitOrderLibraries.t.sol +354 -0
  188. package/test/LimitOrderLiquidityPayouts.t.sol +333 -0
  189. package/test/LimitOrderV4Pools.t.sol +157 -0
  190. package/test/LimitOrderWithdraw.t.sol +653 -0
  191. package/test/SimpleAccessManager.t.sol +420 -0
  192. package/test/SwapWithLimitOrders.t.sol +107 -0
  193. package/test/SwapWithLimitOrdersRouter.t.sol +1073 -0
  194. package/test/gas/LimitOrderFillGas.t.sol +1008 -0
  195. package/test/gas/LimitOrderSwapGas.t.sol +403 -0
  196. package/test/gas/logs/gas_benchmarks_fill_20251201.log +30 -0
  197. package/test/gas/logs/gas_benchmarks_swap_20251201.log +27 -0
  198. package/test/unit/LimitOrderBitmapUnit.t.sol +276 -0
  199. package/test/unit/LimitOrderCreateUnit.t.sol +358 -0
  200. package/test/unit/SwapLimitOrdersUnit.t.sol +672 -0
  201. package/test/unit/SwapLimitOrdersValidation.t.sol +423 -0
  202. package/test/unit/SwapWithLimitOrdersUnit.t.sol +321 -0
  203. package/test/utils/BaseTest.sol +793 -0
  204. package/test/utils/TestableZoraLimitOrderBook.sol +54 -0
  205. package/tsconfig.build.json +10 -0
  206. package/tsconfig.json +9 -0
  207. package/tsup.config.ts +11 -0
  208. package/wagmi.config.ts +18 -0
@@ -0,0 +1,771 @@
1
+ [
2
+ {
3
+ "type": "constructor",
4
+ "inputs": [
5
+ {
6
+ "name": "poolManager_",
7
+ "type": "address",
8
+ "internalType": "address"
9
+ },
10
+ {
11
+ "name": "zoraCoinVersionLookup_",
12
+ "type": "address",
13
+ "internalType": "address"
14
+ },
15
+ {
16
+ "name": "zoraHookRegistry_",
17
+ "type": "address",
18
+ "internalType": "address"
19
+ },
20
+ {
21
+ "name": "authority_",
22
+ "type": "address",
23
+ "internalType": "address"
24
+ }
25
+ ],
26
+ "stateMutability": "nonpayable"
27
+ },
28
+ {
29
+ "type": "receive",
30
+ "stateMutability": "payable"
31
+ },
32
+ {
33
+ "type": "function",
34
+ "name": "authority",
35
+ "inputs": [],
36
+ "outputs": [
37
+ {
38
+ "name": "",
39
+ "type": "address",
40
+ "internalType": "address"
41
+ }
42
+ ],
43
+ "stateMutability": "view"
44
+ },
45
+ {
46
+ "type": "function",
47
+ "name": "balanceOf",
48
+ "inputs": [
49
+ {
50
+ "name": "maker",
51
+ "type": "address",
52
+ "internalType": "address"
53
+ },
54
+ {
55
+ "name": "coin",
56
+ "type": "address",
57
+ "internalType": "address"
58
+ }
59
+ ],
60
+ "outputs": [
61
+ {
62
+ "name": "",
63
+ "type": "uint256",
64
+ "internalType": "uint256"
65
+ }
66
+ ],
67
+ "stateMutability": "view"
68
+ },
69
+ {
70
+ "type": "function",
71
+ "name": "create",
72
+ "inputs": [
73
+ {
74
+ "name": "key",
75
+ "type": "tuple",
76
+ "internalType": "struct PoolKey",
77
+ "components": [
78
+ {
79
+ "name": "currency0",
80
+ "type": "address",
81
+ "internalType": "Currency"
82
+ },
83
+ {
84
+ "name": "currency1",
85
+ "type": "address",
86
+ "internalType": "Currency"
87
+ },
88
+ {
89
+ "name": "fee",
90
+ "type": "uint24",
91
+ "internalType": "uint24"
92
+ },
93
+ {
94
+ "name": "tickSpacing",
95
+ "type": "int24",
96
+ "internalType": "int24"
97
+ },
98
+ {
99
+ "name": "hooks",
100
+ "type": "address",
101
+ "internalType": "contract IHooks"
102
+ }
103
+ ]
104
+ },
105
+ {
106
+ "name": "isCurrency0",
107
+ "type": "bool",
108
+ "internalType": "bool"
109
+ },
110
+ {
111
+ "name": "orderSizes",
112
+ "type": "uint256[]",
113
+ "internalType": "uint256[]"
114
+ },
115
+ {
116
+ "name": "orderTicks",
117
+ "type": "int24[]",
118
+ "internalType": "int24[]"
119
+ },
120
+ {
121
+ "name": "maker",
122
+ "type": "address",
123
+ "internalType": "address"
124
+ }
125
+ ],
126
+ "outputs": [
127
+ {
128
+ "name": "",
129
+ "type": "bytes32[]",
130
+ "internalType": "bytes32[]"
131
+ }
132
+ ],
133
+ "stateMutability": "payable"
134
+ },
135
+ {
136
+ "type": "function",
137
+ "name": "fill",
138
+ "inputs": [
139
+ {
140
+ "name": "key",
141
+ "type": "tuple",
142
+ "internalType": "struct PoolKey",
143
+ "components": [
144
+ {
145
+ "name": "currency0",
146
+ "type": "address",
147
+ "internalType": "Currency"
148
+ },
149
+ {
150
+ "name": "currency1",
151
+ "type": "address",
152
+ "internalType": "Currency"
153
+ },
154
+ {
155
+ "name": "fee",
156
+ "type": "uint24",
157
+ "internalType": "uint24"
158
+ },
159
+ {
160
+ "name": "tickSpacing",
161
+ "type": "int24",
162
+ "internalType": "int24"
163
+ },
164
+ {
165
+ "name": "hooks",
166
+ "type": "address",
167
+ "internalType": "contract IHooks"
168
+ }
169
+ ]
170
+ },
171
+ {
172
+ "name": "isCurrency0",
173
+ "type": "bool",
174
+ "internalType": "bool"
175
+ },
176
+ {
177
+ "name": "startTick",
178
+ "type": "int24",
179
+ "internalType": "int24"
180
+ },
181
+ {
182
+ "name": "endTick",
183
+ "type": "int24",
184
+ "internalType": "int24"
185
+ },
186
+ {
187
+ "name": "maxFillCount",
188
+ "type": "uint256",
189
+ "internalType": "uint256"
190
+ },
191
+ {
192
+ "name": "fillReferral",
193
+ "type": "address",
194
+ "internalType": "address"
195
+ }
196
+ ],
197
+ "outputs": [],
198
+ "stateMutability": "nonpayable"
199
+ },
200
+ {
201
+ "type": "function",
202
+ "name": "fill",
203
+ "inputs": [
204
+ {
205
+ "name": "batches",
206
+ "type": "tuple[]",
207
+ "internalType": "struct IZoraLimitOrderBook.OrderBatch[]",
208
+ "components": [
209
+ {
210
+ "name": "key",
211
+ "type": "tuple",
212
+ "internalType": "struct PoolKey",
213
+ "components": [
214
+ {
215
+ "name": "currency0",
216
+ "type": "address",
217
+ "internalType": "Currency"
218
+ },
219
+ {
220
+ "name": "currency1",
221
+ "type": "address",
222
+ "internalType": "Currency"
223
+ },
224
+ {
225
+ "name": "fee",
226
+ "type": "uint24",
227
+ "internalType": "uint24"
228
+ },
229
+ {
230
+ "name": "tickSpacing",
231
+ "type": "int24",
232
+ "internalType": "int24"
233
+ },
234
+ {
235
+ "name": "hooks",
236
+ "type": "address",
237
+ "internalType": "contract IHooks"
238
+ }
239
+ ]
240
+ },
241
+ {
242
+ "name": "isCurrency0",
243
+ "type": "bool",
244
+ "internalType": "bool"
245
+ },
246
+ {
247
+ "name": "orderIds",
248
+ "type": "bytes32[]",
249
+ "internalType": "bytes32[]"
250
+ }
251
+ ]
252
+ },
253
+ {
254
+ "name": "fillReferral",
255
+ "type": "address",
256
+ "internalType": "address"
257
+ }
258
+ ],
259
+ "outputs": [],
260
+ "stateMutability": "nonpayable"
261
+ },
262
+ {
263
+ "type": "function",
264
+ "name": "getMaxFillCount",
265
+ "inputs": [],
266
+ "outputs": [
267
+ {
268
+ "name": "",
269
+ "type": "uint256",
270
+ "internalType": "uint256"
271
+ }
272
+ ],
273
+ "stateMutability": "view"
274
+ },
275
+ {
276
+ "type": "function",
277
+ "name": "poolManager",
278
+ "inputs": [],
279
+ "outputs": [
280
+ {
281
+ "name": "",
282
+ "type": "address",
283
+ "internalType": "contract IPoolManager"
284
+ }
285
+ ],
286
+ "stateMutability": "view"
287
+ },
288
+ {
289
+ "type": "function",
290
+ "name": "setAuthority",
291
+ "inputs": [
292
+ {
293
+ "name": "newAuthority",
294
+ "type": "address",
295
+ "internalType": "address"
296
+ }
297
+ ],
298
+ "outputs": [],
299
+ "stateMutability": "nonpayable"
300
+ },
301
+ {
302
+ "type": "function",
303
+ "name": "setMaxFillCount",
304
+ "inputs": [
305
+ {
306
+ "name": "maxFillCount",
307
+ "type": "uint256",
308
+ "internalType": "uint256"
309
+ }
310
+ ],
311
+ "outputs": [],
312
+ "stateMutability": "nonpayable"
313
+ },
314
+ {
315
+ "type": "function",
316
+ "name": "unlockCallback",
317
+ "inputs": [
318
+ {
319
+ "name": "data",
320
+ "type": "bytes",
321
+ "internalType": "bytes"
322
+ }
323
+ ],
324
+ "outputs": [
325
+ {
326
+ "name": "",
327
+ "type": "bytes",
328
+ "internalType": "bytes"
329
+ }
330
+ ],
331
+ "stateMutability": "nonpayable"
332
+ },
333
+ {
334
+ "type": "function",
335
+ "name": "withdraw",
336
+ "inputs": [
337
+ {
338
+ "name": "orderIds",
339
+ "type": "bytes32[]",
340
+ "internalType": "bytes32[]"
341
+ },
342
+ {
343
+ "name": "coin",
344
+ "type": "address",
345
+ "internalType": "address"
346
+ },
347
+ {
348
+ "name": "minAmountOut",
349
+ "type": "uint256",
350
+ "internalType": "uint256"
351
+ },
352
+ {
353
+ "name": "recipient",
354
+ "type": "address",
355
+ "internalType": "address"
356
+ }
357
+ ],
358
+ "outputs": [],
359
+ "stateMutability": "nonpayable"
360
+ },
361
+ {
362
+ "type": "function",
363
+ "name": "zoraCoinVersionLookup",
364
+ "inputs": [],
365
+ "outputs": [
366
+ {
367
+ "name": "",
368
+ "type": "address",
369
+ "internalType": "contract IDeployedCoinVersionLookup"
370
+ }
371
+ ],
372
+ "stateMutability": "view"
373
+ },
374
+ {
375
+ "type": "function",
376
+ "name": "zoraHookRegistry",
377
+ "inputs": [],
378
+ "outputs": [
379
+ {
380
+ "name": "",
381
+ "type": "address",
382
+ "internalType": "contract IZoraHookRegistry"
383
+ }
384
+ ],
385
+ "stateMutability": "view"
386
+ },
387
+ {
388
+ "type": "event",
389
+ "name": "AuthorityUpdated",
390
+ "inputs": [
391
+ {
392
+ "name": "authority",
393
+ "type": "address",
394
+ "indexed": false,
395
+ "internalType": "address"
396
+ }
397
+ ],
398
+ "anonymous": false
399
+ },
400
+ {
401
+ "type": "event",
402
+ "name": "LimitOrderCreated",
403
+ "inputs": [
404
+ {
405
+ "name": "maker",
406
+ "type": "address",
407
+ "indexed": true,
408
+ "internalType": "address"
409
+ },
410
+ {
411
+ "name": "coin",
412
+ "type": "address",
413
+ "indexed": true,
414
+ "internalType": "address"
415
+ },
416
+ {
417
+ "name": "poolKeyHash",
418
+ "type": "bytes32",
419
+ "indexed": false,
420
+ "internalType": "bytes32"
421
+ },
422
+ {
423
+ "name": "isCurrency0",
424
+ "type": "bool",
425
+ "indexed": false,
426
+ "internalType": "bool"
427
+ },
428
+ {
429
+ "name": "orderTick",
430
+ "type": "int24",
431
+ "indexed": false,
432
+ "internalType": "int24"
433
+ },
434
+ {
435
+ "name": "currentTick",
436
+ "type": "int24",
437
+ "indexed": false,
438
+ "internalType": "int24"
439
+ },
440
+ {
441
+ "name": "orderSize",
442
+ "type": "uint128",
443
+ "indexed": false,
444
+ "internalType": "uint128"
445
+ },
446
+ {
447
+ "name": "orderId",
448
+ "type": "bytes32",
449
+ "indexed": false,
450
+ "internalType": "bytes32"
451
+ }
452
+ ],
453
+ "anonymous": false
454
+ },
455
+ {
456
+ "type": "event",
457
+ "name": "LimitOrderFilled",
458
+ "inputs": [
459
+ {
460
+ "name": "maker",
461
+ "type": "address",
462
+ "indexed": true,
463
+ "internalType": "address"
464
+ },
465
+ {
466
+ "name": "coinIn",
467
+ "type": "address",
468
+ "indexed": true,
469
+ "internalType": "address"
470
+ },
471
+ {
472
+ "name": "coinOut",
473
+ "type": "address",
474
+ "indexed": false,
475
+ "internalType": "address"
476
+ },
477
+ {
478
+ "name": "amountIn",
479
+ "type": "uint128",
480
+ "indexed": false,
481
+ "internalType": "uint128"
482
+ },
483
+ {
484
+ "name": "amountOut",
485
+ "type": "uint128",
486
+ "indexed": false,
487
+ "internalType": "uint128"
488
+ },
489
+ {
490
+ "name": "fillReferral",
491
+ "type": "address",
492
+ "indexed": false,
493
+ "internalType": "address"
494
+ },
495
+ {
496
+ "name": "fillReferralAmount",
497
+ "type": "uint128",
498
+ "indexed": false,
499
+ "internalType": "uint128"
500
+ },
501
+ {
502
+ "name": "poolKeyHash",
503
+ "type": "bytes32",
504
+ "indexed": false,
505
+ "internalType": "bytes32"
506
+ },
507
+ {
508
+ "name": "tick",
509
+ "type": "int24",
510
+ "indexed": false,
511
+ "internalType": "int24"
512
+ },
513
+ {
514
+ "name": "orderId",
515
+ "type": "bytes32",
516
+ "indexed": false,
517
+ "internalType": "bytes32"
518
+ }
519
+ ],
520
+ "anonymous": false
521
+ },
522
+ {
523
+ "type": "event",
524
+ "name": "LimitOrderUpdated",
525
+ "inputs": [
526
+ {
527
+ "name": "maker",
528
+ "type": "address",
529
+ "indexed": true,
530
+ "internalType": "address"
531
+ },
532
+ {
533
+ "name": "coin",
534
+ "type": "address",
535
+ "indexed": true,
536
+ "internalType": "address"
537
+ },
538
+ {
539
+ "name": "poolKeyHash",
540
+ "type": "bytes32",
541
+ "indexed": false,
542
+ "internalType": "bytes32"
543
+ },
544
+ {
545
+ "name": "isCurrency0",
546
+ "type": "bool",
547
+ "indexed": false,
548
+ "internalType": "bool"
549
+ },
550
+ {
551
+ "name": "tick",
552
+ "type": "int24",
553
+ "indexed": false,
554
+ "internalType": "int24"
555
+ },
556
+ {
557
+ "name": "orderSize",
558
+ "type": "uint128",
559
+ "indexed": false,
560
+ "internalType": "uint128"
561
+ },
562
+ {
563
+ "name": "orderId",
564
+ "type": "bytes32",
565
+ "indexed": false,
566
+ "internalType": "bytes32"
567
+ },
568
+ {
569
+ "name": "isCancelled",
570
+ "type": "bool",
571
+ "indexed": false,
572
+ "internalType": "bool"
573
+ }
574
+ ],
575
+ "anonymous": false
576
+ },
577
+ {
578
+ "type": "event",
579
+ "name": "MakerBalanceUpdated",
580
+ "inputs": [
581
+ {
582
+ "name": "maker",
583
+ "type": "address",
584
+ "indexed": true,
585
+ "internalType": "address"
586
+ },
587
+ {
588
+ "name": "coin",
589
+ "type": "address",
590
+ "indexed": true,
591
+ "internalType": "address"
592
+ },
593
+ {
594
+ "name": "newBalance",
595
+ "type": "uint256",
596
+ "indexed": false,
597
+ "internalType": "uint256"
598
+ }
599
+ ],
600
+ "anonymous": false
601
+ },
602
+ {
603
+ "type": "error",
604
+ "name": "AccessManagedInvalidAuthority",
605
+ "inputs": [
606
+ {
607
+ "name": "authority",
608
+ "type": "address",
609
+ "internalType": "address"
610
+ }
611
+ ]
612
+ },
613
+ {
614
+ "type": "error",
615
+ "name": "AccessManagedUnauthorized",
616
+ "inputs": []
617
+ },
618
+ {
619
+ "type": "error",
620
+ "name": "AddressZero",
621
+ "inputs": []
622
+ },
623
+ {
624
+ "type": "error",
625
+ "name": "ArrayLengthMismatch",
626
+ "inputs": []
627
+ },
628
+ {
629
+ "type": "error",
630
+ "name": "CoinMismatch",
631
+ "inputs": [
632
+ {
633
+ "name": "orderId",
634
+ "type": "bytes32",
635
+ "internalType": "bytes32"
636
+ },
637
+ {
638
+ "name": "expectedCoin",
639
+ "type": "address",
640
+ "internalType": "address"
641
+ },
642
+ {
643
+ "name": "actualCoin",
644
+ "type": "address",
645
+ "internalType": "address"
646
+ }
647
+ ]
648
+ },
649
+ {
650
+ "type": "error",
651
+ "name": "InsufficientForwardedFunds",
652
+ "inputs": []
653
+ },
654
+ {
655
+ "type": "error",
656
+ "name": "InsufficientTransferFunds",
657
+ "inputs": []
658
+ },
659
+ {
660
+ "type": "error",
661
+ "name": "InvalidFillWindow",
662
+ "inputs": [
663
+ {
664
+ "name": "startTick",
665
+ "type": "int24",
666
+ "internalType": "int24"
667
+ },
668
+ {
669
+ "name": "endTick",
670
+ "type": "int24",
671
+ "internalType": "int24"
672
+ },
673
+ {
674
+ "name": "isCurrency0",
675
+ "type": "bool",
676
+ "internalType": "bool"
677
+ }
678
+ ]
679
+ },
680
+ {
681
+ "type": "error",
682
+ "name": "InvalidOrder",
683
+ "inputs": []
684
+ },
685
+ {
686
+ "type": "error",
687
+ "name": "InvalidPoolKey",
688
+ "inputs": []
689
+ },
690
+ {
691
+ "type": "error",
692
+ "name": "MaxFillCountCannotBeZero",
693
+ "inputs": []
694
+ },
695
+ {
696
+ "type": "error",
697
+ "name": "MinAmountNotReached",
698
+ "inputs": [
699
+ {
700
+ "name": "withdrawn",
701
+ "type": "uint256",
702
+ "internalType": "uint256"
703
+ },
704
+ {
705
+ "name": "minAmountOut",
706
+ "type": "uint256",
707
+ "internalType": "uint256"
708
+ }
709
+ ]
710
+ },
711
+ {
712
+ "type": "error",
713
+ "name": "NativeValueMismatch",
714
+ "inputs": []
715
+ },
716
+ {
717
+ "type": "error",
718
+ "name": "NotPoolManager",
719
+ "inputs": []
720
+ },
721
+ {
722
+ "type": "error",
723
+ "name": "OnlyZoraHook",
724
+ "inputs": []
725
+ },
726
+ {
727
+ "type": "error",
728
+ "name": "OrderClosed",
729
+ "inputs": []
730
+ },
731
+ {
732
+ "type": "error",
733
+ "name": "OrderNotMaker",
734
+ "inputs": []
735
+ },
736
+ {
737
+ "type": "error",
738
+ "name": "PathMustHaveAtLeastOneStep",
739
+ "inputs": []
740
+ },
741
+ {
742
+ "type": "error",
743
+ "name": "RouterMsgSenderInvalid",
744
+ "inputs": []
745
+ },
746
+ {
747
+ "type": "error",
748
+ "name": "UnknownCallback",
749
+ "inputs": []
750
+ },
751
+ {
752
+ "type": "error",
753
+ "name": "UnlockedFillNotAllowed",
754
+ "inputs": []
755
+ },
756
+ {
757
+ "type": "error",
758
+ "name": "ZeroMaker",
759
+ "inputs": []
760
+ },
761
+ {
762
+ "type": "error",
763
+ "name": "ZeroOrderSize",
764
+ "inputs": []
765
+ },
766
+ {
767
+ "type": "error",
768
+ "name": "ZeroRealizedOrder",
769
+ "inputs": []
770
+ }
771
+ ]