@varla/sdk 1.11.4 → 1.14.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 (242) hide show
  1. package/AGENTS.md +82 -95
  2. package/CHANGELOG.md +367 -0
  3. package/LICENSE +21 -0
  4. package/README.md +227 -275
  5. package/dist/abi/full/OpinionCtfExecutionEngineAdapter.js +1 -0
  6. package/dist/abi/full/OpinionCtfExecutionEngineAdapter.js.map +1 -0
  7. package/dist/abi/full/OracleUpdaterRouter.d.ts +30 -9
  8. package/dist/abi/full/OracleUpdaterRouter.d.ts.map +1 -1
  9. package/dist/abi/full/OracleUpdaterRouter.js +37 -9
  10. package/dist/abi/full/OracleUpdaterRouter.js.map +1 -0
  11. package/dist/abi/full/PolymarketCtfAdapter.js +1 -0
  12. package/dist/abi/full/PolymarketCtfAdapter.js.map +1 -0
  13. package/dist/abi/full/VarlaAccessManager.js +1 -0
  14. package/dist/abi/full/VarlaAccessManager.js.map +1 -0
  15. package/dist/abi/full/VarlaConvertLiquidator.js +1 -0
  16. package/dist/abi/full/VarlaConvertLiquidator.js.map +1 -0
  17. package/dist/abi/full/VarlaCore.js +1 -0
  18. package/dist/abi/full/VarlaCore.js.map +1 -0
  19. package/dist/abi/full/VarlaInterestRateStrategy.js +1 -0
  20. package/dist/abi/full/VarlaInterestRateStrategy.js.map +1 -0
  21. package/dist/abi/full/VarlaLiquidator.d.ts +12 -0
  22. package/dist/abi/full/VarlaLiquidator.d.ts.map +1 -1
  23. package/dist/abi/full/VarlaLiquidator.js +17 -0
  24. package/dist/abi/full/VarlaLiquidator.js.map +1 -0
  25. package/dist/abi/full/VarlaMergeLiquidator.js +1 -0
  26. package/dist/abi/full/VarlaMergeLiquidator.js.map +1 -0
  27. package/dist/abi/full/VarlaOracle.js +1 -0
  28. package/dist/abi/full/VarlaOracle.js.map +1 -0
  29. package/dist/abi/full/VarlaPool.js +1 -0
  30. package/dist/abi/full/VarlaPool.js.map +1 -0
  31. package/dist/abi/full/VarlaProxyAdmin.js +1 -0
  32. package/dist/abi/full/VarlaProxyAdmin.js.map +1 -0
  33. package/dist/abi/index.js +1 -0
  34. package/dist/abi/index.js.map +1 -0
  35. package/dist/abi/subsets/VarlaOracle.registry.js +1 -0
  36. package/dist/abi/subsets/VarlaOracle.registry.js.map +1 -0
  37. package/dist/abi.js +1 -0
  38. package/dist/abi.js.map +1 -0
  39. package/dist/actions/admin.js +1 -0
  40. package/dist/actions/admin.js.map +1 -0
  41. package/dist/actions/core.js +1 -0
  42. package/dist/actions/core.js.map +1 -0
  43. package/dist/actions/erc1155.js +1 -0
  44. package/dist/actions/erc1155.js.map +1 -0
  45. package/dist/actions/erc20.js +1 -0
  46. package/dist/actions/erc20.js.map +1 -0
  47. package/dist/actions/index.d.ts +7 -7
  48. package/dist/actions/index.d.ts.map +1 -1
  49. package/dist/actions/index.js +8 -7
  50. package/dist/actions/index.js.map +1 -0
  51. package/dist/actions/liquidator.js +1 -0
  52. package/dist/actions/liquidator.js.map +1 -0
  53. package/dist/actions/oracle.d.ts +1 -2
  54. package/dist/actions/oracle.d.ts.map +1 -1
  55. package/dist/actions/oracle.js +1 -0
  56. package/dist/actions/oracle.js.map +1 -0
  57. package/dist/actions/oracleUpdaterRouter.d.ts +8 -1
  58. package/dist/actions/oracleUpdaterRouter.d.ts.map +1 -1
  59. package/dist/actions/oracleUpdaterRouter.js +14 -1
  60. package/dist/actions/oracleUpdaterRouter.js.map +1 -0
  61. package/dist/actions/pool.js +1 -0
  62. package/dist/actions/pool.js.map +1 -0
  63. package/dist/actions/rbac.js +1 -0
  64. package/dist/actions/rbac.js.map +1 -0
  65. package/dist/actions/tx.js +1 -0
  66. package/dist/actions/tx.js.map +1 -0
  67. package/dist/actions/utils.js +1 -0
  68. package/dist/actions/utils.js.map +1 -0
  69. package/dist/addresses/bsc.js +1 -0
  70. package/dist/addresses/bsc.js.map +1 -0
  71. package/dist/addresses/index.js +1 -0
  72. package/dist/addresses/index.js.map +1 -0
  73. package/dist/addresses/polygon.js +1 -0
  74. package/dist/addresses/polygon.js.map +1 -0
  75. package/dist/addresses.js +1 -0
  76. package/dist/addresses.js.map +1 -0
  77. package/dist/batch.js +1 -0
  78. package/dist/batch.js.map +1 -0
  79. package/dist/contracts.d.ts +1 -2
  80. package/dist/contracts.d.ts.map +1 -1
  81. package/dist/contracts.js +2 -2
  82. package/dist/contracts.js.map +1 -0
  83. package/dist/errors.d.ts +87 -0
  84. package/dist/errors.d.ts.map +1 -0
  85. package/dist/errors.js +240 -0
  86. package/dist/errors.js.map +1 -0
  87. package/dist/events/decode.js +1 -0
  88. package/dist/events/decode.js.map +1 -0
  89. package/dist/events/defs.js +1 -0
  90. package/dist/events/defs.js.map +1 -0
  91. package/dist/events/index.d.ts +3 -3
  92. package/dist/events/index.d.ts.map +1 -1
  93. package/dist/events/index.js +4 -3
  94. package/dist/events/index.js.map +1 -0
  95. package/dist/events/logs.js +1 -0
  96. package/dist/events/logs.js.map +1 -0
  97. package/dist/events/oracleRegistrySync.js +1 -0
  98. package/dist/events/oracleRegistrySync.js.map +1 -0
  99. package/dist/events/recent.d.ts +1 -1
  100. package/dist/events/recent.d.ts.map +1 -1
  101. package/dist/events/recent.js +2 -1
  102. package/dist/events/recent.js.map +1 -0
  103. package/dist/format.js +1 -0
  104. package/dist/format.js.map +1 -0
  105. package/dist/generated.d.ts +42 -9
  106. package/dist/generated.d.ts.map +1 -1
  107. package/dist/generated.js +1 -0
  108. package/dist/generated.js.map +1 -0
  109. package/dist/index.d.ts +6 -5
  110. package/dist/index.d.ts.map +1 -1
  111. package/dist/index.js +12 -9
  112. package/dist/index.js.map +1 -0
  113. package/dist/leverage/deleverageExecute.d.ts +36 -0
  114. package/dist/leverage/deleverageExecute.d.ts.map +1 -0
  115. package/dist/leverage/deleverageExecute.js +53 -0
  116. package/dist/leverage/deleverageExecute.js.map +1 -0
  117. package/dist/leverage/execute.d.ts +62 -0
  118. package/dist/leverage/execute.d.ts.map +1 -0
  119. package/dist/leverage/execute.js +84 -0
  120. package/dist/leverage/execute.js.map +1 -0
  121. package/dist/leverage/index.d.ts +32 -0
  122. package/dist/leverage/index.d.ts.map +1 -0
  123. package/dist/leverage/index.js +12 -0
  124. package/dist/leverage/index.js.map +1 -0
  125. package/dist/leverage/math.d.ts +119 -0
  126. package/dist/leverage/math.d.ts.map +1 -0
  127. package/dist/leverage/math.js +304 -0
  128. package/dist/leverage/math.js.map +1 -0
  129. package/dist/leverage/plan.d.ts +143 -0
  130. package/dist/leverage/plan.d.ts.map +1 -0
  131. package/dist/leverage/plan.js +204 -0
  132. package/dist/leverage/plan.js.map +1 -0
  133. package/dist/leverage/preflight.d.ts +27 -0
  134. package/dist/leverage/preflight.d.ts.map +1 -0
  135. package/dist/leverage/preflight.js +34 -0
  136. package/dist/leverage/preflight.js.map +1 -0
  137. package/dist/leverage/types.d.ts +157 -0
  138. package/dist/leverage/types.d.ts.map +1 -0
  139. package/dist/leverage/types.js +43 -0
  140. package/dist/leverage/types.js.map +1 -0
  141. package/dist/meta.d.ts +42 -0
  142. package/dist/meta.d.ts.map +1 -0
  143. package/dist/meta.js +47 -0
  144. package/dist/meta.js.map +1 -0
  145. package/dist/types.js +1 -0
  146. package/dist/types.js.map +1 -0
  147. package/dist/views/accessManager.js +1 -0
  148. package/dist/views/accessManager.js.map +1 -0
  149. package/dist/views/adapters.js +1 -0
  150. package/dist/views/adapters.js.map +1 -0
  151. package/dist/views/admin.d.ts.map +1 -1
  152. package/dist/views/admin.js +1 -0
  153. package/dist/views/admin.js.map +1 -0
  154. package/dist/views/core.d.ts.map +1 -1
  155. package/dist/views/core.js +1 -0
  156. package/dist/views/core.js.map +1 -0
  157. package/dist/views/index.d.ts +5 -5
  158. package/dist/views/index.d.ts.map +1 -1
  159. package/dist/views/index.js +6 -5
  160. package/dist/views/index.js.map +1 -0
  161. package/dist/views/lenders.js +1 -0
  162. package/dist/views/lenders.js.map +1 -0
  163. package/dist/views/liquidators.d.ts +82 -1
  164. package/dist/views/liquidators.d.ts.map +1 -1
  165. package/dist/views/liquidators.js +88 -0
  166. package/dist/views/liquidators.js.map +1 -0
  167. package/dist/views/oracle.js +1 -0
  168. package/dist/views/oracle.js.map +1 -0
  169. package/dist/views/pool.js +1 -0
  170. package/dist/views/pool.js.map +1 -0
  171. package/dist/views/system.d.ts.map +1 -1
  172. package/dist/views/system.js +1 -0
  173. package/dist/views/system.js.map +1 -0
  174. package/package.json +18 -5
  175. package/src/abi/README.md +17 -0
  176. package/src/abi/full/OpinionCtfExecutionEngineAdapter.ts +320 -0
  177. package/src/abi/full/OracleUpdaterRouter.ts +528 -0
  178. package/src/abi/full/PolymarketCtfAdapter.ts +312 -0
  179. package/src/abi/full/VarlaAccessManager.ts +1171 -0
  180. package/src/abi/full/VarlaConvertLiquidator.ts +834 -0
  181. package/src/abi/full/VarlaCore.ts +2277 -0
  182. package/src/abi/full/VarlaInterestRateStrategy.ts +442 -0
  183. package/src/abi/full/VarlaLiquidator.ts +930 -0
  184. package/src/abi/full/VarlaMergeLiquidator.ts +797 -0
  185. package/src/abi/full/VarlaOracle.ts +1825 -0
  186. package/src/abi/full/VarlaPool.ts +1637 -0
  187. package/src/abi/full/VarlaProxyAdmin.ts +301 -0
  188. package/src/abi/index.ts +17 -0
  189. package/src/abi/subsets/VarlaOracle.registry.ts +784 -0
  190. package/src/abi.ts +2 -0
  191. package/src/actions/admin.ts +357 -0
  192. package/src/actions/core.ts +68 -0
  193. package/src/actions/erc1155.ts +22 -0
  194. package/src/actions/erc20.ts +22 -0
  195. package/src/actions/index.ts +13 -0
  196. package/src/actions/liquidator.ts +76 -0
  197. package/src/actions/oracle.ts +618 -0
  198. package/src/actions/oracleUpdaterRouter.ts +233 -0
  199. package/src/actions/pool.ts +76 -0
  200. package/src/actions/rbac.ts +72 -0
  201. package/src/actions/tx.ts +16 -0
  202. package/src/actions/utils.ts +15 -0
  203. package/src/addresses/README.md +17 -0
  204. package/src/addresses/bsc.json +16 -0
  205. package/src/addresses/bsc.ts +15 -0
  206. package/src/addresses/index.ts +6 -0
  207. package/src/addresses/polygon.json +16 -0
  208. package/src/addresses/polygon.ts +15 -0
  209. package/src/addresses.ts +2 -0
  210. package/src/batch.ts +55 -0
  211. package/src/contracts.ts +232 -0
  212. package/src/errors.ts +305 -0
  213. package/src/events/decode.ts +37 -0
  214. package/src/events/defs.ts +70 -0
  215. package/src/events/index.ts +7 -0
  216. package/src/events/logs.ts +42 -0
  217. package/src/events/oracleRegistrySync.ts +206 -0
  218. package/src/events/recent.ts +39 -0
  219. package/src/format.ts +121 -0
  220. package/src/generated.ts +27 -0
  221. package/src/index.ts +18 -0
  222. package/src/leverage/deleverageExecute.ts +111 -0
  223. package/src/leverage/execute.ts +172 -0
  224. package/src/leverage/index.ts +88 -0
  225. package/src/leverage/math.ts +446 -0
  226. package/src/leverage/plan.ts +356 -0
  227. package/src/leverage/preflight.ts +63 -0
  228. package/src/leverage/types.ts +204 -0
  229. package/src/meta.ts +82 -0
  230. package/src/types.ts +25 -0
  231. package/src/views/accessManager.ts +286 -0
  232. package/src/views/adapters.ts +27 -0
  233. package/src/views/admin.ts +92 -0
  234. package/src/views/core.ts +1370 -0
  235. package/src/views/index.ts +11 -0
  236. package/src/views/lenders.ts +65 -0
  237. package/src/views/liquidators.ts +377 -0
  238. package/src/views/oracle.ts +739 -0
  239. package/src/views/pool.ts +277 -0
  240. package/src/views/system.ts +42 -0
  241. package/BACKEND.md +0 -405
  242. package/FRONTEND.md +0 -485
@@ -0,0 +1,2277 @@
1
+ // Auto-generated by varla-protocol/scripts/export-abi.ts
2
+ // Do not edit manually.
3
+ import type { Abi } from "viem";
4
+
5
+ export const VARLACORE_ABI = [
6
+ {
7
+ "inputs": [
8
+ {
9
+ "internalType": "address",
10
+ "name": "_positionsToken",
11
+ "type": "address"
12
+ },
13
+ {
14
+ "internalType": "address",
15
+ "name": "_collateralToken",
16
+ "type": "address"
17
+ },
18
+ {
19
+ "internalType": "address",
20
+ "name": "_pool",
21
+ "type": "address"
22
+ },
23
+ {
24
+ "internalType": "address",
25
+ "name": "_oracle",
26
+ "type": "address"
27
+ },
28
+ {
29
+ "internalType": "address",
30
+ "name": "_authority",
31
+ "type": "address"
32
+ }
33
+ ],
34
+ "stateMutability": "nonpayable",
35
+ "type": "constructor"
36
+ },
37
+ {
38
+ "inputs": [
39
+ {
40
+ "internalType": "address",
41
+ "name": "authority",
42
+ "type": "address"
43
+ }
44
+ ],
45
+ "name": "AccessManagedInvalidAuthority",
46
+ "type": "error"
47
+ },
48
+ {
49
+ "inputs": [
50
+ {
51
+ "internalType": "address",
52
+ "name": "caller",
53
+ "type": "address"
54
+ },
55
+ {
56
+ "internalType": "uint32",
57
+ "name": "delay",
58
+ "type": "uint32"
59
+ }
60
+ ],
61
+ "name": "AccessManagedRequiredDelay",
62
+ "type": "error"
63
+ },
64
+ {
65
+ "inputs": [
66
+ {
67
+ "internalType": "address",
68
+ "name": "caller",
69
+ "type": "address"
70
+ }
71
+ ],
72
+ "name": "AccessManagedUnauthorized",
73
+ "type": "error"
74
+ },
75
+ {
76
+ "inputs": [
77
+ {
78
+ "internalType": "uint256",
79
+ "name": "amount",
80
+ "type": "uint256"
81
+ },
82
+ {
83
+ "internalType": "uint256",
84
+ "name": "debt",
85
+ "type": "uint256"
86
+ }
87
+ ],
88
+ "name": "AmountExceedsDebt",
89
+ "type": "error"
90
+ },
91
+ {
92
+ "inputs": [],
93
+ "name": "ArrayLengthMismatch",
94
+ "type": "error"
95
+ },
96
+ {
97
+ "inputs": [
98
+ {
99
+ "internalType": "uint256",
100
+ "name": "amount",
101
+ "type": "uint256"
102
+ }
103
+ ],
104
+ "name": "BelowMinBorrow",
105
+ "type": "error"
106
+ },
107
+ {
108
+ "inputs": [
109
+ {
110
+ "internalType": "uint256",
111
+ "name": "expected",
112
+ "type": "uint256"
113
+ },
114
+ {
115
+ "internalType": "uint256",
116
+ "name": "actual",
117
+ "type": "uint256"
118
+ }
119
+ ],
120
+ "name": "DebtChanged",
121
+ "type": "error"
122
+ },
123
+ {
124
+ "inputs": [
125
+ {
126
+ "internalType": "uint256",
127
+ "name": "positionId",
128
+ "type": "uint256"
129
+ }
130
+ ],
131
+ "name": "DepositNotAllowed",
132
+ "type": "error"
133
+ },
134
+ {
135
+ "inputs": [],
136
+ "name": "EmptyDeposit",
137
+ "type": "error"
138
+ },
139
+ {
140
+ "inputs": [
141
+ {
142
+ "internalType": "uint256",
143
+ "name": "requested",
144
+ "type": "uint256"
145
+ },
146
+ {
147
+ "internalType": "uint256",
148
+ "name": "maxBorrow",
149
+ "type": "uint256"
150
+ }
151
+ ],
152
+ "name": "ExceedsMaxBorrow",
153
+ "type": "error"
154
+ },
155
+ {
156
+ "inputs": [
157
+ {
158
+ "internalType": "uint256",
159
+ "name": "positionId",
160
+ "type": "uint256"
161
+ },
162
+ {
163
+ "internalType": "uint256",
164
+ "name": "requested",
165
+ "type": "uint256"
166
+ },
167
+ {
168
+ "internalType": "uint256",
169
+ "name": "available",
170
+ "type": "uint256"
171
+ }
172
+ ],
173
+ "name": "InsufficientBalance",
174
+ "type": "error"
175
+ },
176
+ {
177
+ "inputs": [],
178
+ "name": "InvalidAddress",
179
+ "type": "error"
180
+ },
181
+ {
182
+ "inputs": [
183
+ {
184
+ "internalType": "uint256",
185
+ "name": "positionId",
186
+ "type": "uint256"
187
+ }
188
+ ],
189
+ "name": "InvalidCollateral",
190
+ "type": "error"
191
+ },
192
+ {
193
+ "inputs": [
194
+ {
195
+ "internalType": "uint8",
196
+ "name": "tier",
197
+ "type": "uint8"
198
+ },
199
+ {
200
+ "internalType": "uint256",
201
+ "name": "ltvWad",
202
+ "type": "uint256"
203
+ },
204
+ {
205
+ "internalType": "uint256",
206
+ "name": "maxBonusBps",
207
+ "type": "uint256"
208
+ }
209
+ ],
210
+ "name": "InvalidCollateralFactorAndMaxLiquidationBonus",
211
+ "type": "error"
212
+ },
213
+ {
214
+ "inputs": [],
215
+ "name": "InvalidLiquidationConfig",
216
+ "type": "error"
217
+ },
218
+ {
219
+ "inputs": [
220
+ {
221
+ "internalType": "uint256",
222
+ "name": "feeBps",
223
+ "type": "uint256"
224
+ }
225
+ ],
226
+ "name": "InvalidLiquidationFee",
227
+ "type": "error"
228
+ },
229
+ {
230
+ "inputs": [
231
+ {
232
+ "internalType": "uint256",
233
+ "name": "ltv",
234
+ "type": "uint256"
235
+ }
236
+ ],
237
+ "name": "InvalidLtv",
238
+ "type": "error"
239
+ },
240
+ {
241
+ "inputs": [
242
+ {
243
+ "internalType": "uint256",
244
+ "name": "conservative",
245
+ "type": "uint256"
246
+ },
247
+ {
248
+ "internalType": "uint256",
249
+ "name": "moderate",
250
+ "type": "uint256"
251
+ },
252
+ {
253
+ "internalType": "uint256",
254
+ "name": "risk",
255
+ "type": "uint256"
256
+ }
257
+ ],
258
+ "name": "InvalidLtvConfig",
259
+ "type": "error"
260
+ },
261
+ {
262
+ "inputs": [
263
+ {
264
+ "internalType": "uint256",
265
+ "name": "value",
266
+ "type": "uint256"
267
+ },
268
+ {
269
+ "internalType": "uint256",
270
+ "name": "min",
271
+ "type": "uint256"
272
+ },
273
+ {
274
+ "internalType": "uint256",
275
+ "name": "max",
276
+ "type": "uint256"
277
+ }
278
+ ],
279
+ "name": "InvalidMaxPositions",
280
+ "type": "error"
281
+ },
282
+ {
283
+ "inputs": [
284
+ {
285
+ "internalType": "uint256",
286
+ "name": "min",
287
+ "type": "uint256"
288
+ },
289
+ {
290
+ "internalType": "uint256",
291
+ "name": "max",
292
+ "type": "uint256"
293
+ }
294
+ ],
295
+ "name": "InvalidMaxPositionsBounds",
296
+ "type": "error"
297
+ },
298
+ {
299
+ "inputs": [
300
+ {
301
+ "internalType": "uint8",
302
+ "name": "tier",
303
+ "type": "uint8"
304
+ }
305
+ ],
306
+ "name": "InvalidTier",
307
+ "type": "error"
308
+ },
309
+ {
310
+ "inputs": [],
311
+ "name": "LiquidationBlockedByOracleGuards",
312
+ "type": "error"
313
+ },
314
+ {
315
+ "inputs": [
316
+ {
317
+ "internalType": "uint256",
318
+ "name": "positionId",
319
+ "type": "uint256"
320
+ },
321
+ {
322
+ "internalType": "uint256",
323
+ "name": "provided",
324
+ "type": "uint256"
325
+ },
326
+ {
327
+ "internalType": "uint256",
328
+ "name": "maxAllowed",
329
+ "type": "uint256"
330
+ }
331
+ ],
332
+ "name": "LiquidationOverrideMustOnlyLowerBonus",
333
+ "type": "error"
334
+ },
335
+ {
336
+ "inputs": [
337
+ {
338
+ "internalType": "uint256",
339
+ "name": "positionId",
340
+ "type": "uint256"
341
+ },
342
+ {
343
+ "internalType": "uint256",
344
+ "name": "provided",
345
+ "type": "uint256"
346
+ },
347
+ {
348
+ "internalType": "uint256",
349
+ "name": "maxAllowed",
350
+ "type": "uint256"
351
+ }
352
+ ],
353
+ "name": "LtvOverrideMustOnlyLower",
354
+ "type": "error"
355
+ },
356
+ {
357
+ "inputs": [],
358
+ "name": "NoDebt",
359
+ "type": "error"
360
+ },
361
+ {
362
+ "inputs": [
363
+ {
364
+ "internalType": "uint256",
365
+ "name": "healthFactor",
366
+ "type": "uint256"
367
+ }
368
+ ],
369
+ "name": "NotLiquidatable",
370
+ "type": "error"
371
+ },
372
+ {
373
+ "inputs": [
374
+ {
375
+ "internalType": "uint256",
376
+ "name": "positionId",
377
+ "type": "uint256"
378
+ },
379
+ {
380
+ "internalType": "uint256",
381
+ "name": "until",
382
+ "type": "uint256"
383
+ }
384
+ ],
385
+ "name": "OracleGracePeriodActive",
386
+ "type": "error"
387
+ },
388
+ {
389
+ "inputs": [
390
+ {
391
+ "internalType": "uint256",
392
+ "name": "positionId",
393
+ "type": "uint256"
394
+ }
395
+ ],
396
+ "name": "OraclePriceUnavailableForLiquidation",
397
+ "type": "error"
398
+ },
399
+ {
400
+ "inputs": [],
401
+ "name": "ReentrancyGuardReentrantCall",
402
+ "type": "error"
403
+ },
404
+ {
405
+ "inputs": [
406
+ {
407
+ "internalType": "uint256",
408
+ "name": "remainingDebt",
409
+ "type": "uint256"
410
+ }
411
+ ],
412
+ "name": "RemainingDebtBelowMinBorrow",
413
+ "type": "error"
414
+ },
415
+ {
416
+ "inputs": [
417
+ {
418
+ "internalType": "uint256",
419
+ "name": "amount",
420
+ "type": "uint256"
421
+ },
422
+ {
423
+ "internalType": "uint256",
424
+ "name": "currentIndex",
425
+ "type": "uint256"
426
+ }
427
+ ],
428
+ "name": "RepayAmountTooSmall",
429
+ "type": "error"
430
+ },
431
+ {
432
+ "inputs": [
433
+ {
434
+ "internalType": "uint256",
435
+ "name": "amount",
436
+ "type": "uint256"
437
+ },
438
+ {
439
+ "internalType": "uint256",
440
+ "name": "totalOwed",
441
+ "type": "uint256"
442
+ }
443
+ ],
444
+ "name": "RepayingTooMuch",
445
+ "type": "error"
446
+ },
447
+ {
448
+ "inputs": [
449
+ {
450
+ "internalType": "address",
451
+ "name": "token",
452
+ "type": "address"
453
+ }
454
+ ],
455
+ "name": "SafeERC20FailedOperation",
456
+ "type": "error"
457
+ },
458
+ {
459
+ "inputs": [
460
+ {
461
+ "internalType": "uint256",
462
+ "name": "borrowedAt",
463
+ "type": "uint256"
464
+ },
465
+ {
466
+ "internalType": "uint256",
467
+ "name": "canRepayAt",
468
+ "type": "uint256"
469
+ }
470
+ ],
471
+ "name": "TooEarlyToRepay",
472
+ "type": "error"
473
+ },
474
+ {
475
+ "inputs": [
476
+ {
477
+ "internalType": "uint256",
478
+ "name": "current",
479
+ "type": "uint256"
480
+ },
481
+ {
482
+ "internalType": "uint256",
483
+ "name": "max",
484
+ "type": "uint256"
485
+ }
486
+ ],
487
+ "name": "TooManyPositions",
488
+ "type": "error"
489
+ },
490
+ {
491
+ "inputs": [],
492
+ "name": "WouldBeUndercollateralized",
493
+ "type": "error"
494
+ },
495
+ {
496
+ "inputs": [],
497
+ "name": "ZeroAmount",
498
+ "type": "error"
499
+ },
500
+ {
501
+ "anonymous": false,
502
+ "inputs": [
503
+ {
504
+ "indexed": false,
505
+ "internalType": "address",
506
+ "name": "authority",
507
+ "type": "address"
508
+ }
509
+ ],
510
+ "name": "AuthorityUpdated",
511
+ "type": "event"
512
+ },
513
+ {
514
+ "anonymous": false,
515
+ "inputs": [
516
+ {
517
+ "indexed": true,
518
+ "internalType": "address",
519
+ "name": "user",
520
+ "type": "address"
521
+ },
522
+ {
523
+ "indexed": false,
524
+ "internalType": "uint256",
525
+ "name": "scaledAmount",
526
+ "type": "uint256"
527
+ }
528
+ ],
529
+ "name": "BadDebtHandled",
530
+ "type": "event"
531
+ },
532
+ {
533
+ "anonymous": false,
534
+ "inputs": [
535
+ {
536
+ "indexed": true,
537
+ "internalType": "address",
538
+ "name": "user",
539
+ "type": "address"
540
+ },
541
+ {
542
+ "indexed": false,
543
+ "internalType": "uint256",
544
+ "name": "amount",
545
+ "type": "uint256"
546
+ },
547
+ {
548
+ "indexed": false,
549
+ "internalType": "uint256",
550
+ "name": "scaledAmount",
551
+ "type": "uint256"
552
+ }
553
+ ],
554
+ "name": "Borrow",
555
+ "type": "event"
556
+ },
557
+ {
558
+ "anonymous": false,
559
+ "inputs": [
560
+ {
561
+ "indexed": false,
562
+ "internalType": "uint256",
563
+ "name": "oldConservative",
564
+ "type": "uint256"
565
+ },
566
+ {
567
+ "indexed": false,
568
+ "internalType": "uint256",
569
+ "name": "oldModerate",
570
+ "type": "uint256"
571
+ },
572
+ {
573
+ "indexed": false,
574
+ "internalType": "uint256",
575
+ "name": "oldRisk",
576
+ "type": "uint256"
577
+ },
578
+ {
579
+ "indexed": false,
580
+ "internalType": "uint256",
581
+ "name": "newConservative",
582
+ "type": "uint256"
583
+ },
584
+ {
585
+ "indexed": false,
586
+ "internalType": "uint256",
587
+ "name": "newModerate",
588
+ "type": "uint256"
589
+ },
590
+ {
591
+ "indexed": false,
592
+ "internalType": "uint256",
593
+ "name": "newRisk",
594
+ "type": "uint256"
595
+ }
596
+ ],
597
+ "name": "DefaultLtvUpdated",
598
+ "type": "event"
599
+ },
600
+ {
601
+ "anonymous": false,
602
+ "inputs": [
603
+ {
604
+ "indexed": true,
605
+ "internalType": "address",
606
+ "name": "user",
607
+ "type": "address"
608
+ },
609
+ {
610
+ "indexed": false,
611
+ "internalType": "uint256[]",
612
+ "name": "positionIds",
613
+ "type": "uint256[]"
614
+ },
615
+ {
616
+ "indexed": false,
617
+ "internalType": "uint256[]",
618
+ "name": "amounts",
619
+ "type": "uint256[]"
620
+ }
621
+ ],
622
+ "name": "Deposit",
623
+ "type": "event"
624
+ },
625
+ {
626
+ "anonymous": false,
627
+ "inputs": [
628
+ {
629
+ "indexed": true,
630
+ "internalType": "address",
631
+ "name": "user",
632
+ "type": "address"
633
+ },
634
+ {
635
+ "indexed": true,
636
+ "internalType": "address",
637
+ "name": "liquidator",
638
+ "type": "address"
639
+ },
640
+ {
641
+ "indexed": false,
642
+ "internalType": "uint256[]",
643
+ "name": "positionIds",
644
+ "type": "uint256[]"
645
+ },
646
+ {
647
+ "indexed": false,
648
+ "internalType": "uint256[]",
649
+ "name": "amounts",
650
+ "type": "uint256[]"
651
+ },
652
+ {
653
+ "indexed": false,
654
+ "internalType": "uint256",
655
+ "name": "debtRepaid",
656
+ "type": "uint256"
657
+ }
658
+ ],
659
+ "name": "Liquidate",
660
+ "type": "event"
661
+ },
662
+ {
663
+ "anonymous": false,
664
+ "inputs": [
665
+ {
666
+ "indexed": false,
667
+ "internalType": "uint256",
668
+ "name": "targetHealthFactor",
669
+ "type": "uint256"
670
+ },
671
+ {
672
+ "indexed": false,
673
+ "internalType": "uint256",
674
+ "name": "healthFactorForMaxBonus",
675
+ "type": "uint256"
676
+ },
677
+ {
678
+ "indexed": false,
679
+ "internalType": "uint256",
680
+ "name": "liquidationBonusFactorBps",
681
+ "type": "uint256"
682
+ },
683
+ {
684
+ "indexed": false,
685
+ "internalType": "uint256",
686
+ "name": "dustThreshold",
687
+ "type": "uint256"
688
+ },
689
+ {
690
+ "indexed": false,
691
+ "internalType": "uint256",
692
+ "name": "collateralDustThreshold",
693
+ "type": "uint256"
694
+ }
695
+ ],
696
+ "name": "LiquidationConfigUpdated",
697
+ "type": "event"
698
+ },
699
+ {
700
+ "anonymous": false,
701
+ "inputs": [
702
+ {
703
+ "indexed": true,
704
+ "internalType": "address",
705
+ "name": "user",
706
+ "type": "address"
707
+ },
708
+ {
709
+ "indexed": true,
710
+ "internalType": "address",
711
+ "name": "liquidator",
712
+ "type": "address"
713
+ },
714
+ {
715
+ "indexed": false,
716
+ "internalType": "uint256",
717
+ "name": "amount",
718
+ "type": "uint256"
719
+ },
720
+ {
721
+ "indexed": false,
722
+ "internalType": "uint256",
723
+ "name": "scaledAmount",
724
+ "type": "uint256"
725
+ }
726
+ ],
727
+ "name": "LiquidationDebtRepaid",
728
+ "type": "event"
729
+ },
730
+ {
731
+ "anonymous": false,
732
+ "inputs": [
733
+ {
734
+ "indexed": false,
735
+ "internalType": "uint256",
736
+ "name": "oldMin",
737
+ "type": "uint256"
738
+ },
739
+ {
740
+ "indexed": false,
741
+ "internalType": "uint256",
742
+ "name": "oldMax",
743
+ "type": "uint256"
744
+ },
745
+ {
746
+ "indexed": false,
747
+ "internalType": "uint256",
748
+ "name": "newMin",
749
+ "type": "uint256"
750
+ },
751
+ {
752
+ "indexed": false,
753
+ "internalType": "uint256",
754
+ "name": "newMax",
755
+ "type": "uint256"
756
+ }
757
+ ],
758
+ "name": "MaxPositionsBoundsUpdated",
759
+ "type": "event"
760
+ },
761
+ {
762
+ "anonymous": false,
763
+ "inputs": [
764
+ {
765
+ "indexed": false,
766
+ "internalType": "uint256",
767
+ "name": "oldMax",
768
+ "type": "uint256"
769
+ },
770
+ {
771
+ "indexed": false,
772
+ "internalType": "uint256",
773
+ "name": "newMax",
774
+ "type": "uint256"
775
+ }
776
+ ],
777
+ "name": "MaxPositionsUpdated",
778
+ "type": "event"
779
+ },
780
+ {
781
+ "anonymous": false,
782
+ "inputs": [
783
+ {
784
+ "indexed": true,
785
+ "internalType": "address",
786
+ "name": "oldOracle",
787
+ "type": "address"
788
+ },
789
+ {
790
+ "indexed": true,
791
+ "internalType": "address",
792
+ "name": "newOracle",
793
+ "type": "address"
794
+ }
795
+ ],
796
+ "name": "OracleUpdated",
797
+ "type": "event"
798
+ },
799
+ {
800
+ "anonymous": false,
801
+ "inputs": [
802
+ {
803
+ "indexed": true,
804
+ "internalType": "uint256",
805
+ "name": "positionId",
806
+ "type": "uint256"
807
+ },
808
+ {
809
+ "indexed": false,
810
+ "internalType": "bool",
811
+ "name": "isSet",
812
+ "type": "bool"
813
+ },
814
+ {
815
+ "indexed": false,
816
+ "internalType": "uint256",
817
+ "name": "maxLiquidationBonusBps",
818
+ "type": "uint256"
819
+ },
820
+ {
821
+ "indexed": false,
822
+ "internalType": "uint256",
823
+ "name": "liquidationFeeBps",
824
+ "type": "uint256"
825
+ }
826
+ ],
827
+ "name": "PositionLiquidationConfigUpdated",
828
+ "type": "event"
829
+ },
830
+ {
831
+ "anonymous": false,
832
+ "inputs": [
833
+ {
834
+ "indexed": true,
835
+ "internalType": "uint256",
836
+ "name": "positionId",
837
+ "type": "uint256"
838
+ },
839
+ {
840
+ "indexed": false,
841
+ "internalType": "bool",
842
+ "name": "isSet",
843
+ "type": "bool"
844
+ },
845
+ {
846
+ "indexed": false,
847
+ "internalType": "uint256",
848
+ "name": "ltv",
849
+ "type": "uint256"
850
+ }
851
+ ],
852
+ "name": "PositionLtvOverrideUpdated",
853
+ "type": "event"
854
+ },
855
+ {
856
+ "anonymous": false,
857
+ "inputs": [
858
+ {
859
+ "indexed": true,
860
+ "internalType": "address",
861
+ "name": "user",
862
+ "type": "address"
863
+ },
864
+ {
865
+ "indexed": false,
866
+ "internalType": "uint256",
867
+ "name": "amount",
868
+ "type": "uint256"
869
+ },
870
+ {
871
+ "indexed": false,
872
+ "internalType": "uint256",
873
+ "name": "scaledAmount",
874
+ "type": "uint256"
875
+ }
876
+ ],
877
+ "name": "Repay",
878
+ "type": "event"
879
+ },
880
+ {
881
+ "anonymous": false,
882
+ "inputs": [
883
+ {
884
+ "indexed": true,
885
+ "internalType": "uint8",
886
+ "name": "tier",
887
+ "type": "uint8"
888
+ },
889
+ {
890
+ "indexed": false,
891
+ "internalType": "uint256",
892
+ "name": "maxLiquidationBonusBps",
893
+ "type": "uint256"
894
+ },
895
+ {
896
+ "indexed": false,
897
+ "internalType": "uint256",
898
+ "name": "liquidationFeeBps",
899
+ "type": "uint256"
900
+ }
901
+ ],
902
+ "name": "TierLiquidationConfigUpdated",
903
+ "type": "event"
904
+ },
905
+ {
906
+ "anonymous": false,
907
+ "inputs": [
908
+ {
909
+ "indexed": true,
910
+ "internalType": "address",
911
+ "name": "user",
912
+ "type": "address"
913
+ },
914
+ {
915
+ "indexed": false,
916
+ "internalType": "uint256[]",
917
+ "name": "positionIds",
918
+ "type": "uint256[]"
919
+ },
920
+ {
921
+ "indexed": false,
922
+ "internalType": "uint256[]",
923
+ "name": "amounts",
924
+ "type": "uint256[]"
925
+ }
926
+ ],
927
+ "name": "Withdraw",
928
+ "type": "event"
929
+ },
930
+ {
931
+ "inputs": [],
932
+ "name": "BPS",
933
+ "outputs": [
934
+ {
935
+ "internalType": "uint256",
936
+ "name": "",
937
+ "type": "uint256"
938
+ }
939
+ ],
940
+ "stateMutability": "view",
941
+ "type": "function"
942
+ },
943
+ {
944
+ "inputs": [],
945
+ "name": "DEFAULT_MAX_POSITIONS",
946
+ "outputs": [
947
+ {
948
+ "internalType": "uint256",
949
+ "name": "",
950
+ "type": "uint256"
951
+ }
952
+ ],
953
+ "stateMutability": "view",
954
+ "type": "function"
955
+ },
956
+ {
957
+ "inputs": [],
958
+ "name": "LIQUIDATION_THRESHOLD",
959
+ "outputs": [
960
+ {
961
+ "internalType": "uint256",
962
+ "name": "",
963
+ "type": "uint256"
964
+ }
965
+ ],
966
+ "stateMutability": "view",
967
+ "type": "function"
968
+ },
969
+ {
970
+ "inputs": [],
971
+ "name": "MAX_MAX_POSITIONS_DEFAULT",
972
+ "outputs": [
973
+ {
974
+ "internalType": "uint256",
975
+ "name": "",
976
+ "type": "uint256"
977
+ }
978
+ ],
979
+ "stateMutability": "view",
980
+ "type": "function"
981
+ },
982
+ {
983
+ "inputs": [],
984
+ "name": "MIN_BORROW",
985
+ "outputs": [
986
+ {
987
+ "internalType": "uint256",
988
+ "name": "",
989
+ "type": "uint256"
990
+ }
991
+ ],
992
+ "stateMutability": "view",
993
+ "type": "function"
994
+ },
995
+ {
996
+ "inputs": [],
997
+ "name": "MIN_BORROW_DURATION",
998
+ "outputs": [
999
+ {
1000
+ "internalType": "uint256",
1001
+ "name": "",
1002
+ "type": "uint256"
1003
+ }
1004
+ ],
1005
+ "stateMutability": "view",
1006
+ "type": "function"
1007
+ },
1008
+ {
1009
+ "inputs": [],
1010
+ "name": "MIN_MAX_POSITIONS_DEFAULT",
1011
+ "outputs": [
1012
+ {
1013
+ "internalType": "uint256",
1014
+ "name": "",
1015
+ "type": "uint256"
1016
+ }
1017
+ ],
1018
+ "stateMutability": "view",
1019
+ "type": "function"
1020
+ },
1021
+ {
1022
+ "inputs": [],
1023
+ "name": "PRECISION",
1024
+ "outputs": [
1025
+ {
1026
+ "internalType": "uint256",
1027
+ "name": "",
1028
+ "type": "uint256"
1029
+ }
1030
+ ],
1031
+ "stateMutability": "view",
1032
+ "type": "function"
1033
+ },
1034
+ {
1035
+ "inputs": [],
1036
+ "name": "PRICE_PRECISION",
1037
+ "outputs": [
1038
+ {
1039
+ "internalType": "uint256",
1040
+ "name": "",
1041
+ "type": "uint256"
1042
+ }
1043
+ ],
1044
+ "stateMutability": "view",
1045
+ "type": "function"
1046
+ },
1047
+ {
1048
+ "inputs": [],
1049
+ "name": "authority",
1050
+ "outputs": [
1051
+ {
1052
+ "internalType": "address",
1053
+ "name": "",
1054
+ "type": "address"
1055
+ }
1056
+ ],
1057
+ "stateMutability": "view",
1058
+ "type": "function"
1059
+ },
1060
+ {
1061
+ "inputs": [
1062
+ {
1063
+ "internalType": "uint256",
1064
+ "name": "amount",
1065
+ "type": "uint256"
1066
+ }
1067
+ ],
1068
+ "name": "borrow",
1069
+ "outputs": [],
1070
+ "stateMutability": "nonpayable",
1071
+ "type": "function"
1072
+ },
1073
+ {
1074
+ "inputs": [
1075
+ {
1076
+ "internalType": "uint256",
1077
+ "name": "positionId",
1078
+ "type": "uint256"
1079
+ }
1080
+ ],
1081
+ "name": "clearPositionLiquidationConfigOverride",
1082
+ "outputs": [],
1083
+ "stateMutability": "nonpayable",
1084
+ "type": "function"
1085
+ },
1086
+ {
1087
+ "inputs": [
1088
+ {
1089
+ "internalType": "uint256",
1090
+ "name": "positionId",
1091
+ "type": "uint256"
1092
+ }
1093
+ ],
1094
+ "name": "clearPositionLtvOverride",
1095
+ "outputs": [],
1096
+ "stateMutability": "nonpayable",
1097
+ "type": "function"
1098
+ },
1099
+ {
1100
+ "inputs": [],
1101
+ "name": "collateralDecimals",
1102
+ "outputs": [
1103
+ {
1104
+ "internalType": "uint8",
1105
+ "name": "",
1106
+ "type": "uint8"
1107
+ }
1108
+ ],
1109
+ "stateMutability": "view",
1110
+ "type": "function"
1111
+ },
1112
+ {
1113
+ "inputs": [],
1114
+ "name": "collateralToken",
1115
+ "outputs": [
1116
+ {
1117
+ "internalType": "contract IERC20",
1118
+ "name": "",
1119
+ "type": "address"
1120
+ }
1121
+ ],
1122
+ "stateMutability": "view",
1123
+ "type": "function"
1124
+ },
1125
+ {
1126
+ "inputs": [
1127
+ {
1128
+ "internalType": "uint256[]",
1129
+ "name": "positionIds",
1130
+ "type": "uint256[]"
1131
+ },
1132
+ {
1133
+ "internalType": "uint256[]",
1134
+ "name": "amounts",
1135
+ "type": "uint256[]"
1136
+ }
1137
+ ],
1138
+ "name": "deposit",
1139
+ "outputs": [],
1140
+ "stateMutability": "nonpayable",
1141
+ "type": "function"
1142
+ },
1143
+ {
1144
+ "inputs": [
1145
+ {
1146
+ "internalType": "address",
1147
+ "name": "user",
1148
+ "type": "address"
1149
+ }
1150
+ ],
1151
+ "name": "getAccountSummary",
1152
+ "outputs": [
1153
+ {
1154
+ "internalType": "uint256",
1155
+ "name": "portfolioValue",
1156
+ "type": "uint256"
1157
+ },
1158
+ {
1159
+ "internalType": "uint256",
1160
+ "name": "collateralValue",
1161
+ "type": "uint256"
1162
+ },
1163
+ {
1164
+ "internalType": "uint256",
1165
+ "name": "debt",
1166
+ "type": "uint256"
1167
+ },
1168
+ {
1169
+ "internalType": "uint256",
1170
+ "name": "healthFactor",
1171
+ "type": "uint256"
1172
+ },
1173
+ {
1174
+ "internalType": "uint256",
1175
+ "name": "maxBorrow",
1176
+ "type": "uint256"
1177
+ }
1178
+ ],
1179
+ "stateMutability": "view",
1180
+ "type": "function"
1181
+ },
1182
+ {
1183
+ "inputs": [
1184
+ {
1185
+ "internalType": "uint256",
1186
+ "name": "index",
1187
+ "type": "uint256"
1188
+ }
1189
+ ],
1190
+ "name": "getBorrowerAt",
1191
+ "outputs": [
1192
+ {
1193
+ "internalType": "address",
1194
+ "name": "",
1195
+ "type": "address"
1196
+ }
1197
+ ],
1198
+ "stateMutability": "view",
1199
+ "type": "function"
1200
+ },
1201
+ {
1202
+ "inputs": [],
1203
+ "name": "getBorrowers",
1204
+ "outputs": [
1205
+ {
1206
+ "internalType": "address[]",
1207
+ "name": "",
1208
+ "type": "address[]"
1209
+ }
1210
+ ],
1211
+ "stateMutability": "view",
1212
+ "type": "function"
1213
+ },
1214
+ {
1215
+ "inputs": [],
1216
+ "name": "getBorrowersCount",
1217
+ "outputs": [
1218
+ {
1219
+ "internalType": "uint256",
1220
+ "name": "",
1221
+ "type": "uint256"
1222
+ }
1223
+ ],
1224
+ "stateMutability": "view",
1225
+ "type": "function"
1226
+ },
1227
+ {
1228
+ "inputs": [
1229
+ {
1230
+ "internalType": "address",
1231
+ "name": "user",
1232
+ "type": "address"
1233
+ }
1234
+ ],
1235
+ "name": "getCollateralValue",
1236
+ "outputs": [
1237
+ {
1238
+ "internalType": "uint256",
1239
+ "name": "",
1240
+ "type": "uint256"
1241
+ }
1242
+ ],
1243
+ "stateMutability": "view",
1244
+ "type": "function"
1245
+ },
1246
+ {
1247
+ "inputs": [
1248
+ {
1249
+ "internalType": "address",
1250
+ "name": "user",
1251
+ "type": "address"
1252
+ }
1253
+ ],
1254
+ "name": "getDebt",
1255
+ "outputs": [
1256
+ {
1257
+ "internalType": "uint256",
1258
+ "name": "",
1259
+ "type": "uint256"
1260
+ }
1261
+ ],
1262
+ "stateMutability": "view",
1263
+ "type": "function"
1264
+ },
1265
+ {
1266
+ "inputs": [],
1267
+ "name": "getDefaultLtvConfig",
1268
+ "outputs": [
1269
+ {
1270
+ "components": [
1271
+ {
1272
+ "internalType": "uint256",
1273
+ "name": "conservative",
1274
+ "type": "uint256"
1275
+ },
1276
+ {
1277
+ "internalType": "uint256",
1278
+ "name": "moderate",
1279
+ "type": "uint256"
1280
+ },
1281
+ {
1282
+ "internalType": "uint256",
1283
+ "name": "risk",
1284
+ "type": "uint256"
1285
+ }
1286
+ ],
1287
+ "internalType": "struct VarlaCore.LtvConfig",
1288
+ "name": "",
1289
+ "type": "tuple"
1290
+ }
1291
+ ],
1292
+ "stateMutability": "view",
1293
+ "type": "function"
1294
+ },
1295
+ {
1296
+ "inputs": [
1297
+ {
1298
+ "internalType": "address",
1299
+ "name": "user",
1300
+ "type": "address"
1301
+ }
1302
+ ],
1303
+ "name": "getHealthFactor",
1304
+ "outputs": [
1305
+ {
1306
+ "internalType": "uint256",
1307
+ "name": "healthFactor",
1308
+ "type": "uint256"
1309
+ },
1310
+ {
1311
+ "internalType": "bool",
1312
+ "name": "canBeLiquidated",
1313
+ "type": "bool"
1314
+ }
1315
+ ],
1316
+ "stateMutability": "view",
1317
+ "type": "function"
1318
+ },
1319
+ {
1320
+ "inputs": [
1321
+ {
1322
+ "internalType": "uint256",
1323
+ "name": "positionId",
1324
+ "type": "uint256"
1325
+ },
1326
+ {
1327
+ "internalType": "uint256",
1328
+ "name": "healthFactor",
1329
+ "type": "uint256"
1330
+ }
1331
+ ],
1332
+ "name": "getLiquidationBonusBps",
1333
+ "outputs": [
1334
+ {
1335
+ "internalType": "uint256",
1336
+ "name": "bonusBps",
1337
+ "type": "uint256"
1338
+ }
1339
+ ],
1340
+ "stateMutability": "view",
1341
+ "type": "function"
1342
+ },
1343
+ {
1344
+ "inputs": [],
1345
+ "name": "getLiquidationConfig",
1346
+ "outputs": [
1347
+ {
1348
+ "components": [
1349
+ {
1350
+ "internalType": "uint256",
1351
+ "name": "targetHealthFactor",
1352
+ "type": "uint256"
1353
+ },
1354
+ {
1355
+ "internalType": "uint256",
1356
+ "name": "healthFactorForMaxBonus",
1357
+ "type": "uint256"
1358
+ },
1359
+ {
1360
+ "internalType": "uint256",
1361
+ "name": "liquidationBonusFactorBps",
1362
+ "type": "uint256"
1363
+ },
1364
+ {
1365
+ "internalType": "uint256",
1366
+ "name": "dustThreshold",
1367
+ "type": "uint256"
1368
+ },
1369
+ {
1370
+ "internalType": "uint256",
1371
+ "name": "collateralDustThreshold",
1372
+ "type": "uint256"
1373
+ }
1374
+ ],
1375
+ "internalType": "struct VarlaCore.LiquidationConfig",
1376
+ "name": "",
1377
+ "type": "tuple"
1378
+ }
1379
+ ],
1380
+ "stateMutability": "view",
1381
+ "type": "function"
1382
+ },
1383
+ {
1384
+ "inputs": [
1385
+ {
1386
+ "internalType": "uint256",
1387
+ "name": "positionId",
1388
+ "type": "uint256"
1389
+ }
1390
+ ],
1391
+ "name": "getLiquidationParamsForPosition",
1392
+ "outputs": [
1393
+ {
1394
+ "internalType": "uint256",
1395
+ "name": "maxLiquidationBonusBps",
1396
+ "type": "uint256"
1397
+ },
1398
+ {
1399
+ "internalType": "uint256",
1400
+ "name": "liquidationFeeBps",
1401
+ "type": "uint256"
1402
+ }
1403
+ ],
1404
+ "stateMutability": "view",
1405
+ "type": "function"
1406
+ },
1407
+ {
1408
+ "inputs": [
1409
+ {
1410
+ "internalType": "uint256",
1411
+ "name": "positionId",
1412
+ "type": "uint256"
1413
+ }
1414
+ ],
1415
+ "name": "getLtvForPosition",
1416
+ "outputs": [
1417
+ {
1418
+ "internalType": "uint256",
1419
+ "name": "",
1420
+ "type": "uint256"
1421
+ }
1422
+ ],
1423
+ "stateMutability": "view",
1424
+ "type": "function"
1425
+ },
1426
+ {
1427
+ "inputs": [
1428
+ {
1429
+ "internalType": "address",
1430
+ "name": "user",
1431
+ "type": "address"
1432
+ }
1433
+ ],
1434
+ "name": "getMaxBorrow",
1435
+ "outputs": [
1436
+ {
1437
+ "internalType": "uint256",
1438
+ "name": "",
1439
+ "type": "uint256"
1440
+ }
1441
+ ],
1442
+ "stateMutability": "view",
1443
+ "type": "function"
1444
+ },
1445
+ {
1446
+ "inputs": [
1447
+ {
1448
+ "internalType": "address",
1449
+ "name": "user",
1450
+ "type": "address"
1451
+ }
1452
+ ],
1453
+ "name": "getOracleGuardsStatus",
1454
+ "outputs": [
1455
+ {
1456
+ "internalType": "bool",
1457
+ "name": "ok",
1458
+ "type": "bool"
1459
+ },
1460
+ {
1461
+ "internalType": "uint256",
1462
+ "name": "badPid",
1463
+ "type": "uint256"
1464
+ },
1465
+ {
1466
+ "internalType": "uint256",
1467
+ "name": "until",
1468
+ "type": "uint256"
1469
+ }
1470
+ ],
1471
+ "stateMutability": "view",
1472
+ "type": "function"
1473
+ },
1474
+ {
1475
+ "inputs": [
1476
+ {
1477
+ "internalType": "address",
1478
+ "name": "user",
1479
+ "type": "address"
1480
+ }
1481
+ ],
1482
+ "name": "getPortfolioValue",
1483
+ "outputs": [
1484
+ {
1485
+ "internalType": "uint256",
1486
+ "name": "",
1487
+ "type": "uint256"
1488
+ }
1489
+ ],
1490
+ "stateMutability": "view",
1491
+ "type": "function"
1492
+ },
1493
+ {
1494
+ "inputs": [
1495
+ {
1496
+ "internalType": "address",
1497
+ "name": "user",
1498
+ "type": "address"
1499
+ },
1500
+ {
1501
+ "internalType": "uint256",
1502
+ "name": "positionId",
1503
+ "type": "uint256"
1504
+ }
1505
+ ],
1506
+ "name": "getPositionBalance",
1507
+ "outputs": [
1508
+ {
1509
+ "internalType": "uint256",
1510
+ "name": "",
1511
+ "type": "uint256"
1512
+ }
1513
+ ],
1514
+ "stateMutability": "view",
1515
+ "type": "function"
1516
+ },
1517
+ {
1518
+ "inputs": [
1519
+ {
1520
+ "internalType": "address",
1521
+ "name": "user",
1522
+ "type": "address"
1523
+ },
1524
+ {
1525
+ "internalType": "uint256[]",
1526
+ "name": "positionIds",
1527
+ "type": "uint256[]"
1528
+ }
1529
+ ],
1530
+ "name": "getPositionBalances",
1531
+ "outputs": [
1532
+ {
1533
+ "internalType": "uint256[]",
1534
+ "name": "balances",
1535
+ "type": "uint256[]"
1536
+ }
1537
+ ],
1538
+ "stateMutability": "view",
1539
+ "type": "function"
1540
+ },
1541
+ {
1542
+ "inputs": [
1543
+ {
1544
+ "internalType": "address",
1545
+ "name": "user",
1546
+ "type": "address"
1547
+ }
1548
+ ],
1549
+ "name": "getPositionCount",
1550
+ "outputs": [
1551
+ {
1552
+ "internalType": "uint256",
1553
+ "name": "",
1554
+ "type": "uint256"
1555
+ }
1556
+ ],
1557
+ "stateMutability": "view",
1558
+ "type": "function"
1559
+ },
1560
+ {
1561
+ "inputs": [
1562
+ {
1563
+ "internalType": "address",
1564
+ "name": "user",
1565
+ "type": "address"
1566
+ }
1567
+ ],
1568
+ "name": "getPositionIds",
1569
+ "outputs": [
1570
+ {
1571
+ "internalType": "uint256[]",
1572
+ "name": "positionIds",
1573
+ "type": "uint256[]"
1574
+ }
1575
+ ],
1576
+ "stateMutability": "view",
1577
+ "type": "function"
1578
+ },
1579
+ {
1580
+ "inputs": [
1581
+ {
1582
+ "internalType": "uint256",
1583
+ "name": "positionId",
1584
+ "type": "uint256"
1585
+ }
1586
+ ],
1587
+ "name": "getPositionLiquidationConfigOverride",
1588
+ "outputs": [
1589
+ {
1590
+ "internalType": "bool",
1591
+ "name": "isSet",
1592
+ "type": "bool"
1593
+ },
1594
+ {
1595
+ "internalType": "uint256",
1596
+ "name": "maxLiquidationBonusBps",
1597
+ "type": "uint256"
1598
+ },
1599
+ {
1600
+ "internalType": "uint256",
1601
+ "name": "liquidationFeeBps",
1602
+ "type": "uint256"
1603
+ }
1604
+ ],
1605
+ "stateMutability": "view",
1606
+ "type": "function"
1607
+ },
1608
+ {
1609
+ "inputs": [
1610
+ {
1611
+ "internalType": "uint256",
1612
+ "name": "positionId",
1613
+ "type": "uint256"
1614
+ }
1615
+ ],
1616
+ "name": "getPositionLtvOverride",
1617
+ "outputs": [
1618
+ {
1619
+ "internalType": "bool",
1620
+ "name": "isSet",
1621
+ "type": "bool"
1622
+ },
1623
+ {
1624
+ "internalType": "uint256",
1625
+ "name": "ltv",
1626
+ "type": "uint256"
1627
+ }
1628
+ ],
1629
+ "stateMutability": "view",
1630
+ "type": "function"
1631
+ },
1632
+ {
1633
+ "inputs": [
1634
+ {
1635
+ "internalType": "address",
1636
+ "name": "user",
1637
+ "type": "address"
1638
+ }
1639
+ ],
1640
+ "name": "getPositions",
1641
+ "outputs": [
1642
+ {
1643
+ "internalType": "uint256[]",
1644
+ "name": "positionIds",
1645
+ "type": "uint256[]"
1646
+ },
1647
+ {
1648
+ "internalType": "uint256[]",
1649
+ "name": "balances",
1650
+ "type": "uint256[]"
1651
+ }
1652
+ ],
1653
+ "stateMutability": "view",
1654
+ "type": "function"
1655
+ },
1656
+ {
1657
+ "inputs": [
1658
+ {
1659
+ "internalType": "address",
1660
+ "name": "user",
1661
+ "type": "address"
1662
+ }
1663
+ ],
1664
+ "name": "getRepayTiming",
1665
+ "outputs": [
1666
+ {
1667
+ "internalType": "uint256",
1668
+ "name": "borrowedAt",
1669
+ "type": "uint256"
1670
+ },
1671
+ {
1672
+ "internalType": "uint256",
1673
+ "name": "canRepayAt",
1674
+ "type": "uint256"
1675
+ },
1676
+ {
1677
+ "internalType": "bool",
1678
+ "name": "isRepayAllowed",
1679
+ "type": "bool"
1680
+ }
1681
+ ],
1682
+ "stateMutability": "view",
1683
+ "type": "function"
1684
+ },
1685
+ {
1686
+ "inputs": [
1687
+ {
1688
+ "internalType": "address",
1689
+ "name": "user",
1690
+ "type": "address"
1691
+ }
1692
+ ],
1693
+ "name": "getScaledDebt",
1694
+ "outputs": [
1695
+ {
1696
+ "internalType": "uint256",
1697
+ "name": "",
1698
+ "type": "uint256"
1699
+ }
1700
+ ],
1701
+ "stateMutability": "view",
1702
+ "type": "function"
1703
+ },
1704
+ {
1705
+ "inputs": [
1706
+ {
1707
+ "internalType": "uint8",
1708
+ "name": "tier",
1709
+ "type": "uint8"
1710
+ }
1711
+ ],
1712
+ "name": "getTierLiquidationConfig",
1713
+ "outputs": [
1714
+ {
1715
+ "components": [
1716
+ {
1717
+ "internalType": "uint256",
1718
+ "name": "maxLiquidationBonusBps",
1719
+ "type": "uint256"
1720
+ },
1721
+ {
1722
+ "internalType": "uint256",
1723
+ "name": "liquidationFeeBps",
1724
+ "type": "uint256"
1725
+ }
1726
+ ],
1727
+ "internalType": "struct VarlaCore.TierLiquidationConfig",
1728
+ "name": "",
1729
+ "type": "tuple"
1730
+ }
1731
+ ],
1732
+ "stateMutability": "view",
1733
+ "type": "function"
1734
+ },
1735
+ {
1736
+ "inputs": [
1737
+ {
1738
+ "internalType": "address",
1739
+ "name": "user",
1740
+ "type": "address"
1741
+ },
1742
+ {
1743
+ "internalType": "uint256",
1744
+ "name": "expectedScaledDebt",
1745
+ "type": "uint256"
1746
+ }
1747
+ ],
1748
+ "name": "handleBadDebt",
1749
+ "outputs": [],
1750
+ "stateMutability": "nonpayable",
1751
+ "type": "function"
1752
+ },
1753
+ {
1754
+ "inputs": [
1755
+ {
1756
+ "internalType": "address",
1757
+ "name": "user",
1758
+ "type": "address"
1759
+ }
1760
+ ],
1761
+ "name": "isBorrower",
1762
+ "outputs": [
1763
+ {
1764
+ "internalType": "bool",
1765
+ "name": "",
1766
+ "type": "bool"
1767
+ }
1768
+ ],
1769
+ "stateMutability": "view",
1770
+ "type": "function"
1771
+ },
1772
+ {
1773
+ "inputs": [],
1774
+ "name": "isConsumingScheduledOp",
1775
+ "outputs": [
1776
+ {
1777
+ "internalType": "bytes4",
1778
+ "name": "",
1779
+ "type": "bytes4"
1780
+ }
1781
+ ],
1782
+ "stateMutability": "view",
1783
+ "type": "function"
1784
+ },
1785
+ {
1786
+ "inputs": [
1787
+ {
1788
+ "internalType": "address",
1789
+ "name": "user",
1790
+ "type": "address"
1791
+ }
1792
+ ],
1793
+ "name": "isLiquidatable",
1794
+ "outputs": [
1795
+ {
1796
+ "internalType": "bool",
1797
+ "name": "",
1798
+ "type": "bool"
1799
+ }
1800
+ ],
1801
+ "stateMutability": "view",
1802
+ "type": "function"
1803
+ },
1804
+ {
1805
+ "inputs": [],
1806
+ "name": "maxMaxPositions",
1807
+ "outputs": [
1808
+ {
1809
+ "internalType": "uint256",
1810
+ "name": "",
1811
+ "type": "uint256"
1812
+ }
1813
+ ],
1814
+ "stateMutability": "view",
1815
+ "type": "function"
1816
+ },
1817
+ {
1818
+ "inputs": [],
1819
+ "name": "maxPositions",
1820
+ "outputs": [
1821
+ {
1822
+ "internalType": "uint256",
1823
+ "name": "",
1824
+ "type": "uint256"
1825
+ }
1826
+ ],
1827
+ "stateMutability": "view",
1828
+ "type": "function"
1829
+ },
1830
+ {
1831
+ "inputs": [],
1832
+ "name": "minMaxPositions",
1833
+ "outputs": [
1834
+ {
1835
+ "internalType": "uint256",
1836
+ "name": "",
1837
+ "type": "uint256"
1838
+ }
1839
+ ],
1840
+ "stateMutability": "view",
1841
+ "type": "function"
1842
+ },
1843
+ {
1844
+ "inputs": [
1845
+ {
1846
+ "internalType": "address",
1847
+ "name": "",
1848
+ "type": "address"
1849
+ },
1850
+ {
1851
+ "internalType": "address",
1852
+ "name": "",
1853
+ "type": "address"
1854
+ },
1855
+ {
1856
+ "internalType": "uint256[]",
1857
+ "name": "",
1858
+ "type": "uint256[]"
1859
+ },
1860
+ {
1861
+ "internalType": "uint256[]",
1862
+ "name": "",
1863
+ "type": "uint256[]"
1864
+ },
1865
+ {
1866
+ "internalType": "bytes",
1867
+ "name": "",
1868
+ "type": "bytes"
1869
+ }
1870
+ ],
1871
+ "name": "onERC1155BatchReceived",
1872
+ "outputs": [
1873
+ {
1874
+ "internalType": "bytes4",
1875
+ "name": "",
1876
+ "type": "bytes4"
1877
+ }
1878
+ ],
1879
+ "stateMutability": "nonpayable",
1880
+ "type": "function"
1881
+ },
1882
+ {
1883
+ "inputs": [
1884
+ {
1885
+ "internalType": "address",
1886
+ "name": "",
1887
+ "type": "address"
1888
+ },
1889
+ {
1890
+ "internalType": "address",
1891
+ "name": "",
1892
+ "type": "address"
1893
+ },
1894
+ {
1895
+ "internalType": "uint256",
1896
+ "name": "",
1897
+ "type": "uint256"
1898
+ },
1899
+ {
1900
+ "internalType": "uint256",
1901
+ "name": "",
1902
+ "type": "uint256"
1903
+ },
1904
+ {
1905
+ "internalType": "bytes",
1906
+ "name": "",
1907
+ "type": "bytes"
1908
+ }
1909
+ ],
1910
+ "name": "onERC1155Received",
1911
+ "outputs": [
1912
+ {
1913
+ "internalType": "bytes4",
1914
+ "name": "",
1915
+ "type": "bytes4"
1916
+ }
1917
+ ],
1918
+ "stateMutability": "nonpayable",
1919
+ "type": "function"
1920
+ },
1921
+ {
1922
+ "inputs": [],
1923
+ "name": "oracle",
1924
+ "outputs": [
1925
+ {
1926
+ "internalType": "contract IVarlaOracle",
1927
+ "name": "",
1928
+ "type": "address"
1929
+ }
1930
+ ],
1931
+ "stateMutability": "view",
1932
+ "type": "function"
1933
+ },
1934
+ {
1935
+ "inputs": [],
1936
+ "name": "pool",
1937
+ "outputs": [
1938
+ {
1939
+ "internalType": "contract IVarlaPool",
1940
+ "name": "",
1941
+ "type": "address"
1942
+ }
1943
+ ],
1944
+ "stateMutability": "view",
1945
+ "type": "function"
1946
+ },
1947
+ {
1948
+ "inputs": [
1949
+ {
1950
+ "internalType": "address",
1951
+ "name": "",
1952
+ "type": "address"
1953
+ },
1954
+ {
1955
+ "internalType": "uint256",
1956
+ "name": "",
1957
+ "type": "uint256"
1958
+ }
1959
+ ],
1960
+ "name": "positionBalances",
1961
+ "outputs": [
1962
+ {
1963
+ "internalType": "uint256",
1964
+ "name": "",
1965
+ "type": "uint256"
1966
+ }
1967
+ ],
1968
+ "stateMutability": "view",
1969
+ "type": "function"
1970
+ },
1971
+ {
1972
+ "inputs": [],
1973
+ "name": "positionsToken",
1974
+ "outputs": [
1975
+ {
1976
+ "internalType": "contract IERC1155",
1977
+ "name": "",
1978
+ "type": "address"
1979
+ }
1980
+ ],
1981
+ "stateMutability": "view",
1982
+ "type": "function"
1983
+ },
1984
+ {
1985
+ "inputs": [
1986
+ {
1987
+ "internalType": "uint256",
1988
+ "name": "amount",
1989
+ "type": "uint256"
1990
+ }
1991
+ ],
1992
+ "name": "repay",
1993
+ "outputs": [],
1994
+ "stateMutability": "nonpayable",
1995
+ "type": "function"
1996
+ },
1997
+ {
1998
+ "inputs": [
1999
+ {
2000
+ "internalType": "address",
2001
+ "name": "user",
2002
+ "type": "address"
2003
+ },
2004
+ {
2005
+ "internalType": "uint256",
2006
+ "name": "amount",
2007
+ "type": "uint256"
2008
+ }
2009
+ ],
2010
+ "name": "repayOnBehalfFromLiquidation",
2011
+ "outputs": [
2012
+ {
2013
+ "internalType": "uint256",
2014
+ "name": "scaledRepayAmount",
2015
+ "type": "uint256"
2016
+ }
2017
+ ],
2018
+ "stateMutability": "nonpayable",
2019
+ "type": "function"
2020
+ },
2021
+ {
2022
+ "inputs": [
2023
+ {
2024
+ "internalType": "address",
2025
+ "name": "user",
2026
+ "type": "address"
2027
+ },
2028
+ {
2029
+ "internalType": "uint256[]",
2030
+ "name": "positionIds",
2031
+ "type": "uint256[]"
2032
+ },
2033
+ {
2034
+ "internalType": "uint256[]",
2035
+ "name": "amounts",
2036
+ "type": "uint256[]"
2037
+ },
2038
+ {
2039
+ "internalType": "address",
2040
+ "name": "recipient",
2041
+ "type": "address"
2042
+ }
2043
+ ],
2044
+ "name": "seizeCollateral",
2045
+ "outputs": [],
2046
+ "stateMutability": "nonpayable",
2047
+ "type": "function"
2048
+ },
2049
+ {
2050
+ "inputs": [
2051
+ {
2052
+ "internalType": "address",
2053
+ "name": "newAuthority",
2054
+ "type": "address"
2055
+ }
2056
+ ],
2057
+ "name": "setAuthority",
2058
+ "outputs": [],
2059
+ "stateMutability": "nonpayable",
2060
+ "type": "function"
2061
+ },
2062
+ {
2063
+ "inputs": [
2064
+ {
2065
+ "internalType": "uint256",
2066
+ "name": "conservative",
2067
+ "type": "uint256"
2068
+ },
2069
+ {
2070
+ "internalType": "uint256",
2071
+ "name": "moderate",
2072
+ "type": "uint256"
2073
+ },
2074
+ {
2075
+ "internalType": "uint256",
2076
+ "name": "risk",
2077
+ "type": "uint256"
2078
+ }
2079
+ ],
2080
+ "name": "setDefaultLtvConfig",
2081
+ "outputs": [],
2082
+ "stateMutability": "nonpayable",
2083
+ "type": "function"
2084
+ },
2085
+ {
2086
+ "inputs": [
2087
+ {
2088
+ "internalType": "uint256",
2089
+ "name": "targetHealthFactor",
2090
+ "type": "uint256"
2091
+ },
2092
+ {
2093
+ "internalType": "uint256",
2094
+ "name": "healthFactorForMaxBonus",
2095
+ "type": "uint256"
2096
+ },
2097
+ {
2098
+ "internalType": "uint256",
2099
+ "name": "liquidationBonusFactorBps",
2100
+ "type": "uint256"
2101
+ },
2102
+ {
2103
+ "internalType": "uint256",
2104
+ "name": "dustThreshold",
2105
+ "type": "uint256"
2106
+ },
2107
+ {
2108
+ "internalType": "uint256",
2109
+ "name": "collateralDustThreshold",
2110
+ "type": "uint256"
2111
+ }
2112
+ ],
2113
+ "name": "setLiquidationConfig",
2114
+ "outputs": [],
2115
+ "stateMutability": "nonpayable",
2116
+ "type": "function"
2117
+ },
2118
+ {
2119
+ "inputs": [
2120
+ {
2121
+ "internalType": "uint256",
2122
+ "name": "_maxPositions",
2123
+ "type": "uint256"
2124
+ }
2125
+ ],
2126
+ "name": "setMaxPositions",
2127
+ "outputs": [],
2128
+ "stateMutability": "nonpayable",
2129
+ "type": "function"
2130
+ },
2131
+ {
2132
+ "inputs": [
2133
+ {
2134
+ "internalType": "uint256",
2135
+ "name": "newMin",
2136
+ "type": "uint256"
2137
+ },
2138
+ {
2139
+ "internalType": "uint256",
2140
+ "name": "newMax",
2141
+ "type": "uint256"
2142
+ }
2143
+ ],
2144
+ "name": "setMaxPositionsBounds",
2145
+ "outputs": [],
2146
+ "stateMutability": "nonpayable",
2147
+ "type": "function"
2148
+ },
2149
+ {
2150
+ "inputs": [
2151
+ {
2152
+ "internalType": "address",
2153
+ "name": "_oracle",
2154
+ "type": "address"
2155
+ }
2156
+ ],
2157
+ "name": "setOracle",
2158
+ "outputs": [],
2159
+ "stateMutability": "nonpayable",
2160
+ "type": "function"
2161
+ },
2162
+ {
2163
+ "inputs": [
2164
+ {
2165
+ "internalType": "uint256",
2166
+ "name": "positionId",
2167
+ "type": "uint256"
2168
+ },
2169
+ {
2170
+ "internalType": "uint256",
2171
+ "name": "maxLiquidationBonusBps",
2172
+ "type": "uint256"
2173
+ },
2174
+ {
2175
+ "internalType": "uint256",
2176
+ "name": "liquidationFeeBps",
2177
+ "type": "uint256"
2178
+ }
2179
+ ],
2180
+ "name": "setPositionLiquidationConfigOverride",
2181
+ "outputs": [],
2182
+ "stateMutability": "nonpayable",
2183
+ "type": "function"
2184
+ },
2185
+ {
2186
+ "inputs": [
2187
+ {
2188
+ "internalType": "uint256",
2189
+ "name": "positionId",
2190
+ "type": "uint256"
2191
+ },
2192
+ {
2193
+ "internalType": "uint256",
2194
+ "name": "ltv",
2195
+ "type": "uint256"
2196
+ }
2197
+ ],
2198
+ "name": "setPositionLtvOverride",
2199
+ "outputs": [],
2200
+ "stateMutability": "nonpayable",
2201
+ "type": "function"
2202
+ },
2203
+ {
2204
+ "inputs": [
2205
+ {
2206
+ "internalType": "uint8",
2207
+ "name": "tier",
2208
+ "type": "uint8"
2209
+ },
2210
+ {
2211
+ "internalType": "uint256",
2212
+ "name": "maxLiquidationBonusBps",
2213
+ "type": "uint256"
2214
+ },
2215
+ {
2216
+ "internalType": "uint256",
2217
+ "name": "liquidationFeeBps",
2218
+ "type": "uint256"
2219
+ }
2220
+ ],
2221
+ "name": "setTierLiquidationConfig",
2222
+ "outputs": [],
2223
+ "stateMutability": "nonpayable",
2224
+ "type": "function"
2225
+ },
2226
+ {
2227
+ "inputs": [
2228
+ {
2229
+ "internalType": "bytes4",
2230
+ "name": "interfaceId",
2231
+ "type": "bytes4"
2232
+ }
2233
+ ],
2234
+ "name": "supportsInterface",
2235
+ "outputs": [
2236
+ {
2237
+ "internalType": "bool",
2238
+ "name": "",
2239
+ "type": "bool"
2240
+ }
2241
+ ],
2242
+ "stateMutability": "view",
2243
+ "type": "function"
2244
+ },
2245
+ {
2246
+ "inputs": [],
2247
+ "name": "totalScaledDebt",
2248
+ "outputs": [
2249
+ {
2250
+ "internalType": "uint256",
2251
+ "name": "",
2252
+ "type": "uint256"
2253
+ }
2254
+ ],
2255
+ "stateMutability": "view",
2256
+ "type": "function"
2257
+ },
2258
+ {
2259
+ "inputs": [
2260
+ {
2261
+ "internalType": "uint256[]",
2262
+ "name": "positionIds",
2263
+ "type": "uint256[]"
2264
+ },
2265
+ {
2266
+ "internalType": "uint256[]",
2267
+ "name": "amounts",
2268
+ "type": "uint256[]"
2269
+ }
2270
+ ],
2271
+ "name": "withdraw",
2272
+ "outputs": [],
2273
+ "stateMutability": "nonpayable",
2274
+ "type": "function"
2275
+ }
2276
+ ] as const satisfies Abi;
2277
+