@underscore-finance/sdk 0.3.5 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (244) hide show
  1. package/dist/contracts/AaveV3.d.ts +2120 -0
  2. package/dist/contracts/AaveV3.d.ts.map +1 -0
  3. package/dist/contracts/AaveV3.js +2714 -0
  4. package/dist/contracts/AeroClassic.d.ts +2017 -0
  5. package/dist/contracts/AeroClassic.d.ts.map +1 -0
  6. package/dist/contracts/AeroClassic.js +2567 -0
  7. package/dist/contracts/AeroSlipstream.d.ts +2113 -0
  8. package/dist/contracts/AeroSlipstream.d.ts.map +1 -0
  9. package/dist/contracts/AeroSlipstream.js +2692 -0
  10. package/dist/contracts/Agent.d.ts +2189 -1138
  11. package/dist/contracts/Agent.d.ts.map +1 -1
  12. package/dist/contracts/Agent.js +2807 -1343
  13. package/dist/contracts/AgentWrapper.d.ts +3760 -0
  14. package/dist/contracts/AgentWrapper.d.ts.map +1 -0
  15. package/dist/contracts/AgentWrapper.js +4922 -0
  16. package/dist/contracts/Appraiser.d.ts +997 -0
  17. package/dist/contracts/Appraiser.d.ts.map +1 -0
  18. package/dist/contracts/Appraiser.js +1285 -0
  19. package/dist/contracts/Billing.d.ts +420 -0
  20. package/dist/contracts/Billing.d.ts.map +1 -0
  21. package/dist/contracts/Billing.js +506 -0
  22. package/dist/contracts/ChequeBook.d.ts +1184 -0
  23. package/dist/contracts/ChequeBook.d.ts.map +1 -0
  24. package/dist/contracts/ChequeBook.js +1352 -0
  25. package/dist/contracts/CompoundV3.d.ts +2158 -0
  26. package/dist/contracts/CompoundV3.d.ts.map +1 -0
  27. package/dist/contracts/CompoundV3.js +2764 -0
  28. package/dist/contracts/Curve.d.ts +1077 -0
  29. package/dist/contracts/Curve.d.ts.map +1 -0
  30. package/dist/contracts/Curve.js +1357 -0
  31. package/dist/contracts/DefaultsBase.d.ts +290 -0
  32. package/dist/contracts/DefaultsBase.d.ts.map +1 -0
  33. package/dist/contracts/DefaultsBase.js +316 -0
  34. package/dist/contracts/Euler.d.ts +2172 -0
  35. package/dist/contracts/Euler.d.ts.map +1 -0
  36. package/dist/contracts/Euler.js +2782 -0
  37. package/dist/contracts/Fluid.d.ts +2106 -0
  38. package/dist/contracts/Fluid.d.ts.map +1 -0
  39. package/dist/contracts/Fluid.js +2696 -0
  40. package/dist/contracts/Hatchery.d.ts +541 -0
  41. package/dist/contracts/Hatchery.d.ts.map +1 -0
  42. package/dist/contracts/Hatchery.js +671 -0
  43. package/dist/contracts/HighCommand.d.ts +1868 -0
  44. package/dist/contracts/HighCommand.d.ts.map +1 -0
  45. package/dist/contracts/HighCommand.js +2149 -0
  46. package/dist/contracts/Kernel.d.ts +354 -0
  47. package/dist/contracts/Kernel.d.ts.map +1 -0
  48. package/dist/contracts/Kernel.js +412 -0
  49. package/dist/contracts/Ledger.d.ts +694 -0
  50. package/dist/contracts/Ledger.d.ts.map +1 -0
  51. package/dist/contracts/Ledger.js +834 -0
  52. package/dist/contracts/LegoBook.d.ts +1424 -0
  53. package/dist/contracts/LegoBook.d.ts.map +1 -0
  54. package/dist/contracts/LegoBook.js +1783 -0
  55. package/dist/contracts/LegoTools.d.ts +1898 -0
  56. package/dist/contracts/LegoTools.d.ts.map +1 -0
  57. package/dist/contracts/LegoTools.js +2378 -0
  58. package/dist/contracts/LegoUniswapV0_2.d.ts +1204 -0
  59. package/dist/contracts/LegoUniswapV0_2.d.ts.map +1 -0
  60. package/dist/contracts/LegoUniswapV0_2.js +1546 -0
  61. package/dist/contracts/LootDistributor.d.ts +996 -0
  62. package/dist/contracts/LootDistributor.d.ts.map +1 -0
  63. package/dist/contracts/LootDistributor.js +1255 -0
  64. package/dist/contracts/Migrator.d.ts +268 -0
  65. package/dist/contracts/Migrator.d.ts.map +1 -0
  66. package/dist/contracts/Migrator.js +324 -0
  67. package/dist/contracts/MissionControl.d.ts +1331 -0
  68. package/dist/contracts/MissionControl.d.ts.map +1 -0
  69. package/dist/contracts/MissionControl.js +1485 -0
  70. package/dist/contracts/Moonwell.d.ts +2137 -0
  71. package/dist/contracts/Moonwell.d.ts.map +1 -0
  72. package/dist/contracts/Moonwell.js +2737 -0
  73. package/dist/contracts/Morpho.d.ts +2172 -0
  74. package/dist/contracts/Morpho.d.ts.map +1 -0
  75. package/dist/contracts/Morpho.js +2782 -0
  76. package/dist/contracts/Paymaster.d.ts +1679 -0
  77. package/dist/contracts/Paymaster.d.ts.map +1 -0
  78. package/dist/contracts/Paymaster.js +2077 -0
  79. package/dist/contracts/RipeLego.d.ts +2263 -0
  80. package/dist/contracts/RipeLego.d.ts.map +1 -0
  81. package/dist/contracts/RipeLego.js +2891 -0
  82. package/dist/contracts/Sentinel.d.ts +1804 -0
  83. package/dist/contracts/Sentinel.d.ts.map +1 -0
  84. package/dist/contracts/Sentinel.js +2152 -0
  85. package/dist/contracts/Switchboard.d.ts +1395 -0
  86. package/dist/contracts/Switchboard.d.ts.map +1 -0
  87. package/dist/contracts/Switchboard.js +1746 -0
  88. package/dist/contracts/SwitchboardAlpha.d.ts +2228 -0
  89. package/dist/contracts/SwitchboardAlpha.d.ts.map +1 -0
  90. package/dist/contracts/SwitchboardAlpha.js +2743 -0
  91. package/dist/contracts/SwitchboardBravo.d.ts +1498 -0
  92. package/dist/contracts/SwitchboardBravo.d.ts.map +1 -0
  93. package/dist/contracts/SwitchboardBravo.js +1855 -0
  94. package/dist/contracts/UndyHq.d.ts +1580 -0
  95. package/dist/contracts/UndyHq.d.ts.map +1 -0
  96. package/dist/contracts/UndyHq.js +1986 -0
  97. package/dist/contracts/UniswapV2.d.ts +2017 -0
  98. package/dist/contracts/UniswapV2.d.ts.map +1 -0
  99. package/dist/contracts/UniswapV2.js +2567 -0
  100. package/dist/contracts/UniswapV3.d.ts +2113 -0
  101. package/dist/contracts/UniswapV3.d.ts.map +1 -0
  102. package/dist/contracts/UniswapV3.js +2692 -0
  103. package/dist/contracts/UserWallet.d.ts +1438 -784
  104. package/dist/contracts/UserWallet.d.ts.map +1 -1
  105. package/dist/contracts/UserWallet.js +1854 -935
  106. package/dist/contracts/UserWalletConfig.d.ts +3034 -1231
  107. package/dist/contracts/UserWalletConfig.d.ts.map +1 -1
  108. package/dist/contracts/UserWalletConfig.js +3395 -1407
  109. package/dist/contracts/WalletBackpack.d.ts +1183 -0
  110. package/dist/contracts/WalletBackpack.d.ts.map +1 -0
  111. package/dist/contracts/WalletBackpack.js +1484 -0
  112. package/dist/contracts/index.d.ts +33 -36
  113. package/dist/contracts/index.d.ts.map +1 -1
  114. package/dist/contracts/index.js +33 -36
  115. package/dist/contracts/sdk.d.ts +66 -72
  116. package/dist/contracts/sdk.d.ts.map +1 -1
  117. package/dist/contracts/sdk.js +66 -72
  118. package/dist/contracts/v0_1_AddyRegistry.d.ts +473 -0
  119. package/dist/contracts/v0_1_AddyRegistry.d.ts.map +1 -0
  120. package/dist/contracts/v0_1_AddyRegistry.js +594 -0
  121. package/dist/contracts/v0_1_Agent.d.ts +2631 -0
  122. package/dist/contracts/v0_1_Agent.d.ts.map +1 -0
  123. package/dist/contracts/v0_1_Agent.js +3372 -0
  124. package/dist/contracts/v0_1_AgentFactory.d.ts +1054 -0
  125. package/dist/contracts/v0_1_AgentFactory.d.ts.map +1 -0
  126. package/dist/contracts/v0_1_AgentFactory.js +1336 -0
  127. package/dist/contracts/v0_1_UserWallet.d.ts +1980 -0
  128. package/dist/contracts/v0_1_UserWallet.d.ts.map +1 -0
  129. package/dist/contracts/v0_1_UserWallet.js +2581 -0
  130. package/dist/contracts/v0_1_UserWalletConfig.d.ts +1400 -0
  131. package/dist/contracts/v0_1_UserWalletConfig.d.ts.map +1 -0
  132. package/dist/contracts/v0_1_UserWalletConfig.js +1676 -0
  133. package/dist/contracts/v0_2_AddyRegistry.d.ts +1050 -0
  134. package/dist/contracts/v0_2_AddyRegistry.d.ts.map +1 -0
  135. package/dist/contracts/v0_2_AddyRegistry.js +1313 -0
  136. package/dist/contracts/v0_2_Agent.d.ts +2709 -0
  137. package/dist/contracts/v0_2_Agent.d.ts.map +1 -0
  138. package/dist/contracts/v0_2_Agent.js +3458 -0
  139. package/dist/contracts/v0_2_AgentFactory.d.ts +1275 -0
  140. package/dist/contracts/v0_2_AgentFactory.d.ts.map +1 -0
  141. package/dist/contracts/v0_2_AgentFactory.js +1609 -0
  142. package/dist/contracts/v0_2_UserWallet.d.ts +1958 -0
  143. package/dist/contracts/v0_2_UserWallet.d.ts.map +1 -0
  144. package/dist/contracts/v0_2_UserWallet.js +2553 -0
  145. package/dist/contracts/v0_2_UserWalletConfig.d.ts +1468 -0
  146. package/dist/contracts/v0_2_UserWalletConfig.d.ts.map +1 -0
  147. package/dist/contracts/v0_2_UserWalletConfig.js +1764 -0
  148. package/dist/contracts/v0_3_AddyRegistry.d.ts +1109 -0
  149. package/dist/contracts/v0_3_AddyRegistry.d.ts.map +1 -0
  150. package/dist/contracts/v0_3_AddyRegistry.js +1392 -0
  151. package/dist/contracts/v0_3_Agent.d.ts +2709 -0
  152. package/dist/contracts/v0_3_Agent.d.ts.map +1 -0
  153. package/dist/contracts/v0_3_Agent.js +3458 -0
  154. package/dist/contracts/v0_3_AgentFactory.d.ts +1665 -0
  155. package/dist/contracts/v0_3_AgentFactory.d.ts.map +1 -0
  156. package/dist/contracts/v0_3_AgentFactory.js +2078 -0
  157. package/dist/contracts/v0_3_ChainlinkFeeds.d.ts +706 -0
  158. package/dist/contracts/v0_3_ChainlinkFeeds.d.ts.map +1 -0
  159. package/dist/contracts/v0_3_ChainlinkFeeds.js +900 -0
  160. package/dist/contracts/v0_3_LegoAaveV3.d.ts +1033 -0
  161. package/dist/contracts/v0_3_LegoAaveV3.d.ts.map +1 -0
  162. package/dist/contracts/v0_3_LegoAaveV3.js +1330 -0
  163. package/dist/contracts/v0_3_LegoAeroClassic.d.ts +1204 -0
  164. package/dist/contracts/v0_3_LegoAeroClassic.d.ts.map +1 -0
  165. package/dist/contracts/v0_3_LegoAeroClassic.js +1546 -0
  166. package/dist/contracts/v0_3_LegoAeroSlipstream.d.ts +1300 -0
  167. package/dist/contracts/v0_3_LegoAeroSlipstream.d.ts.map +1 -0
  168. package/dist/contracts/v0_3_LegoAeroSlipstream.js +1671 -0
  169. package/dist/contracts/v0_3_LegoCommon.d.ts +164 -0
  170. package/dist/contracts/v0_3_LegoCommon.d.ts.map +1 -0
  171. package/dist/contracts/v0_3_LegoCommon.js +202 -0
  172. package/dist/contracts/v0_3_LegoCompoundV3.d.ts +1060 -0
  173. package/dist/contracts/v0_3_LegoCompoundV3.d.ts.map +1 -0
  174. package/dist/contracts/v0_3_LegoCompoundV3.js +1365 -0
  175. package/dist/contracts/v0_3_LegoCredit.d.ts +140 -0
  176. package/dist/contracts/v0_3_LegoCredit.d.ts.map +1 -0
  177. package/dist/contracts/v0_3_LegoCredit.js +179 -0
  178. package/dist/contracts/v0_3_LegoCurve.d.ts +1189 -0
  179. package/dist/contracts/v0_3_LegoCurve.d.ts.map +1 -0
  180. package/dist/contracts/v0_3_LegoCurve.js +1519 -0
  181. package/dist/contracts/v0_3_LegoDex.d.ts +587 -0
  182. package/dist/contracts/v0_3_LegoDex.d.ts.map +1 -0
  183. package/dist/contracts/v0_3_LegoDex.js +774 -0
  184. package/dist/contracts/v0_3_LegoEuler.d.ts +1074 -0
  185. package/dist/contracts/v0_3_LegoEuler.d.ts.map +1 -0
  186. package/dist/contracts/v0_3_LegoEuler.js +1383 -0
  187. package/dist/contracts/v0_3_LegoFluid.d.ts +1025 -0
  188. package/dist/contracts/v0_3_LegoFluid.d.ts.map +1 -0
  189. package/dist/contracts/v0_3_LegoFluid.js +1320 -0
  190. package/dist/contracts/v0_3_LegoHelper.d.ts +1563 -0
  191. package/dist/contracts/v0_3_LegoHelper.d.ts.map +1 -0
  192. package/dist/contracts/v0_3_LegoHelper.js +1947 -0
  193. package/dist/contracts/v0_3_LegoMoonwell.d.ts +1042 -0
  194. package/dist/contracts/v0_3_LegoMoonwell.d.ts.map +1 -0
  195. package/dist/contracts/v0_3_LegoMoonwell.js +1342 -0
  196. package/dist/contracts/v0_3_LegoMorpho.d.ts +1074 -0
  197. package/dist/contracts/v0_3_LegoMorpho.d.ts.map +1 -0
  198. package/dist/contracts/v0_3_LegoMorpho.js +1383 -0
  199. package/dist/contracts/v0_3_LegoRegistry.d.ts +1079 -0
  200. package/dist/contracts/v0_3_LegoRegistry.d.ts.map +1 -0
  201. package/dist/contracts/v0_3_LegoRegistry.js +1368 -0
  202. package/dist/contracts/v0_3_LegoSky.d.ts +923 -0
  203. package/dist/contracts/v0_3_LegoSky.d.ts.map +1 -0
  204. package/dist/contracts/v0_3_LegoSky.js +1180 -0
  205. package/dist/contracts/v0_3_LegoUniswapV3.d.ts +1338 -0
  206. package/dist/contracts/v0_3_LegoUniswapV3.d.ts.map +1 -0
  207. package/dist/contracts/v0_3_LegoUniswapV3.js +1718 -0
  208. package/dist/contracts/v0_3_LegoYield.d.ts +390 -0
  209. package/dist/contracts/v0_3_LegoYield.d.ts.map +1 -0
  210. package/dist/contracts/v0_3_LegoYield.js +511 -0
  211. package/dist/contracts/v0_3_OracleParser.d.ts +207 -0
  212. package/dist/contracts/v0_3_OracleParser.d.ts.map +1 -0
  213. package/dist/contracts/v0_3_OracleParser.js +264 -0
  214. package/dist/contracts/v0_3_OracleRegistry.d.ts +1221 -0
  215. package/dist/contracts/v0_3_OracleRegistry.d.ts.map +1 -0
  216. package/dist/contracts/v0_3_OracleRegistry.js +1562 -0
  217. package/dist/contracts/v0_3_PriceSheets.d.ts +1127 -0
  218. package/dist/contracts/v0_3_PriceSheets.d.ts.map +1 -0
  219. package/dist/contracts/v0_3_PriceSheets.js +1383 -0
  220. package/dist/contracts/v0_3_PythFeeds.d.ts +640 -0
  221. package/dist/contracts/v0_3_PythFeeds.d.ts.map +1 -0
  222. package/dist/contracts/v0_3_PythFeeds.js +813 -0
  223. package/dist/contracts/v0_3_StorkFeeds.d.ts +640 -0
  224. package/dist/contracts/v0_3_StorkFeeds.d.ts.map +1 -0
  225. package/dist/contracts/v0_3_StorkFeeds.js +813 -0
  226. package/dist/contracts/v0_3_UserWallet.d.ts +1975 -0
  227. package/dist/contracts/v0_3_UserWallet.d.ts.map +1 -0
  228. package/dist/contracts/v0_3_UserWallet.js +2577 -0
  229. package/dist/contracts/v0_3_UserWalletConfig.d.ts +1852 -0
  230. package/dist/contracts/v0_3_UserWalletConfig.d.ts.map +1 -0
  231. package/dist/contracts/v0_3_UserWalletConfig.js +2263 -0
  232. package/dist/getContracts.d.ts +75 -0
  233. package/dist/getContracts.d.ts.map +1 -0
  234. package/dist/getContracts.js +62 -0
  235. package/dist/getLegacyContracts.d.ts +69 -0
  236. package/dist/getLegacyContracts.d.ts.map +1 -0
  237. package/dist/getLegacyContracts.js +55 -0
  238. package/dist/getSwapInstructions.d.ts +33 -0
  239. package/dist/getSwapInstructions.d.ts.map +1 -0
  240. package/dist/getSwapInstructions.js +21 -0
  241. package/dist/index.d.ts +3 -475
  242. package/dist/index.d.ts.map +1 -1
  243. package/dist/index.js +8 -182
  244. package/package.json +2 -2
@@ -0,0 +1,1320 @@
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /* @ts-nocheck */
5
+ import { singleQuery, mutate } from '@dappql/async';
6
+ export const abi = [
7
+ {
8
+ anonymous: false,
9
+ inputs: [
10
+ {
11
+ indexed: true,
12
+ name: 'sender',
13
+ type: 'address',
14
+ },
15
+ {
16
+ indexed: true,
17
+ name: 'asset',
18
+ type: 'address',
19
+ },
20
+ {
21
+ indexed: true,
22
+ name: 'vaultToken',
23
+ type: 'address',
24
+ },
25
+ {
26
+ indexed: false,
27
+ name: 'assetAmountDeposited',
28
+ type: 'uint256',
29
+ },
30
+ {
31
+ indexed: false,
32
+ name: 'usdValue',
33
+ type: 'uint256',
34
+ },
35
+ {
36
+ indexed: false,
37
+ name: 'vaultTokenAmountReceived',
38
+ type: 'uint256',
39
+ },
40
+ {
41
+ indexed: false,
42
+ name: 'recipient',
43
+ type: 'address',
44
+ },
45
+ ],
46
+ name: 'FluidDeposit',
47
+ type: 'event',
48
+ },
49
+ {
50
+ anonymous: false,
51
+ inputs: [
52
+ {
53
+ indexed: true,
54
+ name: 'sender',
55
+ type: 'address',
56
+ },
57
+ {
58
+ indexed: true,
59
+ name: 'asset',
60
+ type: 'address',
61
+ },
62
+ {
63
+ indexed: true,
64
+ name: 'vaultToken',
65
+ type: 'address',
66
+ },
67
+ {
68
+ indexed: false,
69
+ name: 'assetAmountReceived',
70
+ type: 'uint256',
71
+ },
72
+ {
73
+ indexed: false,
74
+ name: 'usdValue',
75
+ type: 'uint256',
76
+ },
77
+ {
78
+ indexed: false,
79
+ name: 'vaultTokenAmountBurned',
80
+ type: 'uint256',
81
+ },
82
+ {
83
+ indexed: false,
84
+ name: 'recipient',
85
+ type: 'address',
86
+ },
87
+ ],
88
+ name: 'FluidWithdrawal',
89
+ type: 'event',
90
+ },
91
+ {
92
+ anonymous: false,
93
+ inputs: [
94
+ {
95
+ indexed: true,
96
+ name: 'asset',
97
+ type: 'address',
98
+ },
99
+ {
100
+ indexed: true,
101
+ name: 'recipient',
102
+ type: 'address',
103
+ },
104
+ {
105
+ indexed: false,
106
+ name: 'amount',
107
+ type: 'uint256',
108
+ },
109
+ ],
110
+ name: 'FluidFundsRecovered',
111
+ type: 'event',
112
+ },
113
+ {
114
+ anonymous: false,
115
+ inputs: [
116
+ {
117
+ indexed: false,
118
+ name: 'legoId',
119
+ type: 'uint256',
120
+ },
121
+ ],
122
+ name: 'FluidLegoIdSet',
123
+ type: 'event',
124
+ },
125
+ {
126
+ anonymous: false,
127
+ inputs: [
128
+ {
129
+ indexed: false,
130
+ name: 'isActivated',
131
+ type: 'bool',
132
+ },
133
+ ],
134
+ name: 'FluidActivated',
135
+ type: 'event',
136
+ },
137
+ {
138
+ anonymous: false,
139
+ inputs: [
140
+ {
141
+ indexed: true,
142
+ name: 'prevGov',
143
+ type: 'address',
144
+ },
145
+ {
146
+ indexed: true,
147
+ name: 'newGov',
148
+ type: 'address',
149
+ },
150
+ {
151
+ indexed: false,
152
+ name: 'confirmBlock',
153
+ type: 'uint256',
154
+ },
155
+ ],
156
+ name: 'GovChangeInitiated',
157
+ type: 'event',
158
+ },
159
+ {
160
+ anonymous: false,
161
+ inputs: [
162
+ {
163
+ indexed: true,
164
+ name: 'prevGov',
165
+ type: 'address',
166
+ },
167
+ {
168
+ indexed: true,
169
+ name: 'newGov',
170
+ type: 'address',
171
+ },
172
+ {
173
+ indexed: false,
174
+ name: 'initiatedBlock',
175
+ type: 'uint256',
176
+ },
177
+ {
178
+ indexed: false,
179
+ name: 'confirmBlock',
180
+ type: 'uint256',
181
+ },
182
+ ],
183
+ name: 'GovChangeConfirmed',
184
+ type: 'event',
185
+ },
186
+ {
187
+ anonymous: false,
188
+ inputs: [
189
+ {
190
+ indexed: true,
191
+ name: 'cancelledGov',
192
+ type: 'address',
193
+ },
194
+ {
195
+ indexed: false,
196
+ name: 'initiatedBlock',
197
+ type: 'uint256',
198
+ },
199
+ {
200
+ indexed: false,
201
+ name: 'confirmBlock',
202
+ type: 'uint256',
203
+ },
204
+ ],
205
+ name: 'GovChangeCancelled',
206
+ type: 'event',
207
+ },
208
+ {
209
+ anonymous: false,
210
+ inputs: [
211
+ {
212
+ indexed: false,
213
+ name: 'delayBlocks',
214
+ type: 'uint256',
215
+ },
216
+ ],
217
+ name: 'GovChangeDelaySet',
218
+ type: 'event',
219
+ },
220
+ {
221
+ anonymous: false,
222
+ inputs: [
223
+ {
224
+ indexed: true,
225
+ name: 'asset',
226
+ type: 'address',
227
+ },
228
+ {
229
+ indexed: true,
230
+ name: 'vaultToken',
231
+ type: 'address',
232
+ },
233
+ ],
234
+ name: 'AssetOpportunityAdded',
235
+ type: 'event',
236
+ },
237
+ {
238
+ anonymous: false,
239
+ inputs: [
240
+ {
241
+ indexed: true,
242
+ name: 'asset',
243
+ type: 'address',
244
+ },
245
+ {
246
+ indexed: true,
247
+ name: 'vaultToken',
248
+ type: 'address',
249
+ },
250
+ ],
251
+ name: 'AssetOpportunityRemoved',
252
+ type: 'event',
253
+ },
254
+ {
255
+ inputs: [
256
+ {
257
+ name: '_asset',
258
+ type: 'address',
259
+ },
260
+ ],
261
+ name: 'getAssetOpportunities',
262
+ outputs: [
263
+ {
264
+ name: '',
265
+ type: 'address[]',
266
+ },
267
+ ],
268
+ stateMutability: 'view',
269
+ type: 'function',
270
+ },
271
+ {
272
+ inputs: [],
273
+ name: 'getAssets',
274
+ outputs: [
275
+ {
276
+ name: '',
277
+ type: 'address[]',
278
+ },
279
+ ],
280
+ stateMutability: 'view',
281
+ type: 'function',
282
+ },
283
+ {
284
+ inputs: [
285
+ {
286
+ name: 'arg0',
287
+ type: 'address',
288
+ },
289
+ {
290
+ name: 'arg1',
291
+ type: 'uint256',
292
+ },
293
+ ],
294
+ name: 'assetOpportunities',
295
+ outputs: [
296
+ {
297
+ name: '',
298
+ type: 'address',
299
+ },
300
+ ],
301
+ stateMutability: 'view',
302
+ type: 'function',
303
+ },
304
+ {
305
+ inputs: [
306
+ {
307
+ name: 'arg0',
308
+ type: 'address',
309
+ },
310
+ {
311
+ name: 'arg1',
312
+ type: 'address',
313
+ },
314
+ ],
315
+ name: 'indexOfAssetOpportunity',
316
+ outputs: [
317
+ {
318
+ name: '',
319
+ type: 'uint256',
320
+ },
321
+ ],
322
+ stateMutability: 'view',
323
+ type: 'function',
324
+ },
325
+ {
326
+ inputs: [
327
+ {
328
+ name: 'arg0',
329
+ type: 'address',
330
+ },
331
+ ],
332
+ name: 'numAssetOpportunities',
333
+ outputs: [
334
+ {
335
+ name: '',
336
+ type: 'uint256',
337
+ },
338
+ ],
339
+ stateMutability: 'view',
340
+ type: 'function',
341
+ },
342
+ {
343
+ inputs: [
344
+ {
345
+ name: 'arg0',
346
+ type: 'address',
347
+ },
348
+ ],
349
+ name: 'vaultToAsset',
350
+ outputs: [
351
+ {
352
+ name: '',
353
+ type: 'address',
354
+ },
355
+ ],
356
+ stateMutability: 'view',
357
+ type: 'function',
358
+ },
359
+ {
360
+ inputs: [
361
+ {
362
+ name: 'arg0',
363
+ type: 'uint256',
364
+ },
365
+ ],
366
+ name: 'assets',
367
+ outputs: [
368
+ {
369
+ name: '',
370
+ type: 'address',
371
+ },
372
+ ],
373
+ stateMutability: 'view',
374
+ type: 'function',
375
+ },
376
+ {
377
+ inputs: [
378
+ {
379
+ name: 'arg0',
380
+ type: 'address',
381
+ },
382
+ ],
383
+ name: 'indexOfAsset',
384
+ outputs: [
385
+ {
386
+ name: '',
387
+ type: 'uint256',
388
+ },
389
+ ],
390
+ stateMutability: 'view',
391
+ type: 'function',
392
+ },
393
+ {
394
+ inputs: [],
395
+ name: 'numAssets',
396
+ outputs: [
397
+ {
398
+ name: '',
399
+ type: 'uint256',
400
+ },
401
+ ],
402
+ stateMutability: 'view',
403
+ type: 'function',
404
+ },
405
+ {
406
+ inputs: [
407
+ {
408
+ name: '_address',
409
+ type: 'address',
410
+ },
411
+ ],
412
+ name: 'canGovern',
413
+ outputs: [
414
+ {
415
+ name: '',
416
+ type: 'bool',
417
+ },
418
+ ],
419
+ stateMutability: 'view',
420
+ type: 'function',
421
+ },
422
+ {
423
+ inputs: [],
424
+ name: 'hasPendingGovChange',
425
+ outputs: [
426
+ {
427
+ name: '',
428
+ type: 'bool',
429
+ },
430
+ ],
431
+ stateMutability: 'view',
432
+ type: 'function',
433
+ },
434
+ {
435
+ inputs: [
436
+ {
437
+ name: '_newGov',
438
+ type: 'address',
439
+ },
440
+ ],
441
+ name: 'changeGovernance',
442
+ outputs: [],
443
+ stateMutability: 'nonpayable',
444
+ type: 'function',
445
+ },
446
+ {
447
+ inputs: [],
448
+ name: 'confirmGovernanceChange',
449
+ outputs: [],
450
+ stateMutability: 'nonpayable',
451
+ type: 'function',
452
+ },
453
+ {
454
+ inputs: [],
455
+ name: 'cancelGovernanceChange',
456
+ outputs: [],
457
+ stateMutability: 'nonpayable',
458
+ type: 'function',
459
+ },
460
+ {
461
+ inputs: [
462
+ {
463
+ name: '_numBlocks',
464
+ type: 'uint256',
465
+ },
466
+ ],
467
+ name: 'setGovernanceChangeDelay',
468
+ outputs: [],
469
+ stateMutability: 'nonpayable',
470
+ type: 'function',
471
+ },
472
+ {
473
+ inputs: [],
474
+ name: 'governance',
475
+ outputs: [
476
+ {
477
+ name: '',
478
+ type: 'address',
479
+ },
480
+ ],
481
+ stateMutability: 'view',
482
+ type: 'function',
483
+ },
484
+ {
485
+ inputs: [],
486
+ name: 'pendingGov',
487
+ outputs: [
488
+ {
489
+ components: [
490
+ {
491
+ name: 'newGov',
492
+ type: 'address',
493
+ },
494
+ {
495
+ name: 'initiatedBlock',
496
+ type: 'uint256',
497
+ },
498
+ {
499
+ name: 'confirmBlock',
500
+ type: 'uint256',
501
+ },
502
+ ],
503
+ name: '',
504
+ type: 'tuple',
505
+ },
506
+ ],
507
+ stateMutability: 'view',
508
+ type: 'function',
509
+ },
510
+ {
511
+ inputs: [],
512
+ name: 'govChangeDelay',
513
+ outputs: [
514
+ {
515
+ name: '',
516
+ type: 'uint256',
517
+ },
518
+ ],
519
+ stateMutability: 'view',
520
+ type: 'function',
521
+ },
522
+ {
523
+ inputs: [],
524
+ name: 'MIN_GOV_CHANGE_DELAY',
525
+ outputs: [
526
+ {
527
+ name: '',
528
+ type: 'uint256',
529
+ },
530
+ ],
531
+ stateMutability: 'view',
532
+ type: 'function',
533
+ },
534
+ {
535
+ inputs: [],
536
+ name: 'MAX_GOV_CHANGE_DELAY',
537
+ outputs: [
538
+ {
539
+ name: '',
540
+ type: 'uint256',
541
+ },
542
+ ],
543
+ stateMutability: 'view',
544
+ type: 'function',
545
+ },
546
+ {
547
+ inputs: [],
548
+ name: 'getRegistries',
549
+ outputs: [
550
+ {
551
+ name: '',
552
+ type: 'address[]',
553
+ },
554
+ ],
555
+ stateMutability: 'view',
556
+ type: 'function',
557
+ },
558
+ {
559
+ inputs: [
560
+ {
561
+ name: '_user',
562
+ type: 'address',
563
+ },
564
+ ],
565
+ name: 'getAccessForLego',
566
+ outputs: [
567
+ {
568
+ name: '',
569
+ type: 'address',
570
+ },
571
+ {
572
+ name: '',
573
+ type: 'string',
574
+ },
575
+ {
576
+ name: '',
577
+ type: 'uint256',
578
+ },
579
+ ],
580
+ stateMutability: 'view',
581
+ type: 'function',
582
+ },
583
+ {
584
+ inputs: [
585
+ {
586
+ name: '_vaultToken',
587
+ type: 'address',
588
+ },
589
+ ],
590
+ name: 'isVaultToken',
591
+ outputs: [
592
+ {
593
+ name: '',
594
+ type: 'bool',
595
+ },
596
+ ],
597
+ stateMutability: 'view',
598
+ type: 'function',
599
+ },
600
+ {
601
+ inputs: [
602
+ {
603
+ name: '_vaultToken',
604
+ type: 'address',
605
+ },
606
+ ],
607
+ name: 'getUnderlyingAsset',
608
+ outputs: [
609
+ {
610
+ name: '',
611
+ type: 'address',
612
+ },
613
+ ],
614
+ stateMutability: 'view',
615
+ type: 'function',
616
+ },
617
+ {
618
+ inputs: [
619
+ {
620
+ name: '_vaultToken',
621
+ type: 'address',
622
+ },
623
+ {
624
+ name: '_vaultTokenAmount',
625
+ type: 'uint256',
626
+ },
627
+ ],
628
+ name: 'getUnderlyingAmount',
629
+ outputs: [
630
+ {
631
+ name: '',
632
+ type: 'uint256',
633
+ },
634
+ ],
635
+ stateMutability: 'view',
636
+ type: 'function',
637
+ },
638
+ {
639
+ inputs: [
640
+ {
641
+ name: '_asset',
642
+ type: 'address',
643
+ },
644
+ {
645
+ name: '_assetAmount',
646
+ type: 'uint256',
647
+ },
648
+ {
649
+ name: '_vaultToken',
650
+ type: 'address',
651
+ },
652
+ ],
653
+ name: 'getVaultTokenAmount',
654
+ outputs: [
655
+ {
656
+ name: '',
657
+ type: 'uint256',
658
+ },
659
+ ],
660
+ stateMutability: 'view',
661
+ type: 'function',
662
+ },
663
+ {
664
+ inputs: [
665
+ {
666
+ name: '_vaultToken',
667
+ type: 'address',
668
+ },
669
+ {
670
+ name: '_vaultTokenAmount',
671
+ type: 'uint256',
672
+ },
673
+ ],
674
+ name: 'getUsdValueOfVaultToken',
675
+ outputs: [
676
+ {
677
+ name: '',
678
+ type: 'uint256',
679
+ },
680
+ ],
681
+ stateMutability: 'view',
682
+ type: 'function',
683
+ },
684
+ {
685
+ inputs: [
686
+ {
687
+ name: '_vaultToken',
688
+ type: 'address',
689
+ },
690
+ {
691
+ name: '_vaultTokenAmount',
692
+ type: 'uint256',
693
+ },
694
+ {
695
+ name: '_oracleRegistry',
696
+ type: 'address',
697
+ },
698
+ ],
699
+ name: 'getUsdValueOfVaultToken',
700
+ outputs: [
701
+ {
702
+ name: '',
703
+ type: 'uint256',
704
+ },
705
+ ],
706
+ stateMutability: 'view',
707
+ type: 'function',
708
+ },
709
+ {
710
+ inputs: [
711
+ {
712
+ name: '_vaultToken',
713
+ type: 'address',
714
+ },
715
+ {
716
+ name: '_vaultTokenAmount',
717
+ type: 'uint256',
718
+ },
719
+ ],
720
+ name: 'getUnderlyingData',
721
+ outputs: [
722
+ {
723
+ name: '',
724
+ type: 'address',
725
+ },
726
+ {
727
+ name: '',
728
+ type: 'uint256',
729
+ },
730
+ {
731
+ name: '',
732
+ type: 'uint256',
733
+ },
734
+ ],
735
+ stateMutability: 'view',
736
+ type: 'function',
737
+ },
738
+ {
739
+ inputs: [
740
+ {
741
+ name: '_vaultToken',
742
+ type: 'address',
743
+ },
744
+ {
745
+ name: '_vaultTokenAmount',
746
+ type: 'uint256',
747
+ },
748
+ {
749
+ name: '_oracleRegistry',
750
+ type: 'address',
751
+ },
752
+ ],
753
+ name: 'getUnderlyingData',
754
+ outputs: [
755
+ {
756
+ name: '',
757
+ type: 'address',
758
+ },
759
+ {
760
+ name: '',
761
+ type: 'uint256',
762
+ },
763
+ {
764
+ name: '',
765
+ type: 'uint256',
766
+ },
767
+ ],
768
+ stateMutability: 'view',
769
+ type: 'function',
770
+ },
771
+ {
772
+ inputs: [
773
+ {
774
+ name: '_vaultToken',
775
+ type: 'address',
776
+ },
777
+ ],
778
+ name: 'totalAssets',
779
+ outputs: [
780
+ {
781
+ name: '',
782
+ type: 'uint256',
783
+ },
784
+ ],
785
+ stateMutability: 'view',
786
+ type: 'function',
787
+ },
788
+ {
789
+ inputs: [
790
+ {
791
+ name: '_vaultToken',
792
+ type: 'address',
793
+ },
794
+ ],
795
+ name: 'totalBorrows',
796
+ outputs: [
797
+ {
798
+ name: '',
799
+ type: 'uint256',
800
+ },
801
+ ],
802
+ stateMutability: 'view',
803
+ type: 'function',
804
+ },
805
+ {
806
+ inputs: [
807
+ {
808
+ name: '_asset',
809
+ type: 'address',
810
+ },
811
+ {
812
+ name: '_amount',
813
+ type: 'uint256',
814
+ },
815
+ {
816
+ name: '_vault',
817
+ type: 'address',
818
+ },
819
+ {
820
+ name: '_recipient',
821
+ type: 'address',
822
+ },
823
+ ],
824
+ name: 'depositTokens',
825
+ outputs: [
826
+ {
827
+ name: '',
828
+ type: 'uint256',
829
+ },
830
+ {
831
+ name: '',
832
+ type: 'address',
833
+ },
834
+ {
835
+ name: '',
836
+ type: 'uint256',
837
+ },
838
+ {
839
+ name: '',
840
+ type: 'uint256',
841
+ },
842
+ {
843
+ name: '',
844
+ type: 'uint256',
845
+ },
846
+ ],
847
+ stateMutability: 'nonpayable',
848
+ type: 'function',
849
+ },
850
+ {
851
+ inputs: [
852
+ {
853
+ name: '_asset',
854
+ type: 'address',
855
+ },
856
+ {
857
+ name: '_amount',
858
+ type: 'uint256',
859
+ },
860
+ {
861
+ name: '_vault',
862
+ type: 'address',
863
+ },
864
+ {
865
+ name: '_recipient',
866
+ type: 'address',
867
+ },
868
+ {
869
+ name: '_oracleRegistry',
870
+ type: 'address',
871
+ },
872
+ ],
873
+ name: 'depositTokens',
874
+ outputs: [
875
+ {
876
+ name: '',
877
+ type: 'uint256',
878
+ },
879
+ {
880
+ name: '',
881
+ type: 'address',
882
+ },
883
+ {
884
+ name: '',
885
+ type: 'uint256',
886
+ },
887
+ {
888
+ name: '',
889
+ type: 'uint256',
890
+ },
891
+ {
892
+ name: '',
893
+ type: 'uint256',
894
+ },
895
+ ],
896
+ stateMutability: 'nonpayable',
897
+ type: 'function',
898
+ },
899
+ {
900
+ inputs: [
901
+ {
902
+ name: '_asset',
903
+ type: 'address',
904
+ },
905
+ {
906
+ name: '_amount',
907
+ type: 'uint256',
908
+ },
909
+ {
910
+ name: '_vaultToken',
911
+ type: 'address',
912
+ },
913
+ {
914
+ name: '_recipient',
915
+ type: 'address',
916
+ },
917
+ ],
918
+ name: 'withdrawTokens',
919
+ outputs: [
920
+ {
921
+ name: '',
922
+ type: 'uint256',
923
+ },
924
+ {
925
+ name: '',
926
+ type: 'uint256',
927
+ },
928
+ {
929
+ name: '',
930
+ type: 'uint256',
931
+ },
932
+ {
933
+ name: '',
934
+ type: 'uint256',
935
+ },
936
+ ],
937
+ stateMutability: 'nonpayable',
938
+ type: 'function',
939
+ },
940
+ {
941
+ inputs: [
942
+ {
943
+ name: '_asset',
944
+ type: 'address',
945
+ },
946
+ {
947
+ name: '_amount',
948
+ type: 'uint256',
949
+ },
950
+ {
951
+ name: '_vaultToken',
952
+ type: 'address',
953
+ },
954
+ {
955
+ name: '_recipient',
956
+ type: 'address',
957
+ },
958
+ {
959
+ name: '_oracleRegistry',
960
+ type: 'address',
961
+ },
962
+ ],
963
+ name: 'withdrawTokens',
964
+ outputs: [
965
+ {
966
+ name: '',
967
+ type: 'uint256',
968
+ },
969
+ {
970
+ name: '',
971
+ type: 'uint256',
972
+ },
973
+ {
974
+ name: '',
975
+ type: 'uint256',
976
+ },
977
+ {
978
+ name: '',
979
+ type: 'uint256',
980
+ },
981
+ ],
982
+ stateMutability: 'nonpayable',
983
+ type: 'function',
984
+ },
985
+ {
986
+ inputs: [
987
+ {
988
+ name: '_user',
989
+ type: 'address',
990
+ },
991
+ {
992
+ name: '_market',
993
+ type: 'address',
994
+ },
995
+ {
996
+ name: '_rewardToken',
997
+ type: 'address',
998
+ },
999
+ {
1000
+ name: '_rewardAmount',
1001
+ type: 'uint256',
1002
+ },
1003
+ {
1004
+ name: '_proof',
1005
+ type: 'bytes32',
1006
+ },
1007
+ ],
1008
+ name: 'claimRewards',
1009
+ outputs: [],
1010
+ stateMutability: 'nonpayable',
1011
+ type: 'function',
1012
+ },
1013
+ {
1014
+ inputs: [
1015
+ {
1016
+ name: '_user',
1017
+ type: 'address',
1018
+ },
1019
+ ],
1020
+ name: 'hasClaimableRewards',
1021
+ outputs: [
1022
+ {
1023
+ name: '',
1024
+ type: 'bool',
1025
+ },
1026
+ ],
1027
+ stateMutability: 'view',
1028
+ type: 'function',
1029
+ },
1030
+ {
1031
+ inputs: [
1032
+ {
1033
+ name: '_asset',
1034
+ type: 'address',
1035
+ },
1036
+ {
1037
+ name: '_vault',
1038
+ type: 'address',
1039
+ },
1040
+ ],
1041
+ name: 'addAssetOpportunity',
1042
+ outputs: [
1043
+ {
1044
+ name: '',
1045
+ type: 'bool',
1046
+ },
1047
+ ],
1048
+ stateMutability: 'nonpayable',
1049
+ type: 'function',
1050
+ },
1051
+ {
1052
+ inputs: [
1053
+ {
1054
+ name: '_asset',
1055
+ type: 'address',
1056
+ },
1057
+ {
1058
+ name: '_vault',
1059
+ type: 'address',
1060
+ },
1061
+ ],
1062
+ name: 'removeAssetOpportunity',
1063
+ outputs: [
1064
+ {
1065
+ name: '',
1066
+ type: 'bool',
1067
+ },
1068
+ ],
1069
+ stateMutability: 'nonpayable',
1070
+ type: 'function',
1071
+ },
1072
+ {
1073
+ inputs: [
1074
+ {
1075
+ name: '_asset',
1076
+ type: 'address',
1077
+ },
1078
+ {
1079
+ name: '_recipient',
1080
+ type: 'address',
1081
+ },
1082
+ ],
1083
+ name: 'recoverFunds',
1084
+ outputs: [
1085
+ {
1086
+ name: '',
1087
+ type: 'bool',
1088
+ },
1089
+ ],
1090
+ stateMutability: 'nonpayable',
1091
+ type: 'function',
1092
+ },
1093
+ {
1094
+ inputs: [
1095
+ {
1096
+ name: '_legoId',
1097
+ type: 'uint256',
1098
+ },
1099
+ ],
1100
+ name: 'setLegoId',
1101
+ outputs: [
1102
+ {
1103
+ name: '',
1104
+ type: 'bool',
1105
+ },
1106
+ ],
1107
+ stateMutability: 'nonpayable',
1108
+ type: 'function',
1109
+ },
1110
+ {
1111
+ inputs: [
1112
+ {
1113
+ name: '_shouldActivate',
1114
+ type: 'bool',
1115
+ },
1116
+ ],
1117
+ name: 'activate',
1118
+ outputs: [],
1119
+ stateMutability: 'nonpayable',
1120
+ type: 'function',
1121
+ },
1122
+ {
1123
+ inputs: [],
1124
+ name: 'FLUID_RESOLVER',
1125
+ outputs: [
1126
+ {
1127
+ name: '',
1128
+ type: 'address',
1129
+ },
1130
+ ],
1131
+ stateMutability: 'view',
1132
+ type: 'function',
1133
+ },
1134
+ {
1135
+ inputs: [],
1136
+ name: 'legoId',
1137
+ outputs: [
1138
+ {
1139
+ name: '',
1140
+ type: 'uint256',
1141
+ },
1142
+ ],
1143
+ stateMutability: 'view',
1144
+ type: 'function',
1145
+ },
1146
+ {
1147
+ inputs: [],
1148
+ name: 'isActivated',
1149
+ outputs: [
1150
+ {
1151
+ name: '',
1152
+ type: 'bool',
1153
+ },
1154
+ ],
1155
+ stateMutability: 'view',
1156
+ type: 'function',
1157
+ },
1158
+ {
1159
+ inputs: [],
1160
+ name: 'ADDY_REGISTRY',
1161
+ outputs: [
1162
+ {
1163
+ name: '',
1164
+ type: 'address',
1165
+ },
1166
+ ],
1167
+ stateMutability: 'view',
1168
+ type: 'function',
1169
+ },
1170
+ {
1171
+ inputs: [
1172
+ {
1173
+ name: '_fluidResolver',
1174
+ type: 'address',
1175
+ },
1176
+ {
1177
+ name: '_addyRegistry',
1178
+ type: 'address',
1179
+ },
1180
+ ],
1181
+ outputs: [],
1182
+ stateMutability: 'nonpayable',
1183
+ type: 'constructor',
1184
+ },
1185
+ ];
1186
+ export const deployAddress = '0xc4a864F5543D3CDB06D5F3419c18315f2cDe9675';
1187
+ function getRequest(method, args, contractAddressOrOptions) {
1188
+ const address = typeof contractAddressOrOptions === 'string' ? contractAddressOrOptions : contractAddressOrOptions?.contractAddress;
1189
+ const defaultValue = typeof contractAddressOrOptions === 'string' ? undefined : contractAddressOrOptions?.defaultValue;
1190
+ const call = {
1191
+ contractName: 'v0_3_LegoFluid',
1192
+ method,
1193
+ args,
1194
+ address,
1195
+ deployAddress,
1196
+ defaultValue,
1197
+ getAbi: () => abi,
1198
+ with: (options) => {
1199
+ call.address = options.contractAddress;
1200
+ call.defaultValue = options.defaultValue;
1201
+ return call;
1202
+ },
1203
+ defaultTo: (defaultValue) => {
1204
+ call.defaultValue = defaultValue;
1205
+ return call;
1206
+ },
1207
+ at: (address) => {
1208
+ call.address = address;
1209
+ return call;
1210
+ },
1211
+ };
1212
+ return call;
1213
+ }
1214
+ export const call = {
1215
+ getAssetOpportunities: (...args) => getRequest('getAssetOpportunities', args),
1216
+ getAssets: (...args) => getRequest('getAssets', args),
1217
+ assetOpportunities: (...args) => getRequest('assetOpportunities', args),
1218
+ indexOfAssetOpportunity: (...args) => getRequest('indexOfAssetOpportunity', args),
1219
+ numAssetOpportunities: (...args) => getRequest('numAssetOpportunities', args),
1220
+ vaultToAsset: (...args) => getRequest('vaultToAsset', args),
1221
+ assets: (...args) => getRequest('assets', args),
1222
+ indexOfAsset: (...args) => getRequest('indexOfAsset', args),
1223
+ numAssets: (...args) => getRequest('numAssets', args),
1224
+ canGovern: (...args) => getRequest('canGovern', args),
1225
+ hasPendingGovChange: (...args) => getRequest('hasPendingGovChange', args),
1226
+ governance: (...args) => getRequest('governance', args),
1227
+ pendingGov: (...args) => getRequest('pendingGov', args),
1228
+ govChangeDelay: (...args) => getRequest('govChangeDelay', args),
1229
+ MIN_GOV_CHANGE_DELAY: (...args) => getRequest('MIN_GOV_CHANGE_DELAY', args),
1230
+ MAX_GOV_CHANGE_DELAY: (...args) => getRequest('MAX_GOV_CHANGE_DELAY', args),
1231
+ getRegistries: (...args) => getRequest('getRegistries', args),
1232
+ getAccessForLego: (...args) => getRequest('getAccessForLego', args),
1233
+ isVaultToken: (...args) => getRequest('isVaultToken', args),
1234
+ getUnderlyingAsset: (...args) => getRequest('getUnderlyingAsset', args),
1235
+ getUnderlyingAmount: (...args) => getRequest('getUnderlyingAmount', args),
1236
+ getVaultTokenAmount: (...args) => getRequest('getVaultTokenAmount', args),
1237
+ getUsdValueOfVaultToken: (...args) => getRequest('getUsdValueOfVaultToken', args),
1238
+ getUnderlyingData: (...args) => getRequest('getUnderlyingData', args),
1239
+ totalAssets: (...args) => getRequest('totalAssets', args),
1240
+ totalBorrows: (...args) => getRequest('totalBorrows', args),
1241
+ hasClaimableRewards: (...args) => getRequest('hasClaimableRewards', args),
1242
+ FLUID_RESOLVER: (...args) => getRequest('FLUID_RESOLVER', args),
1243
+ legoId: (...args) => getRequest('legoId', args),
1244
+ isActivated: (...args) => getRequest('isActivated', args),
1245
+ ADDY_REGISTRY: (...args) => getRequest('ADDY_REGISTRY', args),
1246
+ };
1247
+ function getMutation(functionName) {
1248
+ return {
1249
+ contractName: 'v0_3_LegoFluid',
1250
+ functionName,
1251
+ deployAddress,
1252
+ argsType: undefined,
1253
+ getAbi: () => abi,
1254
+ };
1255
+ }
1256
+ export const mutation = {
1257
+ changeGovernance: getMutation('changeGovernance'),
1258
+ confirmGovernanceChange: getMutation('confirmGovernanceChange'),
1259
+ cancelGovernanceChange: getMutation('cancelGovernanceChange'),
1260
+ setGovernanceChangeDelay: getMutation('setGovernanceChangeDelay'),
1261
+ depositTokens: getMutation('depositTokens'),
1262
+ withdrawTokens: getMutation('withdrawTokens'),
1263
+ claimRewards: getMutation('claimRewards'),
1264
+ addAssetOpportunity: getMutation('addAssetOpportunity'),
1265
+ removeAssetOpportunity: getMutation('removeAssetOpportunity'),
1266
+ recoverFunds: getMutation('recoverFunds'),
1267
+ setLegoId: getMutation('setLegoId'),
1268
+ activate: getMutation('activate'),
1269
+ };
1270
+ export function toSdk(publicClient, walletClient) {
1271
+ return {
1272
+ deployAddress,
1273
+ abi,
1274
+ // Queries
1275
+ getAssetOpportunities: (...args) => singleQuery(publicClient, call.getAssetOpportunities(...args)),
1276
+ getAssets: (...args) => singleQuery(publicClient, call.getAssets(...args)),
1277
+ assetOpportunities: (...args) => singleQuery(publicClient, call.assetOpportunities(...args)),
1278
+ indexOfAssetOpportunity: (...args) => singleQuery(publicClient, call.indexOfAssetOpportunity(...args)),
1279
+ numAssetOpportunities: (...args) => singleQuery(publicClient, call.numAssetOpportunities(...args)),
1280
+ vaultToAsset: (...args) => singleQuery(publicClient, call.vaultToAsset(...args)),
1281
+ assets: (...args) => singleQuery(publicClient, call.assets(...args)),
1282
+ indexOfAsset: (...args) => singleQuery(publicClient, call.indexOfAsset(...args)),
1283
+ numAssets: (...args) => singleQuery(publicClient, call.numAssets(...args)),
1284
+ canGovern: (...args) => singleQuery(publicClient, call.canGovern(...args)),
1285
+ hasPendingGovChange: (...args) => singleQuery(publicClient, call.hasPendingGovChange(...args)),
1286
+ governance: (...args) => singleQuery(publicClient, call.governance(...args)),
1287
+ pendingGov: (...args) => singleQuery(publicClient, call.pendingGov(...args)),
1288
+ govChangeDelay: (...args) => singleQuery(publicClient, call.govChangeDelay(...args)),
1289
+ MIN_GOV_CHANGE_DELAY: (...args) => singleQuery(publicClient, call.MIN_GOV_CHANGE_DELAY(...args)),
1290
+ MAX_GOV_CHANGE_DELAY: (...args) => singleQuery(publicClient, call.MAX_GOV_CHANGE_DELAY(...args)),
1291
+ getRegistries: (...args) => singleQuery(publicClient, call.getRegistries(...args)),
1292
+ getAccessForLego: (...args) => singleQuery(publicClient, call.getAccessForLego(...args)),
1293
+ isVaultToken: (...args) => singleQuery(publicClient, call.isVaultToken(...args)),
1294
+ getUnderlyingAsset: (...args) => singleQuery(publicClient, call.getUnderlyingAsset(...args)),
1295
+ getUnderlyingAmount: (...args) => singleQuery(publicClient, call.getUnderlyingAmount(...args)),
1296
+ getVaultTokenAmount: (...args) => singleQuery(publicClient, call.getVaultTokenAmount(...args)),
1297
+ getUsdValueOfVaultToken: (...args) => singleQuery(publicClient, call.getUsdValueOfVaultToken(...args)),
1298
+ getUnderlyingData: (...args) => singleQuery(publicClient, call.getUnderlyingData(...args)),
1299
+ totalAssets: (...args) => singleQuery(publicClient, call.totalAssets(...args)),
1300
+ totalBorrows: (...args) => singleQuery(publicClient, call.totalBorrows(...args)),
1301
+ hasClaimableRewards: (...args) => singleQuery(publicClient, call.hasClaimableRewards(...args)),
1302
+ FLUID_RESOLVER: (...args) => singleQuery(publicClient, call.FLUID_RESOLVER(...args)),
1303
+ legoId: (...args) => singleQuery(publicClient, call.legoId(...args)),
1304
+ isActivated: (...args) => singleQuery(publicClient, call.isActivated(...args)),
1305
+ ADDY_REGISTRY: (...args) => singleQuery(publicClient, call.ADDY_REGISTRY(...args)),
1306
+ // Mutations
1307
+ changeGovernance: (...args) => mutate(walletClient, mutation.changeGovernance)(...args),
1308
+ confirmGovernanceChange: (...args) => mutate(walletClient, mutation.confirmGovernanceChange)(...args),
1309
+ cancelGovernanceChange: (...args) => mutate(walletClient, mutation.cancelGovernanceChange)(...args),
1310
+ setGovernanceChangeDelay: (...args) => mutate(walletClient, mutation.setGovernanceChangeDelay)(...args),
1311
+ depositTokens: (...args) => mutate(walletClient, mutation.depositTokens)(...args),
1312
+ withdrawTokens: (...args) => mutate(walletClient, mutation.withdrawTokens)(...args),
1313
+ claimRewards: (...args) => mutate(walletClient, mutation.claimRewards)(...args),
1314
+ addAssetOpportunity: (...args) => mutate(walletClient, mutation.addAssetOpportunity)(...args),
1315
+ removeAssetOpportunity: (...args) => mutate(walletClient, mutation.removeAssetOpportunity)(...args),
1316
+ recoverFunds: (...args) => mutate(walletClient, mutation.recoverFunds)(...args),
1317
+ setLegoId: (...args) => mutate(walletClient, mutation.setLegoId)(...args),
1318
+ activate: (...args) => mutate(walletClient, mutation.activate)(...args),
1319
+ };
1320
+ }