@defisaver/automation-sdk 3.1.9 → 3.1.14-spark-dev
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.
- package/.babelrc +3 -3
- package/.editorconfig +9 -9
- package/.env.dev +4 -4
- package/.eslintignore +6 -6
- package/.eslintrc.js +39 -39
- package/.mocharc.json +4 -4
- package/.nvmrc +1 -1
- package/README.md +46 -46
- package/cjs/abis/Erc20.json +223 -223
- package/cjs/abis/SubStorage.json +21 -21
- package/cjs/abis/UniMulticall.json +17 -17
- package/cjs/abis/index.d.ts +9 -9
- package/cjs/abis/index.js +30 -30
- package/cjs/abis/legacy_AaveV2Subscriptions.json +8 -8
- package/cjs/abis/legacy_AuthCheck.json +8 -8
- package/cjs/abis/legacy_CompoundV2Subscriptions.json +9 -9
- package/cjs/abis/legacy_MakerSubscriptions.json +9 -9
- package/cjs/automation/private/Automation.d.ts +12 -12
- package/cjs/automation/private/Automation.js +42 -42
- package/cjs/automation/private/LegacyAutomation.d.ts +25 -25
- package/cjs/automation/private/LegacyAutomation.js +118 -118
- package/cjs/automation/private/LegacyProtocol.d.ts +22 -22
- package/cjs/automation/private/LegacyProtocol.js +41 -41
- package/cjs/automation/private/LegacyProtocol.test.d.ts +1 -1
- package/cjs/automation/private/LegacyProtocol.test.js +25 -25
- package/cjs/automation/private/Protocol.d.ts +22 -22
- package/cjs/automation/private/Protocol.js +41 -41
- package/cjs/automation/private/Protocol.test.d.ts +1 -1
- package/cjs/automation/private/Protocol.test.js +25 -25
- package/cjs/automation/private/StrategiesAutomation.d.ts +35 -33
- package/cjs/automation/private/StrategiesAutomation.js +198 -181
- package/cjs/automation/private/StrategiesAutomation.test.d.ts +1 -1
- package/cjs/automation/private/StrategiesAutomation.test.js +696 -671
- package/cjs/automation/public/ArbitrumStrategies.d.ts +5 -5
- package/cjs/automation/public/ArbitrumStrategies.js +13 -13
- package/cjs/automation/public/BaseStrategies.d.ts +5 -5
- package/cjs/automation/public/BaseStrategies.js +13 -13
- package/cjs/automation/public/EthereumStrategies.d.ts +5 -5
- package/cjs/automation/public/EthereumStrategies.js +13 -13
- package/cjs/automation/public/OptimismStrategies.d.ts +5 -5
- package/cjs/automation/public/OptimismStrategies.js +13 -13
- package/cjs/automation/public/Strategies.test.d.ts +1 -1
- package/cjs/automation/public/Strategies.test.js +61 -61
- package/cjs/automation/public/legacy/LegacyAaveAutomation.d.ts +6 -6
- package/cjs/automation/public/legacy/LegacyAaveAutomation.js +20 -20
- package/cjs/automation/public/legacy/LegacyCompoundAutomation.d.ts +6 -6
- package/cjs/automation/public/legacy/LegacyCompoundAutomation.js +20 -20
- package/cjs/automation/public/legacy/LegacyMakerAutomation.d.ts +6 -6
- package/cjs/automation/public/legacy/LegacyMakerAutomation.js +20 -20
- package/cjs/configuration.d.ts +1 -1
- package/cjs/configuration.js +12 -12
- package/cjs/constants/index.d.ts +29 -28
- package/cjs/constants/index.js +905 -534
- package/cjs/index.d.ts +24 -23
- package/cjs/index.js +65 -65
- package/cjs/services/contractService.d.ts +12 -12
- package/cjs/services/contractService.js +54 -54
- package/cjs/services/ethereumService.d.ts +7 -7
- package/cjs/services/ethereumService.js +56 -49
- package/cjs/services/ethereumService.test.d.ts +1 -1
- package/cjs/services/ethereumService.test.js +245 -242
- package/cjs/services/strategiesService.d.ts +2 -2
- package/cjs/services/strategiesService.js +1173 -861
- package/cjs/services/strategiesService.test.d.ts +1 -1
- package/cjs/services/strategiesService.test.js +111 -110
- package/cjs/services/strategySubService.d.ts +129 -107
- package/cjs/services/strategySubService.js +414 -300
- package/cjs/services/strategySubService.test.d.ts +1 -1
- package/cjs/services/strategySubService.test.js +1812 -936
- package/cjs/services/subDataService.d.ts +527 -245
- package/cjs/services/subDataService.js +1219 -636
- package/cjs/services/subDataService.test.d.ts +1 -1
- package/cjs/services/subDataService.test.js +2427 -1282
- package/cjs/services/triggerService.d.ts +325 -226
- package/cjs/services/triggerService.js +616 -433
- package/cjs/services/triggerService.test.d.ts +1 -1
- package/cjs/services/triggerService.test.js +1317 -926
- package/cjs/services/utils.d.ts +30 -30
- package/cjs/services/utils.js +190 -182
- package/cjs/services/utils.test.d.ts +1 -1
- package/cjs/services/utils.test.js +299 -376
- package/cjs/types/contracts/generated/Erc20.d.ts +53 -53
- package/cjs/types/contracts/generated/Erc20.js +5 -5
- package/cjs/types/contracts/generated/Legacy_AaveV2Subscriptions.d.ts +129 -129
- package/cjs/types/contracts/generated/Legacy_AaveV2Subscriptions.js +5 -5
- package/cjs/types/contracts/generated/Legacy_AuthCheck.d.ts +20 -20
- package/cjs/types/contracts/generated/Legacy_AuthCheck.js +5 -5
- package/cjs/types/contracts/generated/Legacy_CompoundV2Subscriptions.d.ts +128 -128
- package/cjs/types/contracts/generated/Legacy_CompoundV2Subscriptions.js +5 -5
- package/cjs/types/contracts/generated/Legacy_MakerSubscriptions.d.ts +246 -246
- package/cjs/types/contracts/generated/Legacy_MakerSubscriptions.js +5 -5
- package/cjs/types/contracts/generated/SubStorage.d.ts +114 -114
- package/cjs/types/contracts/generated/SubStorage.js +5 -5
- package/cjs/types/contracts/generated/UniMulticall.d.ts +55 -55
- package/cjs/types/contracts/generated/UniMulticall.js +5 -5
- package/cjs/types/contracts/generated/index.d.ts +7 -7
- package/cjs/types/contracts/generated/index.js +2 -2
- package/cjs/types/contracts/generated/types.d.ts +54 -54
- package/cjs/types/contracts/generated/types.js +2 -2
- package/cjs/types/enums.d.ts +302 -219
- package/cjs/types/enums.js +328 -245
- package/cjs/types/index.d.ts +306 -248
- package/cjs/types/index.js +2 -2
- package/esm/abis/Erc20.json +223 -223
- package/esm/abis/SubStorage.json +21 -21
- package/esm/abis/UniMulticall.json +17 -17
- package/esm/abis/index.d.ts +9 -9
- package/esm/abis/index.js +18 -18
- package/esm/abis/legacy_AaveV2Subscriptions.json +8 -8
- package/esm/abis/legacy_AuthCheck.json +8 -8
- package/esm/abis/legacy_CompoundV2Subscriptions.json +9 -9
- package/esm/abis/legacy_MakerSubscriptions.json +9 -9
- package/esm/automation/private/Automation.d.ts +12 -12
- package/esm/automation/private/Automation.js +39 -39
- package/esm/automation/private/LegacyAutomation.d.ts +25 -25
- package/esm/automation/private/LegacyAutomation.js +112 -112
- package/esm/automation/private/LegacyProtocol.d.ts +22 -22
- package/esm/automation/private/LegacyProtocol.js +38 -38
- package/esm/automation/private/LegacyProtocol.test.d.ts +1 -1
- package/esm/automation/private/LegacyProtocol.test.js +20 -20
- package/esm/automation/private/Protocol.d.ts +22 -22
- package/esm/automation/private/Protocol.js +38 -38
- package/esm/automation/private/Protocol.test.d.ts +1 -1
- package/esm/automation/private/Protocol.test.js +20 -20
- package/esm/automation/private/StrategiesAutomation.d.ts +35 -33
- package/esm/automation/private/StrategiesAutomation.js +192 -175
- package/esm/automation/private/StrategiesAutomation.test.d.ts +1 -1
- package/esm/automation/private/StrategiesAutomation.test.js +691 -666
- package/esm/automation/public/ArbitrumStrategies.d.ts +5 -5
- package/esm/automation/public/ArbitrumStrategies.js +7 -7
- package/esm/automation/public/BaseStrategies.d.ts +5 -5
- package/esm/automation/public/BaseStrategies.js +7 -7
- package/esm/automation/public/EthereumStrategies.d.ts +5 -5
- package/esm/automation/public/EthereumStrategies.js +7 -7
- package/esm/automation/public/OptimismStrategies.d.ts +5 -5
- package/esm/automation/public/OptimismStrategies.js +7 -7
- package/esm/automation/public/Strategies.test.d.ts +1 -1
- package/esm/automation/public/Strategies.test.js +56 -56
- package/esm/automation/public/legacy/LegacyAaveAutomation.d.ts +6 -6
- package/esm/automation/public/legacy/LegacyAaveAutomation.js +14 -14
- package/esm/automation/public/legacy/LegacyCompoundAutomation.d.ts +6 -6
- package/esm/automation/public/legacy/LegacyCompoundAutomation.js +14 -14
- package/esm/automation/public/legacy/LegacyMakerAutomation.d.ts +6 -6
- package/esm/automation/public/legacy/LegacyMakerAutomation.js +14 -14
- package/esm/configuration.d.ts +1 -1
- package/esm/configuration.js +7 -7
- package/esm/constants/index.d.ts +29 -28
- package/esm/constants/index.js +899 -528
- package/esm/index.d.ts +24 -23
- package/esm/index.js +23 -23
- package/esm/services/contractService.d.ts +12 -12
- package/esm/services/contractService.js +45 -45
- package/esm/services/ethereumService.d.ts +7 -7
- package/esm/services/ethereumService.js +48 -41
- package/esm/services/ethereumService.test.d.ts +1 -1
- package/esm/services/ethereumService.test.js +240 -237
- package/esm/services/strategiesService.d.ts +2 -2
- package/esm/services/strategiesService.js +1143 -831
- package/esm/services/strategiesService.test.d.ts +1 -1
- package/esm/services/strategiesService.test.js +109 -108
- package/esm/services/strategySubService.d.ts +129 -107
- package/esm/services/strategySubService.js +385 -271
- package/esm/services/strategySubService.test.d.ts +1 -1
- package/esm/services/strategySubService.test.js +1784 -908
- package/esm/services/subDataService.d.ts +527 -245
- package/esm/services/subDataService.js +1213 -630
- package/esm/services/subDataService.test.d.ts +1 -1
- package/esm/services/subDataService.test.js +2399 -1254
- package/esm/services/triggerService.d.ts +325 -226
- package/esm/services/triggerService.js +587 -404
- package/esm/services/triggerService.test.d.ts +1 -1
- package/esm/services/triggerService.test.js +1292 -901
- package/esm/services/utils.d.ts +30 -30
- package/esm/services/utils.js +139 -131
- package/esm/services/utils.test.d.ts +1 -1
- package/esm/services/utils.test.js +297 -348
- package/esm/types/contracts/generated/Erc20.d.ts +53 -53
- package/esm/types/contracts/generated/Erc20.js +4 -4
- package/esm/types/contracts/generated/Legacy_AaveV2Subscriptions.d.ts +129 -129
- package/esm/types/contracts/generated/Legacy_AaveV2Subscriptions.js +4 -4
- package/esm/types/contracts/generated/Legacy_AuthCheck.d.ts +20 -20
- package/esm/types/contracts/generated/Legacy_AuthCheck.js +4 -4
- package/esm/types/contracts/generated/Legacy_CompoundV2Subscriptions.d.ts +128 -128
- package/esm/types/contracts/generated/Legacy_CompoundV2Subscriptions.js +4 -4
- package/esm/types/contracts/generated/Legacy_MakerSubscriptions.d.ts +246 -246
- package/esm/types/contracts/generated/Legacy_MakerSubscriptions.js +4 -4
- package/esm/types/contracts/generated/SubStorage.d.ts +114 -114
- package/esm/types/contracts/generated/SubStorage.js +4 -4
- package/esm/types/contracts/generated/UniMulticall.d.ts +55 -55
- package/esm/types/contracts/generated/UniMulticall.js +4 -4
- package/esm/types/contracts/generated/index.d.ts +7 -7
- package/esm/types/contracts/generated/index.js +1 -1
- package/esm/types/contracts/generated/types.d.ts +54 -54
- package/esm/types/contracts/generated/types.js +1 -1
- package/esm/types/enums.d.ts +302 -219
- package/esm/types/enums.js +325 -242
- package/esm/types/index.d.ts +306 -248
- package/esm/types/index.js +1 -1
- package/package.json +60 -61
- package/scripts/generateContractTypes.js +39 -39
- package/src/abis/Erc20.json +222 -222
- package/src/abis/SubStorage.json +21 -21
- package/src/abis/UniMulticall.json +17 -17
- package/src/abis/index.ts +28 -28
- package/src/abis/legacy_AaveV2Subscriptions.json +7 -7
- package/src/abis/legacy_AuthCheck.json +7 -7
- package/src/abis/legacy_CompoundV2Subscriptions.json +8 -8
- package/src/abis/legacy_MakerSubscriptions.json +8 -8
- package/src/automation/private/Automation.ts +44 -44
- package/src/automation/private/LegacyAutomation.ts +135 -135
- package/src/automation/private/LegacyProtocol.test.ts +23 -23
- package/src/automation/private/LegacyProtocol.ts +51 -51
- package/src/automation/private/Protocol.test.ts +23 -23
- package/src/automation/private/Protocol.ts +51 -51
- package/src/automation/private/StrategiesAutomation.test.ts +703 -663
- package/src/automation/private/StrategiesAutomation.ts +265 -242
- package/src/automation/public/ArbitrumStrategies.ts +10 -10
- package/src/automation/public/BaseStrategies.ts +10 -10
- package/src/automation/public/EthereumStrategies.ts +10 -10
- package/src/automation/public/OptimismStrategies.ts +10 -10
- package/src/automation/public/Strategies.test.ts +49 -49
- package/src/automation/public/legacy/LegacyAaveAutomation.ts +20 -20
- package/src/automation/public/legacy/LegacyCompoundAutomation.ts +20 -20
- package/src/automation/public/legacy/LegacyMakerAutomation.ts +20 -20
- package/src/configuration.ts +8 -8
- package/src/constants/index.ts +935 -563
- package/src/index.ts +41 -39
- package/src/services/contractService.ts +77 -77
- package/src/services/ethereumService.test.ts +260 -257
- package/src/services/ethereumService.ts +76 -69
- package/src/services/strategiesService.test.ts +106 -105
- package/src/services/strategiesService.ts +1473 -1111
- package/src/services/strategySubService.test.ts +2136 -1122
- package/src/services/strategySubService.ts +987 -617
- package/src/services/subDataService.test.ts +2630 -1387
- package/src/services/subDataService.ts +1631 -870
- package/src/services/triggerService.test.ts +1434 -1004
- package/src/services/triggerService.ts +819 -553
- package/src/services/utils.test.ts +371 -430
- package/src/services/utils.ts +173 -162
- package/src/types/enums.ts +322 -239
- package/src/types/index.ts +385 -312
- package/tsconfig.esm.json +8 -8
- package/tsconfig.json +22 -22
- package/umd/index.js +0 -34103
|
@@ -1,245 +1,527 @@
|
|
|
1
|
-
import type { EthereumAddress } from '../types';
|
|
2
|
-
import type { CloseStrategyType, OrderType } from '../types/enums';
|
|
3
|
-
import { ChainId, RatioState } from '../types/enums';
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
decode(subData: string[]): {
|
|
15
|
-
targetRatio: number;
|
|
16
|
-
};
|
|
17
|
-
};
|
|
18
|
-
export declare const
|
|
19
|
-
encode(
|
|
20
|
-
decode(subData: string[]): {
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
};
|
|
35
|
-
};
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
decode(subData: string[]): {
|
|
84
|
-
targetRatio: number;
|
|
85
|
-
};
|
|
86
|
-
};
|
|
87
|
-
export declare const
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
};
|
|
104
|
-
};
|
|
105
|
-
export declare const
|
|
106
|
-
encode: (
|
|
107
|
-
decode: (subData: string[]
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
};
|
|
135
|
-
};
|
|
136
|
-
export declare const
|
|
137
|
-
encode:
|
|
138
|
-
decode
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
targetRatio: number;
|
|
191
|
-
};
|
|
192
|
-
};
|
|
193
|
-
export declare const
|
|
194
|
-
encode
|
|
195
|
-
decode
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
};
|
|
223
|
-
};
|
|
224
|
-
export declare const
|
|
225
|
-
encode(
|
|
226
|
-
decode(subData: string[]): {
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
1
|
+
import type { EthereumAddress } from '../types';
|
|
2
|
+
import type { CloseStrategyType, OrderType } from '../types/enums';
|
|
3
|
+
import { ChainId, RatioState } from '../types/enums';
|
|
4
|
+
/**
|
|
5
|
+
_______ _______ .______ .______ _______ ______ ___ .___________. _______ _______
|
|
6
|
+
| \ | ____|| _ \ | _ \ | ____| / | / \ | || ____|| \
|
|
7
|
+
| .--. || |__ | |_) | | |_) | | |__ | ,----' / ^ \ `---| |----`| |__ | .--. |
|
|
8
|
+
| | | || __| | ___/ | / | __| | | / /_\ \ | | | __| | | | |
|
|
9
|
+
| '--' || |____ | | | |\ \----.| |____ | `----./ _____ \ | | | |____ | '--' |
|
|
10
|
+
|_______/ |_______|| _| | _| `._____||_______| \______/__/ \__\ |__| |_______||_______/
|
|
11
|
+
*/
|
|
12
|
+
export declare const morphoAaveV2LeverageManagementSubData: {
|
|
13
|
+
encode(triggerRepayRatio: number, triggerBoostRatio: number, targetBoostRatio: number, targetRepayRatio: number, boostEnabled: boolean): string[];
|
|
14
|
+
decode(subData: string[]): {
|
|
15
|
+
targetRatio: number;
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
export declare const cBondsRebondSubData: {
|
|
19
|
+
encode(bondId: number | string): string[];
|
|
20
|
+
decode(subData: string[]): {
|
|
21
|
+
bondId: string;
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
export declare const liquityPaybackUsingChickenBondSubData: {
|
|
25
|
+
/**
|
|
26
|
+
* @param sourceId bondId or subId
|
|
27
|
+
* @param sourceType 0 for bond, 1 for subId
|
|
28
|
+
* @param chainId
|
|
29
|
+
*/
|
|
30
|
+
encode: (sourceId: string, sourceType: number, chainId?: ChainId) => string[];
|
|
31
|
+
decode: (subData: string[]) => {
|
|
32
|
+
sourceId: string;
|
|
33
|
+
sourceType: string;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
/**
|
|
37
|
+
.___ ___. ___ __ ___ _______ .______
|
|
38
|
+
| \/ | / \ | |/ / | ____|| _ \
|
|
39
|
+
| \ / | / ^ \ | ' / | |__ | |_) |
|
|
40
|
+
| |\/| | / /_\ \ | < | __| | /
|
|
41
|
+
| | | | / _____ \ | . \ | |____ | |\ \----.
|
|
42
|
+
|__| |__| /__/ \__\ |__|\__\ |_______|| _| `._____|
|
|
43
|
+
*/
|
|
44
|
+
export declare const makerRepayFromSavingsSubData: {
|
|
45
|
+
encode(vaultId: number, targetRatioPercentage: number, chainId: ChainId, daiAddr?: EthereumAddress, mcdCdpManagerAddr?: EthereumAddress): string[];
|
|
46
|
+
decode(subData: string[]): {
|
|
47
|
+
vaultId: number;
|
|
48
|
+
daiAddr: string;
|
|
49
|
+
mcdManagerAddr: string;
|
|
50
|
+
targetRatio: number;
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
export declare const makerCloseSubData: {
|
|
54
|
+
encode(vaultId: number, closeToAssetAddr: EthereumAddress, chainId: ChainId, daiAddr?: EthereumAddress, mcdCdpManagerAddr?: EthereumAddress): string[];
|
|
55
|
+
decode(subData: string[]): {
|
|
56
|
+
vaultId: number;
|
|
57
|
+
closeToAssetAddr: EthereumAddress;
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
export declare const makerLeverageManagementSubData: {
|
|
61
|
+
decode: (subData: string[]) => {
|
|
62
|
+
vaultId: number;
|
|
63
|
+
targetRatio: number;
|
|
64
|
+
};
|
|
65
|
+
};
|
|
66
|
+
export declare const makerLeverageManagementWithoutSubProxy: {
|
|
67
|
+
encode(vaultId: number, targetRatio: number, daiAddr?: EthereumAddress): string[];
|
|
68
|
+
decode(subData: string[]): {
|
|
69
|
+
vaultId: number;
|
|
70
|
+
targetRatio: number;
|
|
71
|
+
daiAddr: string;
|
|
72
|
+
};
|
|
73
|
+
};
|
|
74
|
+
/**
|
|
75
|
+
__ __ ______ __ __ __ .___________.____ ____ ____ ____ __
|
|
76
|
+
| | | | / __ \ | | | | | | | |\ \ / / \ \ / / /_ |
|
|
77
|
+
| | | | | | | | | | | | | | `---| |----` \ \/ / \ \/ / | |
|
|
78
|
+
| | | | | | | | | | | | | | | | \_ _/ \ / | |
|
|
79
|
+
| `----.| | | `--' '--.| `--' | | | | | | | \ / | |
|
|
80
|
+
|_______||__| \_____\_____\\______/ |__| |__| |__| \__/ |_|
|
|
81
|
+
*/
|
|
82
|
+
export declare const liquityRepayFromSavingsSubData: {
|
|
83
|
+
decode(subData: string[]): {
|
|
84
|
+
targetRatio: number;
|
|
85
|
+
};
|
|
86
|
+
};
|
|
87
|
+
export declare const liquityLeverageManagementSubData: {
|
|
88
|
+
decode: (subData: string[]) => {
|
|
89
|
+
targetRatio: number;
|
|
90
|
+
};
|
|
91
|
+
};
|
|
92
|
+
export declare const liquityCloseSubData: {
|
|
93
|
+
encode(closeToAssetAddr: EthereumAddress, chainId?: ChainId, collAddr?: EthereumAddress, debtAddr?: EthereumAddress): string[];
|
|
94
|
+
decode(subData: string[]): {
|
|
95
|
+
closeToAssetAddr: EthereumAddress;
|
|
96
|
+
debtAddr: string;
|
|
97
|
+
};
|
|
98
|
+
};
|
|
99
|
+
export declare const liquityDsrPaybackSubData: {
|
|
100
|
+
encode: (targetRatio: number) => string[];
|
|
101
|
+
decode: (subData: string[]) => {
|
|
102
|
+
targetRatio: number;
|
|
103
|
+
};
|
|
104
|
+
};
|
|
105
|
+
export declare const liquityDsrSupplySubData: {
|
|
106
|
+
encode: (targetRatio: number) => string[];
|
|
107
|
+
decode: (subData: string[]) => {
|
|
108
|
+
targetRatio: number;
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
export declare const liquityDebtInFrontRepaySubData: {
|
|
112
|
+
encode: (targetRatioIncrease: number) => string[];
|
|
113
|
+
decode: (subData: string[]) => {
|
|
114
|
+
targetRatioIncrease: number;
|
|
115
|
+
};
|
|
116
|
+
};
|
|
117
|
+
/**
|
|
118
|
+
* __ __ ______ __ __ __ .___________.____ ____ ____ ____ ___
|
|
119
|
+
| | | | / __ \ | | | | | | | |\ \ / / \ \ / / |__ \
|
|
120
|
+
| | | | | | | | | | | | | | `---| |----` \ \/ / \ \/ / ) |
|
|
121
|
+
| | | | | | | | | | | | | | | | \_ _/ \ / / /
|
|
122
|
+
| `----.| | | `--' '--.| `--' | | | | | | | \ / / /_
|
|
123
|
+
|_______||__| \_____\_____\\______/ |__| |__| |__| \__/ |____|
|
|
124
|
+
*/
|
|
125
|
+
export declare const liquityV2LeverageManagementSubData: {
|
|
126
|
+
encode: (market: EthereumAddress, troveId: string, collToken: EthereumAddress, boldToken: EthereumAddress, ratioState: RatioState, targetRatio: number) => string[];
|
|
127
|
+
decode: (subData: string[]) => {
|
|
128
|
+
market: string;
|
|
129
|
+
troveId: string;
|
|
130
|
+
collToken: string;
|
|
131
|
+
boldToken: string;
|
|
132
|
+
ratioState: RatioState;
|
|
133
|
+
targetRatio: number;
|
|
134
|
+
};
|
|
135
|
+
};
|
|
136
|
+
export declare const liquityV2CloseSubData: {
|
|
137
|
+
encode(market: EthereumAddress, troveId: string, collToken: EthereumAddress, boldToken: EthereumAddress, closeType: CloseStrategyType): string[];
|
|
138
|
+
decode(subData: string[]): {
|
|
139
|
+
market: EthereumAddress;
|
|
140
|
+
troveId: string;
|
|
141
|
+
collToken: EthereumAddress;
|
|
142
|
+
boldToken: EthereumAddress;
|
|
143
|
+
closeType: CloseStrategyType;
|
|
144
|
+
};
|
|
145
|
+
};
|
|
146
|
+
export declare const liquityV2LeverageManagementOnPriceSubData: {
|
|
147
|
+
encode(market: EthereumAddress, troveId: string, collToken: EthereumAddress, boldToken: EthereumAddress, targetRatio: number, isRepayOnPrice: boolean): string[];
|
|
148
|
+
decode(subData: string[]): {
|
|
149
|
+
market: EthereumAddress;
|
|
150
|
+
troveId: string;
|
|
151
|
+
collToken: EthereumAddress;
|
|
152
|
+
boldToken: EthereumAddress;
|
|
153
|
+
targetRatio: number;
|
|
154
|
+
};
|
|
155
|
+
};
|
|
156
|
+
export declare const liquityV2PaybackSubData: {
|
|
157
|
+
encode: (market: EthereumAddress, troveId: string, boldToken: EthereumAddress, targetRatio: number, ratioState: RatioState) => string[];
|
|
158
|
+
decode: (subData: string[]) => {
|
|
159
|
+
market: string;
|
|
160
|
+
troveId: string;
|
|
161
|
+
boldToken: string;
|
|
162
|
+
ratioState: RatioState;
|
|
163
|
+
targetRatio: number;
|
|
164
|
+
};
|
|
165
|
+
};
|
|
166
|
+
/**
|
|
167
|
+
___ ___ ____ ____ _______ ____ ____ ___
|
|
168
|
+
/ \ / \ \ \ / / | ____| \ \ / / |__ \
|
|
169
|
+
/ ^ \ / ^ \ \ \/ / | |__ \ \/ / ) |
|
|
170
|
+
/ /_\ \ / /_\ \ \ / | __| \ / / /
|
|
171
|
+
/ _____ \ / _____ \ \ / | |____ \ / / /_
|
|
172
|
+
/__/ \__\ /__/ \__\ \__/ |_______| \__/ |____|
|
|
173
|
+
*/
|
|
174
|
+
export declare const aaveV2LeverageManagementSubData: {
|
|
175
|
+
encode(triggerRepayRatio: number, triggerBoostRatio: number, targetBoostRatio: number, targetRepayRatio: number, boostEnabled: boolean): string[];
|
|
176
|
+
decode(subData: string[]): {
|
|
177
|
+
targetRatio: number;
|
|
178
|
+
};
|
|
179
|
+
};
|
|
180
|
+
/**
|
|
181
|
+
___ ___ ____ ____ _______ ____ ____ ____
|
|
182
|
+
/ \ / \ \ \ / / | ____| \ \ / / |___ \
|
|
183
|
+
/ ^ \ / ^ \ \ \/ / | |__ \ \/ / __) |
|
|
184
|
+
/ /_\ \ / /_\ \ \ / | __| \ / |__ <
|
|
185
|
+
/ _____ \ / _____ \ \ / | |____ \ / ___) |
|
|
186
|
+
/__/ \__\ /__/ \__\ \__/ |_______| \__/ |____/
|
|
187
|
+
*/
|
|
188
|
+
export declare const aaveV3LeverageManagementSubData: {
|
|
189
|
+
decode(subData: string[]): {
|
|
190
|
+
targetRatio: number;
|
|
191
|
+
};
|
|
192
|
+
};
|
|
193
|
+
export declare const aaveV3LeverageManagementSubDataWithoutSubProxy: {
|
|
194
|
+
encode(targetRatio: number, ratioState: RatioState, market: EthereumAddress, user: EthereumAddress, isGeneric: boolean): string[];
|
|
195
|
+
decode(subData: string[]): {
|
|
196
|
+
targetRatio: number;
|
|
197
|
+
ratioState: RatioState;
|
|
198
|
+
};
|
|
199
|
+
};
|
|
200
|
+
export declare const aaveV3LeverageManagementOnPriceGeneric: {
|
|
201
|
+
encode(collAsset: EthereumAddress, collAssetId: number, debtAsset: EthereumAddress, debtAssetId: number, marketAddr: EthereumAddress, targetRatio: number, user: EthereumAddress): string[];
|
|
202
|
+
decode(subData: string[]): {
|
|
203
|
+
collAsset: EthereumAddress;
|
|
204
|
+
collAssetId: number;
|
|
205
|
+
debtAsset: EthereumAddress;
|
|
206
|
+
debtAssetId: number;
|
|
207
|
+
marketAddr: EthereumAddress;
|
|
208
|
+
targetRatio: number;
|
|
209
|
+
owner: EthereumAddress;
|
|
210
|
+
};
|
|
211
|
+
};
|
|
212
|
+
export declare const aaveV3CloseGenericSubData: {
|
|
213
|
+
encode(collAsset: EthereumAddress, collAssetId: number, debtAsset: EthereumAddress, debtAssetId: number, closeType: CloseStrategyType, marketAddr: EthereumAddress, user: EthereumAddress): string[];
|
|
214
|
+
decode(subData: string[]): {
|
|
215
|
+
collAsset: EthereumAddress;
|
|
216
|
+
collAssetId: number;
|
|
217
|
+
debtAsset: EthereumAddress;
|
|
218
|
+
debtAssetId: number;
|
|
219
|
+
closeType: CloseStrategyType;
|
|
220
|
+
marketAddr: EthereumAddress;
|
|
221
|
+
owner: EthereumAddress;
|
|
222
|
+
};
|
|
223
|
+
};
|
|
224
|
+
export declare const aaveV3CollateralSwitchSubData: {
|
|
225
|
+
encode(fromAsset: EthereumAddress, fromAssetId: number, toAsset: EthereumAddress, toAssetId: number, marketAddr: EthereumAddress, amountToSwitch: string, useOnBehalf?: boolean): string[];
|
|
226
|
+
decode(subData: string[]): {
|
|
227
|
+
fromAsset: EthereumAddress;
|
|
228
|
+
fromAssetId: number;
|
|
229
|
+
toAsset: EthereumAddress;
|
|
230
|
+
toAssetId: number;
|
|
231
|
+
marketAddr: EthereumAddress;
|
|
232
|
+
amountToSwitch: string;
|
|
233
|
+
};
|
|
234
|
+
};
|
|
235
|
+
export declare const aaveV3QuotePriceSubData: {
|
|
236
|
+
encode(collAsset: EthereumAddress, collAssetId: number, debtAsset: EthereumAddress, debtAssetId: number, nullAddress?: EthereumAddress): string[];
|
|
237
|
+
decode(subData: string[]): {
|
|
238
|
+
collAsset: EthereumAddress;
|
|
239
|
+
collAssetId: number;
|
|
240
|
+
debtAsset: EthereumAddress;
|
|
241
|
+
debtAssetId: number;
|
|
242
|
+
};
|
|
243
|
+
};
|
|
244
|
+
export declare const aaveV3LeverageManagementOnPriceSubData: {
|
|
245
|
+
encode(collAsset: EthereumAddress, collAssetId: number, debtAsset: EthereumAddress, debtAssetId: number, marketAddr: EthereumAddress, targetRatio: number): string[];
|
|
246
|
+
decode(subData: string[]): {
|
|
247
|
+
collAsset: EthereumAddress;
|
|
248
|
+
collAssetId: number;
|
|
249
|
+
debtAsset: EthereumAddress;
|
|
250
|
+
debtAssetId: number;
|
|
251
|
+
marketAddr: EthereumAddress;
|
|
252
|
+
targetRatio: number;
|
|
253
|
+
};
|
|
254
|
+
};
|
|
255
|
+
/**
|
|
256
|
+
* ___ ___ ____ ____ _______ ____ ____ _ _
|
|
257
|
+
/ \ / \ \ \ / / | ____| \ \ / / | || |
|
|
258
|
+
/ ^ \ / ^ \ \ \/ / | |__ \ \/ / | || |_
|
|
259
|
+
/ /_\ \ / /_\ \ \ / | __| \ / |__ _|
|
|
260
|
+
/ _____ \ / _____ \ \ / | |____ \ / | |
|
|
261
|
+
/__/ \__\ /__/ \__\ \__/ |_______| \__/ |_|
|
|
262
|
+
*/
|
|
263
|
+
export declare const aaveV4LeverageManagementSubData: {
|
|
264
|
+
encode: (spoke: EthereumAddress, owner: EthereumAddress, ratioState: RatioState, targetRatio: number) => string[];
|
|
265
|
+
decode: (subData: string[]) => {
|
|
266
|
+
spoke: string;
|
|
267
|
+
owner: string;
|
|
268
|
+
ratioState: RatioState;
|
|
269
|
+
targetRatio: number;
|
|
270
|
+
};
|
|
271
|
+
};
|
|
272
|
+
export declare const aaveV4LeverageManagementOnPriceSubData: {
|
|
273
|
+
encode: (spoke: EthereumAddress, owner: EthereumAddress, collAsset: EthereumAddress, collAssetId: number, debtAsset: EthereumAddress, debtAssetId: number, ratioState: RatioState, targetRatio: number) => string[];
|
|
274
|
+
decode: (subData: string[]) => {
|
|
275
|
+
spoke: string;
|
|
276
|
+
owner: string;
|
|
277
|
+
collAsset: string;
|
|
278
|
+
collAssetId: number;
|
|
279
|
+
debtAsset: string;
|
|
280
|
+
debtAssetId: number;
|
|
281
|
+
ratioState: RatioState;
|
|
282
|
+
targetRatio: number;
|
|
283
|
+
};
|
|
284
|
+
};
|
|
285
|
+
export declare const aaveV4CloseSubData: {
|
|
286
|
+
encode: (spoke: EthereumAddress, owner: EthereumAddress, collAsset: EthereumAddress, collAssetId: number, debtAsset: EthereumAddress, debtAssetId: number, closeType: CloseStrategyType) => string[];
|
|
287
|
+
decode: (subData: string[]) => {
|
|
288
|
+
spoke: string;
|
|
289
|
+
owner: string;
|
|
290
|
+
collAsset: string;
|
|
291
|
+
collAssetId: number;
|
|
292
|
+
debtAsset: string;
|
|
293
|
+
debtAssetId: number;
|
|
294
|
+
closeType: CloseStrategyType;
|
|
295
|
+
};
|
|
296
|
+
};
|
|
297
|
+
export declare const aaveV4CollateralSwitchSubData: {
|
|
298
|
+
encode: (spoke: EthereumAddress, owner: EthereumAddress, fromAsset: EthereumAddress, fromAssetId: number, toAsset: EthereumAddress, toAssetId: number, amountToSwitch: string) => string[];
|
|
299
|
+
decode: (subData: string[]) => {
|
|
300
|
+
spoke: string;
|
|
301
|
+
owner: string;
|
|
302
|
+
fromAsset: string;
|
|
303
|
+
fromAssetId: number;
|
|
304
|
+
toAsset: string;
|
|
305
|
+
toAssetId: number;
|
|
306
|
+
amountToSwitch: string;
|
|
307
|
+
};
|
|
308
|
+
};
|
|
309
|
+
/**
|
|
310
|
+
______ ______ .___ ___. .______ ____ ____ ___
|
|
311
|
+
/ | / __ \ | \/ | | _ \ \ \ / / |__ \
|
|
312
|
+
| ,----'| | | | | \ / | | |_) | \ \/ / ) |
|
|
313
|
+
| | | | | | | |\/| | | ___/ \ / / /
|
|
314
|
+
| `----.| `--' | | | | | | | \ / / /_
|
|
315
|
+
\______| \______/ |__| |__| | _| \__/ |____|
|
|
316
|
+
*/
|
|
317
|
+
export declare const compoundV2LeverageManagementSubData: {
|
|
318
|
+
encode(triggerRepayRatio: number, triggerBoostRatio: number, targetBoostRatio: number, targetRepayRatio: number, boostEnabled: boolean): string[];
|
|
319
|
+
decode(subData: string[]): {
|
|
320
|
+
targetRatio: number;
|
|
321
|
+
};
|
|
322
|
+
};
|
|
323
|
+
/**
|
|
324
|
+
______ ______ .___ ___. .______ ____ ____ ____
|
|
325
|
+
/ | / __ \ | \/ | | _ \ \ \ / / |___ \
|
|
326
|
+
| ,----'| | | | | \ / | | |_) | \ \/ / __) |
|
|
327
|
+
| | | | | | | |\/| | | ___/ \ / |__ <
|
|
328
|
+
| `----.| `--' | | | | | | | \ / ___) |
|
|
329
|
+
\______| \______/ |__| |__| | _| \__/ |____/
|
|
330
|
+
*/
|
|
331
|
+
export declare const compoundV3LeverageManagementSubData: {
|
|
332
|
+
encode(market: EthereumAddress, baseToken: EthereumAddress, triggerRepayRatio: number, triggerBoostRatio: number, targetBoostRatio: number, targetRepayRatio: number, boostEnabled: boolean, isEOA: boolean): string[];
|
|
333
|
+
decode(subData: string[]): {
|
|
334
|
+
targetRatio: number;
|
|
335
|
+
};
|
|
336
|
+
};
|
|
337
|
+
export declare const compoundV3L2LeverageManagementSubData: {
|
|
338
|
+
encode(market: EthereumAddress, baseToken: EthereumAddress, triggerRepayRatio: number, triggerBoostRatio: number, targetBoostRatio: number, targetRepayRatio: number, boostEnabled: boolean, isEOA: boolean): string;
|
|
339
|
+
decode(subData: string[]): {
|
|
340
|
+
targetRatio: number;
|
|
341
|
+
};
|
|
342
|
+
};
|
|
343
|
+
export declare const compoundV3LeverageManagementOnPriceSubData: {
|
|
344
|
+
encode(market: EthereumAddress, collToken: EthereumAddress, baseToken: EthereumAddress, targetRatio: number, ratioState: RatioState, user: EthereumAddress): string[];
|
|
345
|
+
decode(subData: string[]): {
|
|
346
|
+
market: EthereumAddress;
|
|
347
|
+
collToken: EthereumAddress;
|
|
348
|
+
baseToken: EthereumAddress;
|
|
349
|
+
targetRatio: number;
|
|
350
|
+
ratioState: RatioState;
|
|
351
|
+
owner: EthereumAddress;
|
|
352
|
+
};
|
|
353
|
+
};
|
|
354
|
+
export declare const compoundV3CloseSubData: {
|
|
355
|
+
encode(market: EthereumAddress, collToken: EthereumAddress, baseToken: EthereumAddress, closeType: CloseStrategyType, user: EthereumAddress): string[];
|
|
356
|
+
decode(subData: string[]): {
|
|
357
|
+
market: EthereumAddress;
|
|
358
|
+
collToken: EthereumAddress;
|
|
359
|
+
baseToken: EthereumAddress;
|
|
360
|
+
closeType: CloseStrategyType;
|
|
361
|
+
owner: EthereumAddress;
|
|
362
|
+
};
|
|
363
|
+
};
|
|
364
|
+
/**
|
|
365
|
+
__________ ___ ______ __ __ ___ .__ __. _______ _______
|
|
366
|
+
| ____\ \ / / / || | | | / \ | \ | | / _____|| ____|
|
|
367
|
+
| |__ \ V / | ,----'| |__| | / ^ \ | \| | | | __ | |__
|
|
368
|
+
| __| > < | | | __ | / /_\ \ | . ` | | | |_ | | __|
|
|
369
|
+
| |____ / . \ | `----.| | | | / _____ \ | |\ | | |__| | | |____
|
|
370
|
+
|_______/__/ \__\ \______||__| |__| /__/ \__\ |__| \__| \______| |_______|
|
|
371
|
+
*/
|
|
372
|
+
export declare const exchangeDcaSubData: {
|
|
373
|
+
encode: (fromToken: EthereumAddress, toToken: EthereumAddress, amount: string, interval: number) => string[];
|
|
374
|
+
decode: (subData: string[], chainId: ChainId) => {
|
|
375
|
+
fromToken: string;
|
|
376
|
+
toToken: string;
|
|
377
|
+
amount: string;
|
|
378
|
+
interval: string;
|
|
379
|
+
};
|
|
380
|
+
};
|
|
381
|
+
export declare const exchangeLimitOrderSubData: {
|
|
382
|
+
encode(fromToken: EthereumAddress, toToken: EthereumAddress, amount: string, targetPrice: string, goodUntil: string | number, orderType: OrderType): string[];
|
|
383
|
+
decode: (subData: string[], chainId: ChainId) => {
|
|
384
|
+
fromToken: string;
|
|
385
|
+
toToken: string;
|
|
386
|
+
amount: string;
|
|
387
|
+
};
|
|
388
|
+
};
|
|
389
|
+
/**
|
|
390
|
+
_______..______ ___ .______ __ ___
|
|
391
|
+
/ || _ \ / \ | _ \ | |/ /
|
|
392
|
+
| (----`| |_) | / ^ \ | |_) | | ' /
|
|
393
|
+
\ \ | ___/ / /_\ \ | / | <
|
|
394
|
+
.----) | | | / _____ \ | |\ \----.| . \
|
|
395
|
+
|_______/ | _| /__/ \__\ | _| `._____||__|\__\
|
|
396
|
+
*/
|
|
397
|
+
export declare const sparkLeverageManagementSubData: {
|
|
398
|
+
decode(subData: string[]): {
|
|
399
|
+
targetRatio: number;
|
|
400
|
+
};
|
|
401
|
+
};
|
|
402
|
+
export declare const sparkLeverageManagementSubDataWithoutSubProxy: {
|
|
403
|
+
encode(targetRatio: number, ratioState: RatioState): string[];
|
|
404
|
+
decode(subData: string[]): {
|
|
405
|
+
targetRatio: number;
|
|
406
|
+
ratioState: RatioState;
|
|
407
|
+
};
|
|
408
|
+
};
|
|
409
|
+
export declare const sparkCloseGenericSubData: {
|
|
410
|
+
encode(collAsset: EthereumAddress, collAssetId: number, debtAsset: EthereumAddress, debtAssetId: number, closeType: CloseStrategyType, marketAddr: EthereumAddress, user: EthereumAddress): string[];
|
|
411
|
+
decode(subData: string[]): {
|
|
412
|
+
collAsset: EthereumAddress;
|
|
413
|
+
collAssetId: number;
|
|
414
|
+
debtAsset: EthereumAddress;
|
|
415
|
+
debtAssetId: number;
|
|
416
|
+
closeType: CloseStrategyType;
|
|
417
|
+
marketAddr: EthereumAddress;
|
|
418
|
+
owner: EthereumAddress;
|
|
419
|
+
};
|
|
420
|
+
};
|
|
421
|
+
export declare const sparkLeverageManagementOnPriceSubData: {
|
|
422
|
+
encode(collAsset: EthereumAddress, collAssetId: number, debtAsset: EthereumAddress, debtAssetId: number, marketAddr: EthereumAddress, targetRatio: number): string[];
|
|
423
|
+
decode(subData: string[]): {
|
|
424
|
+
collAsset: EthereumAddress;
|
|
425
|
+
collAssetId: number;
|
|
426
|
+
debtAsset: EthereumAddress;
|
|
427
|
+
debtAssetId: number;
|
|
428
|
+
marketAddr: EthereumAddress;
|
|
429
|
+
targetRatio: number;
|
|
430
|
+
};
|
|
431
|
+
};
|
|
432
|
+
export declare const sparkCollateralSwitchSubData: {
|
|
433
|
+
encode(fromAsset: EthereumAddress, fromAssetId: number, toAsset: EthereumAddress, toAssetId: number, marketAddr: EthereumAddress, amountToSwitch: string, useOnBehalf?: boolean): string[];
|
|
434
|
+
decode(subData: string[]): {
|
|
435
|
+
fromAsset: EthereumAddress;
|
|
436
|
+
fromAssetId: number;
|
|
437
|
+
toAsset: EthereumAddress;
|
|
438
|
+
toAssetId: number;
|
|
439
|
+
marketAddr: EthereumAddress;
|
|
440
|
+
amountToSwitch: string;
|
|
441
|
+
};
|
|
442
|
+
};
|
|
443
|
+
/**
|
|
444
|
+
______ .______ ____ ____ __ __ _______. _______
|
|
445
|
+
/ || _ \ \ \ / / | | | | / || \
|
|
446
|
+
| ,----'| |_) | \ \/ / | | | | | (----`| .--. |
|
|
447
|
+
| | | / \ / | | | | \ \ | | | |
|
|
448
|
+
| `----.| |\ \----. \ / | `--' | .----) | | '--' |
|
|
449
|
+
\______|| _| `._____| \__/ \______/ |_______/ |_______/
|
|
450
|
+
*/
|
|
451
|
+
export declare const crvUSDLeverageManagementSubData: {
|
|
452
|
+
encode: (controllerAddr: EthereumAddress, ratioState: RatioState, targetRatio: number, collTokenAddr: EthereumAddress, crvUSDAddr: EthereumAddress) => string[];
|
|
453
|
+
decode: (subData: string[]) => {
|
|
454
|
+
controller: string;
|
|
455
|
+
targetRatio: number;
|
|
456
|
+
};
|
|
457
|
+
};
|
|
458
|
+
export declare const crvUSDPaybackSubData: {
|
|
459
|
+
encode: (controllerAddr: EthereumAddress, addressToPullTokensFrom: EthereumAddress, positionOwner: EthereumAddress, paybackAmount: string, crvUSDAddr: EthereumAddress) => string[];
|
|
460
|
+
decode: (subData: string[]) => {
|
|
461
|
+
controller: string;
|
|
462
|
+
addressToPullTokensFrom: string;
|
|
463
|
+
positionOwner: string;
|
|
464
|
+
paybackAmount: string;
|
|
465
|
+
};
|
|
466
|
+
};
|
|
467
|
+
/**
|
|
468
|
+
.___ ___. ______ .______ .______ __ __ ______
|
|
469
|
+
| \/ | / __ \ | _ \ | _ \ | | | | / __ \
|
|
470
|
+
| \ / | | | | | | |_) | | |_) | | |__| | | | | |
|
|
471
|
+
| |\/| | | | | | | / | ___/ | __ | | | | |
|
|
472
|
+
| | | | | `--' | | |\ \----.| | | | | | | `--' |
|
|
473
|
+
|__| |__| \______/ | _| `._____|| _| |__| |__| \______/
|
|
474
|
+
*/
|
|
475
|
+
export declare const morphoBlueLeverageManagementSubData: {
|
|
476
|
+
encode: (loanToken: EthereumAddress, collToken: EthereumAddress, oracle: EthereumAddress, irm: EthereumAddress, lltv: string, ratioState: RatioState, targetRatio: number, user: EthereumAddress, isEOA: boolean) => string[];
|
|
477
|
+
decode: (subData: string[]) => {
|
|
478
|
+
loanToken: string;
|
|
479
|
+
collToken: string;
|
|
480
|
+
oracle: string;
|
|
481
|
+
irm: string;
|
|
482
|
+
lltv: string;
|
|
483
|
+
user: string;
|
|
484
|
+
targetRatio: number;
|
|
485
|
+
};
|
|
486
|
+
};
|
|
487
|
+
export declare const morphoBlueLeverageManagementOnPriceSubData: {
|
|
488
|
+
encode(loanToken: EthereumAddress, collToken: EthereumAddress, oracle: EthereumAddress, irm: EthereumAddress, lltv: string, targetRatio: number, user: EthereumAddress): string[];
|
|
489
|
+
decode(subData: string[]): {
|
|
490
|
+
loanToken: string;
|
|
491
|
+
collToken: string;
|
|
492
|
+
oracle: string;
|
|
493
|
+
irm: string;
|
|
494
|
+
lltv: string;
|
|
495
|
+
targetRatio: number;
|
|
496
|
+
user: string;
|
|
497
|
+
};
|
|
498
|
+
};
|
|
499
|
+
export declare const morphoBlueCloseOnPriceSubData: {
|
|
500
|
+
encode(loanToken: EthereumAddress, collToken: EthereumAddress, oracle: EthereumAddress, irm: EthereumAddress, lltv: string, user: EthereumAddress, closeType: CloseStrategyType): string[];
|
|
501
|
+
decode(subData: string[]): {
|
|
502
|
+
loanToken: string;
|
|
503
|
+
collToken: string;
|
|
504
|
+
oracle: string;
|
|
505
|
+
irm: string;
|
|
506
|
+
lltv: string;
|
|
507
|
+
user: string;
|
|
508
|
+
closeType: CloseStrategyType;
|
|
509
|
+
};
|
|
510
|
+
};
|
|
511
|
+
/**
|
|
512
|
+
_______ __ __ __ __ _______
|
|
513
|
+
| ____|| | | | | | | | | \
|
|
514
|
+
| |__ | | | | | | | | | .--. |
|
|
515
|
+
| __| | | | | | | | | | | | |
|
|
516
|
+
| | | `----.| `--' | | | | '--' |
|
|
517
|
+
|__| |_______| \______/ |__| |_______/
|
|
518
|
+
*/
|
|
519
|
+
export declare const fluidLeverageManagementSubData: {
|
|
520
|
+
encode: (nftId: string, vault: EthereumAddress, ratioState: RatioState, targetRatio: number) => string[];
|
|
521
|
+
decode: (subData: string[]) => {
|
|
522
|
+
nftId: string;
|
|
523
|
+
vault: string;
|
|
524
|
+
ratioState: RatioState;
|
|
525
|
+
targetRatio: number;
|
|
526
|
+
};
|
|
527
|
+
};
|