@defisaver/positions-sdk 0.0.201-fluid-dev-10 → 0.0.201-fluid-dev-11
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/.mocharc.json +4 -4
- package/.nvmrc +1 -1
- package/README.md +69 -69
- package/cjs/aaveV2/index.js +1 -1
- package/cjs/config/contracts.d.ts +87 -6
- package/cjs/config/contracts.js +15 -2
- package/cjs/helpers/liquityV2Helpers/index.js +2 -2
- package/cjs/helpers/morphoBlueHelpers/index.js +66 -66
- package/cjs/liquityV2/index.d.ts +9 -4
- package/cjs/liquityV2/index.js +69 -10
- package/cjs/markets/index.d.ts +1 -1
- package/cjs/markets/index.js +2 -1
- package/cjs/markets/liquityV2/index.d.ts +2 -1
- package/cjs/markets/liquityV2/index.js +12 -1
- package/cjs/markets/spark/marketAssets.js +1 -1
- package/cjs/morphoAaveV2/index.js +1 -1
- package/cjs/morphoAaveV3/index.js +1 -2
- package/cjs/spark/index.js +1 -2
- package/cjs/staking/staking.d.ts +1 -6
- package/cjs/staking/staking.js +20 -23
- package/cjs/types/contracts/generated/LiquityV2StabilityPool.d.ts +223 -0
- package/cjs/types/contracts/generated/LiquityV2StabilityPool.js +5 -0
- package/cjs/types/contracts/generated/LiquityV2View.d.ts +144 -2
- package/cjs/types/contracts/generated/index.d.ts +1 -0
- package/cjs/types/liquityV2.d.ts +1 -0
- package/esm/aaveV2/index.js +2 -2
- package/esm/config/contracts.d.ts +87 -6
- package/esm/config/contracts.js +15 -2
- package/esm/helpers/liquityV2Helpers/index.js +2 -2
- package/esm/helpers/morphoBlueHelpers/index.js +66 -66
- package/esm/liquityV2/index.d.ts +9 -4
- package/esm/liquityV2/index.js +64 -10
- package/esm/markets/index.d.ts +1 -1
- package/esm/markets/index.js +1 -1
- package/esm/markets/liquityV2/index.d.ts +2 -1
- package/esm/markets/liquityV2/index.js +10 -0
- package/esm/markets/spark/marketAssets.js +1 -1
- package/esm/morphoAaveV2/index.js +2 -2
- package/esm/morphoAaveV3/index.js +1 -2
- package/esm/spark/index.js +1 -2
- package/esm/staking/staking.d.ts +1 -6
- package/esm/staking/staking.js +24 -22
- package/esm/types/contracts/generated/LiquityV2StabilityPool.d.ts +223 -0
- package/esm/types/contracts/generated/LiquityV2StabilityPool.js +4 -0
- package/esm/types/contracts/generated/LiquityV2View.d.ts +144 -2
- package/esm/types/contracts/generated/index.d.ts +1 -0
- package/esm/types/liquityV2.d.ts +1 -0
- package/package.json +52 -51
- package/src/aaveV2/index.ts +227 -227
- package/src/aaveV3/index.ts +625 -625
- package/src/assets/index.ts +60 -60
- package/src/chickenBonds/index.ts +123 -123
- package/src/compoundV2/index.ts +220 -220
- package/src/compoundV3/index.ts +291 -291
- package/src/config/contracts.js +1135 -1122
- package/src/constants/index.ts +6 -6
- package/src/contracts.ts +134 -134
- package/src/curveUsd/index.ts +229 -229
- package/src/eulerV2/index.ts +303 -303
- package/src/exchange/index.ts +17 -17
- package/src/fluid/index.ts +343 -343
- package/src/helpers/aaveHelpers/index.ts +198 -198
- package/src/helpers/chickenBondsHelpers/index.ts +23 -23
- package/src/helpers/compoundHelpers/index.ts +246 -246
- package/src/helpers/curveUsdHelpers/index.ts +40 -40
- package/src/helpers/eulerHelpers/index.ts +232 -232
- package/src/helpers/fluidHelpers/index.ts +53 -53
- package/src/helpers/index.ts +11 -11
- package/src/helpers/liquityV2Helpers/index.ts +80 -80
- package/src/helpers/llamaLendHelpers/index.ts +53 -53
- package/src/helpers/makerHelpers/index.ts +94 -94
- package/src/helpers/morphoBlueHelpers/index.ts +365 -365
- package/src/helpers/sparkHelpers/index.ts +150 -150
- package/src/index.ts +52 -52
- package/src/liquity/index.ts +116 -116
- package/src/liquityV2/index.ts +295 -228
- package/src/llamaLend/index.ts +275 -275
- package/src/maker/index.ts +117 -117
- package/src/markets/aave/index.ts +152 -152
- package/src/markets/aave/marketAssets.ts +44 -44
- package/src/markets/compound/index.ts +213 -213
- package/src/markets/compound/marketsAssets.ts +82 -82
- package/src/markets/curveUsd/index.ts +69 -69
- package/src/markets/euler/index.ts +26 -26
- package/src/markets/fluid/index.ts +2010 -2010
- package/src/markets/index.ts +27 -27
- package/src/markets/liquityV2/index.ts +55 -44
- package/src/markets/llamaLend/contractAddresses.ts +141 -141
- package/src/markets/llamaLend/index.ts +235 -235
- package/src/markets/morphoBlue/index.ts +895 -895
- package/src/markets/spark/index.ts +29 -29
- package/src/markets/spark/marketAssets.ts +10 -10
- package/src/moneymarket/moneymarketCommonService.ts +80 -80
- package/src/morphoAaveV2/index.ts +256 -256
- package/src/morphoAaveV3/index.ts +630 -631
- package/src/morphoBlue/index.ts +202 -202
- package/src/multicall/index.ts +33 -33
- package/src/services/priceService.ts +91 -91
- package/src/services/utils.ts +59 -59
- package/src/setup.ts +8 -8
- package/src/spark/index.ts +460 -461
- package/src/staking/staking.ts +220 -220
- package/src/types/aave.ts +271 -271
- package/src/types/chickenBonds.ts +45 -45
- package/src/types/common.ts +84 -84
- package/src/types/compound.ts +131 -131
- package/src/types/contracts/generated/LiquityV2StabilityPool.ts +453 -0
- package/src/types/contracts/generated/LiquityV2View.ts +173 -2
- package/src/types/contracts/generated/index.ts +1 -0
- package/src/types/curveUsd.ts +118 -118
- package/src/types/euler.ts +171 -171
- package/src/types/fluid.ts +264 -264
- package/src/types/index.ts +11 -11
- package/src/types/liquity.ts +30 -30
- package/src/types/liquityV2.ts +119 -118
- package/src/types/llamaLend.ts +155 -155
- package/src/types/maker.ts +50 -50
- package/src/types/morphoBlue.ts +192 -192
- package/src/types/spark.ts +131 -131
- package/cjs/services/dsrService.d.ts +0 -3
- package/cjs/services/dsrService.js +0 -28
- package/esm/services/dsrService.d.ts +0 -3
- package/esm/services/dsrService.js +0 -21
- package/src/services/dsrService.ts +0 -16
|
@@ -0,0 +1,453 @@
|
|
|
1
|
+
/* Autogenerated file. Do not edit manually. */
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
|
|
5
|
+
import type BN from "bn.js";
|
|
6
|
+
import type { ContractOptions } from "web3-eth-contract";
|
|
7
|
+
import type { EventLog } from "web3-core";
|
|
8
|
+
import type { EventEmitter } from "events";
|
|
9
|
+
import type {
|
|
10
|
+
Callback,
|
|
11
|
+
PayableTransactionObject,
|
|
12
|
+
NonPayableTransactionObject,
|
|
13
|
+
BlockType,
|
|
14
|
+
ContractEventLog,
|
|
15
|
+
BaseContract,
|
|
16
|
+
} from "./types";
|
|
17
|
+
|
|
18
|
+
export interface EventOptions {
|
|
19
|
+
filter?: object;
|
|
20
|
+
fromBlock?: BlockType;
|
|
21
|
+
topics?: string[];
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export type ActivePoolAddressChanged = ContractEventLog<{
|
|
25
|
+
_newActivePoolAddress: string;
|
|
26
|
+
0: string;
|
|
27
|
+
}>;
|
|
28
|
+
export type B_Updated = ContractEventLog<{
|
|
29
|
+
_B: string;
|
|
30
|
+
_epoch: string;
|
|
31
|
+
_scale: string;
|
|
32
|
+
0: string;
|
|
33
|
+
1: string;
|
|
34
|
+
2: string;
|
|
35
|
+
}>;
|
|
36
|
+
export type BoldTokenAddressChanged = ContractEventLog<{
|
|
37
|
+
_newBoldTokenAddress: string;
|
|
38
|
+
0: string;
|
|
39
|
+
}>;
|
|
40
|
+
export type DefaultPoolAddressChanged = ContractEventLog<{
|
|
41
|
+
_newDefaultPoolAddress: string;
|
|
42
|
+
0: string;
|
|
43
|
+
}>;
|
|
44
|
+
export type DepositOperation = ContractEventLog<{
|
|
45
|
+
_depositor: string;
|
|
46
|
+
_operation: string;
|
|
47
|
+
_depositLossSinceLastOperation: string;
|
|
48
|
+
_depositChange: string;
|
|
49
|
+
_yieldGainSinceLastOperation: string;
|
|
50
|
+
_yieldGainClaimed: string;
|
|
51
|
+
_ethGainSinceLastOperation: string;
|
|
52
|
+
_ethGainClaimed: string;
|
|
53
|
+
0: string;
|
|
54
|
+
1: string;
|
|
55
|
+
2: string;
|
|
56
|
+
3: string;
|
|
57
|
+
4: string;
|
|
58
|
+
5: string;
|
|
59
|
+
6: string;
|
|
60
|
+
7: string;
|
|
61
|
+
}>;
|
|
62
|
+
export type DepositUpdated = ContractEventLog<{
|
|
63
|
+
_depositor: string;
|
|
64
|
+
_newDeposit: string;
|
|
65
|
+
_stashedColl: string;
|
|
66
|
+
_snapshotP: string;
|
|
67
|
+
_snapshotS: string;
|
|
68
|
+
_snapshotB: string;
|
|
69
|
+
_snapshotScale: string;
|
|
70
|
+
_snapshotEpoch: string;
|
|
71
|
+
0: string;
|
|
72
|
+
1: string;
|
|
73
|
+
2: string;
|
|
74
|
+
3: string;
|
|
75
|
+
4: string;
|
|
76
|
+
5: string;
|
|
77
|
+
6: string;
|
|
78
|
+
7: string;
|
|
79
|
+
}>;
|
|
80
|
+
export type EpochUpdated = ContractEventLog<{
|
|
81
|
+
_currentEpoch: string;
|
|
82
|
+
0: string;
|
|
83
|
+
}>;
|
|
84
|
+
export type EtherSent = ContractEventLog<{
|
|
85
|
+
_to: string;
|
|
86
|
+
_amount: string;
|
|
87
|
+
0: string;
|
|
88
|
+
1: string;
|
|
89
|
+
}>;
|
|
90
|
+
export type P_Updated = ContractEventLog<{
|
|
91
|
+
_P: string;
|
|
92
|
+
0: string;
|
|
93
|
+
}>;
|
|
94
|
+
export type PriceFeedAddressChanged = ContractEventLog<{
|
|
95
|
+
_newPriceFeedAddress: string;
|
|
96
|
+
0: string;
|
|
97
|
+
}>;
|
|
98
|
+
export type S_Updated = ContractEventLog<{
|
|
99
|
+
_S: string;
|
|
100
|
+
_epoch: string;
|
|
101
|
+
_scale: string;
|
|
102
|
+
0: string;
|
|
103
|
+
1: string;
|
|
104
|
+
2: string;
|
|
105
|
+
}>;
|
|
106
|
+
export type ScaleUpdated = ContractEventLog<{
|
|
107
|
+
_currentScale: string;
|
|
108
|
+
0: string;
|
|
109
|
+
}>;
|
|
110
|
+
export type StabilityPoolBoldBalanceUpdated = ContractEventLog<{
|
|
111
|
+
_newBalance: string;
|
|
112
|
+
0: string;
|
|
113
|
+
}>;
|
|
114
|
+
export type StabilityPoolCollBalanceUpdated = ContractEventLog<{
|
|
115
|
+
_newBalance: string;
|
|
116
|
+
0: string;
|
|
117
|
+
}>;
|
|
118
|
+
export type TroveManagerAddressChanged = ContractEventLog<{
|
|
119
|
+
_newTroveManagerAddress: string;
|
|
120
|
+
0: string;
|
|
121
|
+
}>;
|
|
122
|
+
|
|
123
|
+
export interface LiquityV2StabilityPool extends BaseContract {
|
|
124
|
+
constructor(
|
|
125
|
+
jsonInterface: any[],
|
|
126
|
+
address?: string,
|
|
127
|
+
options?: ContractOptions
|
|
128
|
+
): LiquityV2StabilityPool;
|
|
129
|
+
clone(): LiquityV2StabilityPool;
|
|
130
|
+
methods: {
|
|
131
|
+
NAME(): NonPayableTransactionObject<string>;
|
|
132
|
+
|
|
133
|
+
P(): NonPayableTransactionObject<string>;
|
|
134
|
+
|
|
135
|
+
SCALE_FACTOR(): NonPayableTransactionObject<string>;
|
|
136
|
+
|
|
137
|
+
activePool(): NonPayableTransactionObject<string>;
|
|
138
|
+
|
|
139
|
+
boldToken(): NonPayableTransactionObject<string>;
|
|
140
|
+
|
|
141
|
+
claimAllCollGains(): NonPayableTransactionObject<void>;
|
|
142
|
+
|
|
143
|
+
collToken(): NonPayableTransactionObject<string>;
|
|
144
|
+
|
|
145
|
+
currentEpoch(): NonPayableTransactionObject<string>;
|
|
146
|
+
|
|
147
|
+
currentScale(): NonPayableTransactionObject<string>;
|
|
148
|
+
|
|
149
|
+
depositSnapshots(
|
|
150
|
+
arg0: string
|
|
151
|
+
): NonPayableTransactionObject<
|
|
152
|
+
[string, string, string, string, string] & {
|
|
153
|
+
S: string;
|
|
154
|
+
P: string;
|
|
155
|
+
B: string;
|
|
156
|
+
scale: string;
|
|
157
|
+
epoch: string;
|
|
158
|
+
}
|
|
159
|
+
>;
|
|
160
|
+
|
|
161
|
+
deposits(arg0: string): NonPayableTransactionObject<string>;
|
|
162
|
+
|
|
163
|
+
epochToScaleToB(
|
|
164
|
+
arg0: number | string | BN,
|
|
165
|
+
arg1: number | string | BN
|
|
166
|
+
): NonPayableTransactionObject<string>;
|
|
167
|
+
|
|
168
|
+
epochToScaleToS(
|
|
169
|
+
arg0: number | string | BN,
|
|
170
|
+
arg1: number | string | BN
|
|
171
|
+
): NonPayableTransactionObject<string>;
|
|
172
|
+
|
|
173
|
+
getCollBalance(): NonPayableTransactionObject<string>;
|
|
174
|
+
|
|
175
|
+
getCompoundedBoldDeposit(
|
|
176
|
+
_depositor: string
|
|
177
|
+
): NonPayableTransactionObject<string>;
|
|
178
|
+
|
|
179
|
+
getDepositorCollGain(
|
|
180
|
+
_depositor: string
|
|
181
|
+
): NonPayableTransactionObject<string>;
|
|
182
|
+
|
|
183
|
+
getDepositorYieldGain(
|
|
184
|
+
_depositor: string
|
|
185
|
+
): NonPayableTransactionObject<string>;
|
|
186
|
+
|
|
187
|
+
getDepositorYieldGainWithPending(
|
|
188
|
+
_depositor: string
|
|
189
|
+
): NonPayableTransactionObject<string>;
|
|
190
|
+
|
|
191
|
+
getEntireSystemColl(): NonPayableTransactionObject<string>;
|
|
192
|
+
|
|
193
|
+
getEntireSystemDebt(): NonPayableTransactionObject<string>;
|
|
194
|
+
|
|
195
|
+
getTotalBoldDeposits(): NonPayableTransactionObject<string>;
|
|
196
|
+
|
|
197
|
+
getYieldGainsOwed(): NonPayableTransactionObject<string>;
|
|
198
|
+
|
|
199
|
+
getYieldGainsPending(): NonPayableTransactionObject<string>;
|
|
200
|
+
|
|
201
|
+
lastBoldLossError_Offset(): NonPayableTransactionObject<string>;
|
|
202
|
+
|
|
203
|
+
lastBoldLossError_TotalDeposits(): NonPayableTransactionObject<string>;
|
|
204
|
+
|
|
205
|
+
lastCollError_Offset(): NonPayableTransactionObject<string>;
|
|
206
|
+
|
|
207
|
+
lastYieldError(): NonPayableTransactionObject<string>;
|
|
208
|
+
|
|
209
|
+
offset(
|
|
210
|
+
_debtToOffset: number | string | BN,
|
|
211
|
+
_collToAdd: number | string | BN
|
|
212
|
+
): NonPayableTransactionObject<void>;
|
|
213
|
+
|
|
214
|
+
provideToSP(
|
|
215
|
+
_topUp: number | string | BN,
|
|
216
|
+
_doClaim: boolean
|
|
217
|
+
): NonPayableTransactionObject<void>;
|
|
218
|
+
|
|
219
|
+
stashedColl(arg0: string): NonPayableTransactionObject<string>;
|
|
220
|
+
|
|
221
|
+
triggerBoldRewards(
|
|
222
|
+
_boldYield: number | string | BN
|
|
223
|
+
): NonPayableTransactionObject<void>;
|
|
224
|
+
|
|
225
|
+
troveManager(): NonPayableTransactionObject<string>;
|
|
226
|
+
|
|
227
|
+
withdrawFromSP(
|
|
228
|
+
_amount: number | string | BN,
|
|
229
|
+
_doClaim: boolean
|
|
230
|
+
): NonPayableTransactionObject<void>;
|
|
231
|
+
};
|
|
232
|
+
events: {
|
|
233
|
+
ActivePoolAddressChanged(
|
|
234
|
+
cb?: Callback<ActivePoolAddressChanged>
|
|
235
|
+
): EventEmitter;
|
|
236
|
+
ActivePoolAddressChanged(
|
|
237
|
+
options?: EventOptions,
|
|
238
|
+
cb?: Callback<ActivePoolAddressChanged>
|
|
239
|
+
): EventEmitter;
|
|
240
|
+
|
|
241
|
+
B_Updated(cb?: Callback<B_Updated>): EventEmitter;
|
|
242
|
+
B_Updated(options?: EventOptions, cb?: Callback<B_Updated>): EventEmitter;
|
|
243
|
+
|
|
244
|
+
BoldTokenAddressChanged(
|
|
245
|
+
cb?: Callback<BoldTokenAddressChanged>
|
|
246
|
+
): EventEmitter;
|
|
247
|
+
BoldTokenAddressChanged(
|
|
248
|
+
options?: EventOptions,
|
|
249
|
+
cb?: Callback<BoldTokenAddressChanged>
|
|
250
|
+
): EventEmitter;
|
|
251
|
+
|
|
252
|
+
DefaultPoolAddressChanged(
|
|
253
|
+
cb?: Callback<DefaultPoolAddressChanged>
|
|
254
|
+
): EventEmitter;
|
|
255
|
+
DefaultPoolAddressChanged(
|
|
256
|
+
options?: EventOptions,
|
|
257
|
+
cb?: Callback<DefaultPoolAddressChanged>
|
|
258
|
+
): EventEmitter;
|
|
259
|
+
|
|
260
|
+
DepositOperation(cb?: Callback<DepositOperation>): EventEmitter;
|
|
261
|
+
DepositOperation(
|
|
262
|
+
options?: EventOptions,
|
|
263
|
+
cb?: Callback<DepositOperation>
|
|
264
|
+
): EventEmitter;
|
|
265
|
+
|
|
266
|
+
DepositUpdated(cb?: Callback<DepositUpdated>): EventEmitter;
|
|
267
|
+
DepositUpdated(
|
|
268
|
+
options?: EventOptions,
|
|
269
|
+
cb?: Callback<DepositUpdated>
|
|
270
|
+
): EventEmitter;
|
|
271
|
+
|
|
272
|
+
EpochUpdated(cb?: Callback<EpochUpdated>): EventEmitter;
|
|
273
|
+
EpochUpdated(
|
|
274
|
+
options?: EventOptions,
|
|
275
|
+
cb?: Callback<EpochUpdated>
|
|
276
|
+
): EventEmitter;
|
|
277
|
+
|
|
278
|
+
EtherSent(cb?: Callback<EtherSent>): EventEmitter;
|
|
279
|
+
EtherSent(options?: EventOptions, cb?: Callback<EtherSent>): EventEmitter;
|
|
280
|
+
|
|
281
|
+
P_Updated(cb?: Callback<P_Updated>): EventEmitter;
|
|
282
|
+
P_Updated(options?: EventOptions, cb?: Callback<P_Updated>): EventEmitter;
|
|
283
|
+
|
|
284
|
+
PriceFeedAddressChanged(
|
|
285
|
+
cb?: Callback<PriceFeedAddressChanged>
|
|
286
|
+
): EventEmitter;
|
|
287
|
+
PriceFeedAddressChanged(
|
|
288
|
+
options?: EventOptions,
|
|
289
|
+
cb?: Callback<PriceFeedAddressChanged>
|
|
290
|
+
): EventEmitter;
|
|
291
|
+
|
|
292
|
+
S_Updated(cb?: Callback<S_Updated>): EventEmitter;
|
|
293
|
+
S_Updated(options?: EventOptions, cb?: Callback<S_Updated>): EventEmitter;
|
|
294
|
+
|
|
295
|
+
ScaleUpdated(cb?: Callback<ScaleUpdated>): EventEmitter;
|
|
296
|
+
ScaleUpdated(
|
|
297
|
+
options?: EventOptions,
|
|
298
|
+
cb?: Callback<ScaleUpdated>
|
|
299
|
+
): EventEmitter;
|
|
300
|
+
|
|
301
|
+
StabilityPoolBoldBalanceUpdated(
|
|
302
|
+
cb?: Callback<StabilityPoolBoldBalanceUpdated>
|
|
303
|
+
): EventEmitter;
|
|
304
|
+
StabilityPoolBoldBalanceUpdated(
|
|
305
|
+
options?: EventOptions,
|
|
306
|
+
cb?: Callback<StabilityPoolBoldBalanceUpdated>
|
|
307
|
+
): EventEmitter;
|
|
308
|
+
|
|
309
|
+
StabilityPoolCollBalanceUpdated(
|
|
310
|
+
cb?: Callback<StabilityPoolCollBalanceUpdated>
|
|
311
|
+
): EventEmitter;
|
|
312
|
+
StabilityPoolCollBalanceUpdated(
|
|
313
|
+
options?: EventOptions,
|
|
314
|
+
cb?: Callback<StabilityPoolCollBalanceUpdated>
|
|
315
|
+
): EventEmitter;
|
|
316
|
+
|
|
317
|
+
TroveManagerAddressChanged(
|
|
318
|
+
cb?: Callback<TroveManagerAddressChanged>
|
|
319
|
+
): EventEmitter;
|
|
320
|
+
TroveManagerAddressChanged(
|
|
321
|
+
options?: EventOptions,
|
|
322
|
+
cb?: Callback<TroveManagerAddressChanged>
|
|
323
|
+
): EventEmitter;
|
|
324
|
+
|
|
325
|
+
allEvents(options?: EventOptions, cb?: Callback<EventLog>): EventEmitter;
|
|
326
|
+
};
|
|
327
|
+
|
|
328
|
+
once(
|
|
329
|
+
event: "ActivePoolAddressChanged",
|
|
330
|
+
cb: Callback<ActivePoolAddressChanged>
|
|
331
|
+
): void;
|
|
332
|
+
once(
|
|
333
|
+
event: "ActivePoolAddressChanged",
|
|
334
|
+
options: EventOptions,
|
|
335
|
+
cb: Callback<ActivePoolAddressChanged>
|
|
336
|
+
): void;
|
|
337
|
+
|
|
338
|
+
once(event: "B_Updated", cb: Callback<B_Updated>): void;
|
|
339
|
+
once(
|
|
340
|
+
event: "B_Updated",
|
|
341
|
+
options: EventOptions,
|
|
342
|
+
cb: Callback<B_Updated>
|
|
343
|
+
): void;
|
|
344
|
+
|
|
345
|
+
once(
|
|
346
|
+
event: "BoldTokenAddressChanged",
|
|
347
|
+
cb: Callback<BoldTokenAddressChanged>
|
|
348
|
+
): void;
|
|
349
|
+
once(
|
|
350
|
+
event: "BoldTokenAddressChanged",
|
|
351
|
+
options: EventOptions,
|
|
352
|
+
cb: Callback<BoldTokenAddressChanged>
|
|
353
|
+
): void;
|
|
354
|
+
|
|
355
|
+
once(
|
|
356
|
+
event: "DefaultPoolAddressChanged",
|
|
357
|
+
cb: Callback<DefaultPoolAddressChanged>
|
|
358
|
+
): void;
|
|
359
|
+
once(
|
|
360
|
+
event: "DefaultPoolAddressChanged",
|
|
361
|
+
options: EventOptions,
|
|
362
|
+
cb: Callback<DefaultPoolAddressChanged>
|
|
363
|
+
): void;
|
|
364
|
+
|
|
365
|
+
once(event: "DepositOperation", cb: Callback<DepositOperation>): void;
|
|
366
|
+
once(
|
|
367
|
+
event: "DepositOperation",
|
|
368
|
+
options: EventOptions,
|
|
369
|
+
cb: Callback<DepositOperation>
|
|
370
|
+
): void;
|
|
371
|
+
|
|
372
|
+
once(event: "DepositUpdated", cb: Callback<DepositUpdated>): void;
|
|
373
|
+
once(
|
|
374
|
+
event: "DepositUpdated",
|
|
375
|
+
options: EventOptions,
|
|
376
|
+
cb: Callback<DepositUpdated>
|
|
377
|
+
): void;
|
|
378
|
+
|
|
379
|
+
once(event: "EpochUpdated", cb: Callback<EpochUpdated>): void;
|
|
380
|
+
once(
|
|
381
|
+
event: "EpochUpdated",
|
|
382
|
+
options: EventOptions,
|
|
383
|
+
cb: Callback<EpochUpdated>
|
|
384
|
+
): void;
|
|
385
|
+
|
|
386
|
+
once(event: "EtherSent", cb: Callback<EtherSent>): void;
|
|
387
|
+
once(
|
|
388
|
+
event: "EtherSent",
|
|
389
|
+
options: EventOptions,
|
|
390
|
+
cb: Callback<EtherSent>
|
|
391
|
+
): void;
|
|
392
|
+
|
|
393
|
+
once(event: "P_Updated", cb: Callback<P_Updated>): void;
|
|
394
|
+
once(
|
|
395
|
+
event: "P_Updated",
|
|
396
|
+
options: EventOptions,
|
|
397
|
+
cb: Callback<P_Updated>
|
|
398
|
+
): void;
|
|
399
|
+
|
|
400
|
+
once(
|
|
401
|
+
event: "PriceFeedAddressChanged",
|
|
402
|
+
cb: Callback<PriceFeedAddressChanged>
|
|
403
|
+
): void;
|
|
404
|
+
once(
|
|
405
|
+
event: "PriceFeedAddressChanged",
|
|
406
|
+
options: EventOptions,
|
|
407
|
+
cb: Callback<PriceFeedAddressChanged>
|
|
408
|
+
): void;
|
|
409
|
+
|
|
410
|
+
once(event: "S_Updated", cb: Callback<S_Updated>): void;
|
|
411
|
+
once(
|
|
412
|
+
event: "S_Updated",
|
|
413
|
+
options: EventOptions,
|
|
414
|
+
cb: Callback<S_Updated>
|
|
415
|
+
): void;
|
|
416
|
+
|
|
417
|
+
once(event: "ScaleUpdated", cb: Callback<ScaleUpdated>): void;
|
|
418
|
+
once(
|
|
419
|
+
event: "ScaleUpdated",
|
|
420
|
+
options: EventOptions,
|
|
421
|
+
cb: Callback<ScaleUpdated>
|
|
422
|
+
): void;
|
|
423
|
+
|
|
424
|
+
once(
|
|
425
|
+
event: "StabilityPoolBoldBalanceUpdated",
|
|
426
|
+
cb: Callback<StabilityPoolBoldBalanceUpdated>
|
|
427
|
+
): void;
|
|
428
|
+
once(
|
|
429
|
+
event: "StabilityPoolBoldBalanceUpdated",
|
|
430
|
+
options: EventOptions,
|
|
431
|
+
cb: Callback<StabilityPoolBoldBalanceUpdated>
|
|
432
|
+
): void;
|
|
433
|
+
|
|
434
|
+
once(
|
|
435
|
+
event: "StabilityPoolCollBalanceUpdated",
|
|
436
|
+
cb: Callback<StabilityPoolCollBalanceUpdated>
|
|
437
|
+
): void;
|
|
438
|
+
once(
|
|
439
|
+
event: "StabilityPoolCollBalanceUpdated",
|
|
440
|
+
options: EventOptions,
|
|
441
|
+
cb: Callback<StabilityPoolCollBalanceUpdated>
|
|
442
|
+
): void;
|
|
443
|
+
|
|
444
|
+
once(
|
|
445
|
+
event: "TroveManagerAddressChanged",
|
|
446
|
+
cb: Callback<TroveManagerAddressChanged>
|
|
447
|
+
): void;
|
|
448
|
+
once(
|
|
449
|
+
event: "TroveManagerAddressChanged",
|
|
450
|
+
options: EventOptions,
|
|
451
|
+
cb: Callback<TroveManagerAddressChanged>
|
|
452
|
+
): void;
|
|
453
|
+
}
|
|
@@ -21,6 +21,85 @@ export interface EventOptions {
|
|
|
21
21
|
topics?: string[];
|
|
22
22
|
}
|
|
23
23
|
|
|
24
|
+
export declare namespace IBorrowerOperations {
|
|
25
|
+
export type InterestBatchManagerStruct =
|
|
26
|
+
| [number | string | BN, number | string | BN, number | string | BN]
|
|
27
|
+
| {
|
|
28
|
+
minInterestRate: number | string | BN;
|
|
29
|
+
maxInterestRate: number | string | BN;
|
|
30
|
+
minInterestRateChangePeriod: number | string | BN;
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
export type InterestBatchManagerStructOutputArray = [string, string, string];
|
|
34
|
+
export type InterestBatchManagerStructOutputStruct = {
|
|
35
|
+
minInterestRate: string;
|
|
36
|
+
maxInterestRate: string;
|
|
37
|
+
minInterestRateChangePeriod: string;
|
|
38
|
+
};
|
|
39
|
+
export type InterestBatchManagerStructOutput =
|
|
40
|
+
InterestBatchManagerStructOutputArray &
|
|
41
|
+
InterestBatchManagerStructOutputStruct;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export declare namespace ITroveManager {
|
|
45
|
+
export type LatestBatchDataStruct =
|
|
46
|
+
| [
|
|
47
|
+
number | string | BN,
|
|
48
|
+
number | string | BN,
|
|
49
|
+
number | string | BN,
|
|
50
|
+
number | string | BN,
|
|
51
|
+
number | string | BN,
|
|
52
|
+
number | string | BN,
|
|
53
|
+
number | string | BN,
|
|
54
|
+
number | string | BN,
|
|
55
|
+
number | string | BN,
|
|
56
|
+
number | string | BN,
|
|
57
|
+
number | string | BN
|
|
58
|
+
]
|
|
59
|
+
| {
|
|
60
|
+
entireDebtWithoutRedistribution: number | string | BN;
|
|
61
|
+
entireCollWithoutRedistribution: number | string | BN;
|
|
62
|
+
accruedInterest: number | string | BN;
|
|
63
|
+
recordedDebt: number | string | BN;
|
|
64
|
+
annualInterestRate: number | string | BN;
|
|
65
|
+
weightedRecordedDebt: number | string | BN;
|
|
66
|
+
annualManagementFee: number | string | BN;
|
|
67
|
+
accruedManagementFee: number | string | BN;
|
|
68
|
+
weightedRecordedBatchManagementFee: number | string | BN;
|
|
69
|
+
lastDebtUpdateTime: number | string | BN;
|
|
70
|
+
lastInterestRateAdjTime: number | string | BN;
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
export type LatestBatchDataStructOutputArray = [
|
|
74
|
+
string,
|
|
75
|
+
string,
|
|
76
|
+
string,
|
|
77
|
+
string,
|
|
78
|
+
string,
|
|
79
|
+
string,
|
|
80
|
+
string,
|
|
81
|
+
string,
|
|
82
|
+
string,
|
|
83
|
+
string,
|
|
84
|
+
string
|
|
85
|
+
];
|
|
86
|
+
export type LatestBatchDataStructOutputStruct = {
|
|
87
|
+
entireDebtWithoutRedistribution: string;
|
|
88
|
+
entireCollWithoutRedistribution: string;
|
|
89
|
+
accruedInterest: string;
|
|
90
|
+
recordedDebt: string;
|
|
91
|
+
annualInterestRate: string;
|
|
92
|
+
weightedRecordedDebt: string;
|
|
93
|
+
annualManagementFee: string;
|
|
94
|
+
accruedManagementFee: string;
|
|
95
|
+
weightedRecordedBatchManagementFee: string;
|
|
96
|
+
lastDebtUpdateTime: string;
|
|
97
|
+
lastInterestRateAdjTime: string;
|
|
98
|
+
};
|
|
99
|
+
export type LatestBatchDataStructOutput = LatestBatchDataStructOutputArray &
|
|
100
|
+
LatestBatchDataStructOutputStruct;
|
|
101
|
+
}
|
|
102
|
+
|
|
24
103
|
export declare namespace LiquityV2View {
|
|
25
104
|
export type MarketDataStruct =
|
|
26
105
|
| [
|
|
@@ -43,7 +122,8 @@ export declare namespace LiquityV2View {
|
|
|
43
122
|
string,
|
|
44
123
|
string,
|
|
45
124
|
number | string | BN,
|
|
46
|
-
boolean
|
|
125
|
+
boolean,
|
|
126
|
+
number | string | BN
|
|
47
127
|
]
|
|
48
128
|
| {
|
|
49
129
|
market: string;
|
|
@@ -66,6 +146,7 @@ export declare namespace LiquityV2View {
|
|
|
66
146
|
priceFeed: string;
|
|
67
147
|
collPrice: number | string | BN;
|
|
68
148
|
isShutDown: boolean;
|
|
149
|
+
boldDepositInSp: number | string | BN;
|
|
69
150
|
};
|
|
70
151
|
|
|
71
152
|
export type MarketDataStructOutputArray = [
|
|
@@ -88,7 +169,8 @@ export declare namespace LiquityV2View {
|
|
|
88
169
|
string,
|
|
89
170
|
string,
|
|
90
171
|
string,
|
|
91
|
-
boolean
|
|
172
|
+
boolean,
|
|
173
|
+
string
|
|
92
174
|
];
|
|
93
175
|
export type MarketDataStructOutputStruct = {
|
|
94
176
|
market: string;
|
|
@@ -111,6 +193,7 @@ export declare namespace LiquityV2View {
|
|
|
111
193
|
priceFeed: string;
|
|
112
194
|
collPrice: string;
|
|
113
195
|
isShutDown: boolean;
|
|
196
|
+
boldDepositInSp: string;
|
|
114
197
|
};
|
|
115
198
|
export type MarketDataStructOutput = MarketDataStructOutputArray &
|
|
116
199
|
MarketDataStructOutputStruct;
|
|
@@ -127,6 +210,7 @@ export declare namespace LiquityV2View {
|
|
|
127
210
|
number | string | BN,
|
|
128
211
|
number | string | BN,
|
|
129
212
|
string,
|
|
213
|
+
number | string | BN,
|
|
130
214
|
number | string | BN
|
|
131
215
|
]
|
|
132
216
|
| {
|
|
@@ -141,6 +225,7 @@ export declare namespace LiquityV2View {
|
|
|
141
225
|
annualInterestRate: number | string | BN;
|
|
142
226
|
interestBatchManager: string;
|
|
143
227
|
batchDebtShares: number | string | BN;
|
|
228
|
+
lastInterestRateAdjTime: number | string | BN;
|
|
144
229
|
};
|
|
145
230
|
|
|
146
231
|
export type TroveDataStructOutputArray = [
|
|
@@ -154,6 +239,7 @@ export declare namespace LiquityV2View {
|
|
|
154
239
|
string,
|
|
155
240
|
string,
|
|
156
241
|
string,
|
|
242
|
+
string,
|
|
157
243
|
string
|
|
158
244
|
];
|
|
159
245
|
export type TroveDataStructOutputStruct = {
|
|
@@ -168,6 +254,7 @@ export declare namespace LiquityV2View {
|
|
|
168
254
|
annualInterestRate: string;
|
|
169
255
|
interestBatchManager: string;
|
|
170
256
|
batchDebtShares: string;
|
|
257
|
+
lastInterestRateAdjTime: string;
|
|
171
258
|
};
|
|
172
259
|
export type TroveDataStructOutput = TroveDataStructOutputArray &
|
|
173
260
|
TroveDataStructOutputStruct;
|
|
@@ -185,6 +272,69 @@ export declare namespace LiquityV2View {
|
|
|
185
272
|
ExistingTroveStructOutputStruct;
|
|
186
273
|
}
|
|
187
274
|
|
|
275
|
+
export declare namespace IMultiTroveGetter {
|
|
276
|
+
export type CombinedTroveDataStruct =
|
|
277
|
+
| [
|
|
278
|
+
number | string | BN,
|
|
279
|
+
number | string | BN,
|
|
280
|
+
number | string | BN,
|
|
281
|
+
number | string | BN,
|
|
282
|
+
number | string | BN,
|
|
283
|
+
number | string | BN,
|
|
284
|
+
number | string | BN,
|
|
285
|
+
string,
|
|
286
|
+
number | string | BN,
|
|
287
|
+
number | string | BN,
|
|
288
|
+
number | string | BN,
|
|
289
|
+
number | string | BN
|
|
290
|
+
]
|
|
291
|
+
| {
|
|
292
|
+
id: number | string | BN;
|
|
293
|
+
debt: number | string | BN;
|
|
294
|
+
coll: number | string | BN;
|
|
295
|
+
stake: number | string | BN;
|
|
296
|
+
annualInterestRate: number | string | BN;
|
|
297
|
+
lastDebtUpdateTime: number | string | BN;
|
|
298
|
+
lastInterestRateAdjTime: number | string | BN;
|
|
299
|
+
interestBatchManager: string;
|
|
300
|
+
batchDebtShares: number | string | BN;
|
|
301
|
+
batchCollShares: number | string | BN;
|
|
302
|
+
snapshotETH: number | string | BN;
|
|
303
|
+
snapshotBoldDebt: number | string | BN;
|
|
304
|
+
};
|
|
305
|
+
|
|
306
|
+
export type CombinedTroveDataStructOutputArray = [
|
|
307
|
+
string,
|
|
308
|
+
string,
|
|
309
|
+
string,
|
|
310
|
+
string,
|
|
311
|
+
string,
|
|
312
|
+
string,
|
|
313
|
+
string,
|
|
314
|
+
string,
|
|
315
|
+
string,
|
|
316
|
+
string,
|
|
317
|
+
string,
|
|
318
|
+
string
|
|
319
|
+
];
|
|
320
|
+
export type CombinedTroveDataStructOutputStruct = {
|
|
321
|
+
id: string;
|
|
322
|
+
debt: string;
|
|
323
|
+
coll: string;
|
|
324
|
+
stake: string;
|
|
325
|
+
annualInterestRate: string;
|
|
326
|
+
lastDebtUpdateTime: string;
|
|
327
|
+
lastInterestRateAdjTime: string;
|
|
328
|
+
interestBatchManager: string;
|
|
329
|
+
batchDebtShares: string;
|
|
330
|
+
batchCollShares: string;
|
|
331
|
+
snapshotETH: string;
|
|
332
|
+
snapshotBoldDebt: string;
|
|
333
|
+
};
|
|
334
|
+
export type CombinedTroveDataStructOutput =
|
|
335
|
+
CombinedTroveDataStructOutputArray & CombinedTroveDataStructOutputStruct;
|
|
336
|
+
}
|
|
337
|
+
|
|
188
338
|
export interface LiquityV2View extends BaseContract {
|
|
189
339
|
constructor(
|
|
190
340
|
jsonInterface: any[],
|
|
@@ -216,6 +366,19 @@ export interface LiquityV2View extends BaseContract {
|
|
|
216
366
|
}
|
|
217
367
|
>;
|
|
218
368
|
|
|
369
|
+
getBatchManagerInfo(
|
|
370
|
+
_market: string,
|
|
371
|
+
_manager: string
|
|
372
|
+
): NonPayableTransactionObject<
|
|
373
|
+
[
|
|
374
|
+
IBorrowerOperations.InterestBatchManagerStructOutput,
|
|
375
|
+
ITroveManager.LatestBatchDataStructOutput
|
|
376
|
+
] & {
|
|
377
|
+
managerData: IBorrowerOperations.InterestBatchManagerStructOutput;
|
|
378
|
+
batchData: ITroveManager.LatestBatchDataStructOutput;
|
|
379
|
+
}
|
|
380
|
+
>;
|
|
381
|
+
|
|
219
382
|
getDebtInFront(
|
|
220
383
|
_market: string,
|
|
221
384
|
_troveId: number | string | BN,
|
|
@@ -265,6 +428,14 @@ export interface LiquityV2View extends BaseContract {
|
|
|
265
428
|
_market: string
|
|
266
429
|
): NonPayableTransactionObject<LiquityV2View.MarketDataStructOutput>;
|
|
267
430
|
|
|
431
|
+
getMultipleSortedTroves(
|
|
432
|
+
_market: string,
|
|
433
|
+
_startIdx: number | string | BN,
|
|
434
|
+
_count: number | string | BN
|
|
435
|
+
): NonPayableTransactionObject<
|
|
436
|
+
IMultiTroveGetter.CombinedTroveDataStructOutput[]
|
|
437
|
+
>;
|
|
438
|
+
|
|
268
439
|
getNumOfTrovesInFrontOfTrove(
|
|
269
440
|
_market: string,
|
|
270
441
|
_troveId: number | string | BN,
|
|
@@ -41,6 +41,7 @@ export type { LendingPoolAddressesProvider } from "./LendingPoolAddressesProvide
|
|
|
41
41
|
export type { Lido } from "./Lido";
|
|
42
42
|
export type { LiquityActivePool } from "./LiquityActivePool";
|
|
43
43
|
export type { LiquityV2CollSurplusPool } from "./LiquityV2CollSurplusPool";
|
|
44
|
+
export type { LiquityV2StabilityPool } from "./LiquityV2StabilityPool";
|
|
44
45
|
export type { LiquityV2TroveNFT } from "./LiquityV2TroveNFT";
|
|
45
46
|
export type { LiquityV2View } from "./LiquityV2View";
|
|
46
47
|
export type { LiquityView } from "./LiquityView";
|