@gearbox-protocol/sdk 14.12.0-next.74 → 14.12.0-next.75
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/dist/cjs/plugins/accounts-counter/AccountsCounterPlugin.js +1 -1
- package/dist/cjs/sdk/accounts/CreditAccountsServiceV310.js +73 -445
- package/dist/cjs/sdk/accounts/credit-account-compressor/CreditAccountCompressor.js +280 -0
- package/dist/cjs/sdk/accounts/credit-account-compressor/CreditAccountCompressorV310Contract.js +141 -0
- package/dist/cjs/sdk/accounts/credit-account-compressor/index.js +6 -0
- package/dist/cjs/sdk/accounts/credit-account-compressor/types.js +1 -0
- package/dist/cjs/sdk/accounts/index.js +5 -0
- package/dist/cjs/sdk/index.js +4 -0
- package/dist/cjs/sdk/market/oracle/PriceOracleBaseContract.js +41 -1
- package/dist/cjs/sdk/market/oracle/PriceOracleV310Contract.js +0 -23
- package/dist/cjs/sdk/market/pricefeeds/PriceFeedsRegister.js +1 -1
- package/dist/esm/plugins/accounts-counter/AccountsCounterPlugin.js +1 -1
- package/dist/esm/sdk/accounts/CreditAccountsServiceV310.js +74 -446
- package/dist/esm/sdk/accounts/credit-account-compressor/CreditAccountCompressor.js +279 -0
- package/dist/esm/sdk/accounts/credit-account-compressor/CreditAccountCompressorV310Contract.js +141 -0
- package/dist/esm/sdk/accounts/credit-account-compressor/index.js +4 -0
- package/dist/esm/sdk/accounts/credit-account-compressor/types.js +1 -0
- package/dist/esm/sdk/accounts/index.js +4 -1
- package/dist/esm/sdk/index.js +3 -1
- package/dist/esm/sdk/market/oracle/PriceOracleBaseContract.js +41 -1
- package/dist/esm/sdk/market/oracle/PriceOracleV310Contract.js +0 -23
- package/dist/esm/sdk/market/pricefeeds/PriceFeedsRegister.js +1 -1
- package/dist/types/plugins/accounts/AccountsPlugin.d.ts +1 -1
- package/dist/types/sdk/accounts/CreditAccountsServiceV310.d.ts +10 -44
- package/dist/types/sdk/accounts/credit-account-compressor/CreditAccountCompressor.d.ts +60 -0
- package/dist/types/sdk/accounts/credit-account-compressor/CreditAccountCompressorV310Contract.d.ts +879 -0
- package/dist/types/sdk/accounts/credit-account-compressor/index.d.ts +4 -0
- package/dist/types/sdk/accounts/credit-account-compressor/types.d.ts +164 -0
- package/dist/types/sdk/accounts/index.d.ts +7 -3
- package/dist/types/sdk/accounts/types.d.ts +5 -112
- package/dist/types/sdk/base/index.d.ts +2 -2
- package/dist/types/sdk/base/types.d.ts +6 -1
- package/dist/types/sdk/index.d.ts +8 -5
- package/dist/types/sdk/market/index.d.ts +2 -2
- package/dist/types/sdk/market/oracle/PriceOracleBaseContract.d.ts +15 -4
- package/dist/types/sdk/market/oracle/PriceOracleV310Contract.d.ts +0 -11
- package/dist/types/sdk/market/oracle/index.d.ts +2 -2
- package/dist/types/sdk/market/oracle/types.d.ts +30 -14
- package/package.json +1 -1
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { CreditAccountDataCall, CreditAccountFilter, CreditAccountReadOptions, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsTarget, CreditManagerFilter, GetCreditAccountsArgs, GetCreditAccountsOptions, ListStrategyPositionsProps } from "./types.js";
|
|
2
|
+
import { CreditAccountCompressor } from "./CreditAccountCompressor.js";
|
|
3
|
+
import { CreditAccountCompressorV310Contract } from "./CreditAccountCompressorV310Contract.js";
|
|
4
|
+
export { CreditAccountCompressor, CreditAccountCompressorV310Contract, CreditAccountDataCall, CreditAccountFilter, CreditAccountReadOptions, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsTarget, CreditManagerFilter, GetCreditAccountsArgs, GetCreditAccountsOptions, ListStrategyPositionsProps };
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
import { creditAccountCompressorAbi } from "../../../abi/compressors/creditAccountCompressor.js";
|
|
2
|
+
import { IPriceUpdateTx } from "../../types/transactions.js";
|
|
3
|
+
import "../../types/index.js";
|
|
4
|
+
import { Address, ContractFunctionArgs, ContractFunctionParameters } from "viem";
|
|
5
|
+
//#region src/sdk/accounts/credit-account-compressor/types.d.ts
|
|
6
|
+
/**
|
|
7
|
+
* @internal
|
|
8
|
+
* Arguments tuple for the credit account compressor's `getCreditAccounts` view method.
|
|
9
|
+
**/
|
|
10
|
+
type GetCreditAccountsArgs = ContractFunctionArgs<typeof creditAccountCompressorAbi, "pure" | "view", "getCreditAccounts">;
|
|
11
|
+
/**
|
|
12
|
+
* @internal
|
|
13
|
+
* Descriptor of a `getCreditAccountData` call, so that it can be batched with
|
|
14
|
+
* calls to other contracts.
|
|
15
|
+
**/
|
|
16
|
+
type CreditAccountDataCall = ContractFunctionParameters<typeof creditAccountCompressorAbi, "pure" | "view", "getCreditAccountData">;
|
|
17
|
+
/**
|
|
18
|
+
* @internal
|
|
19
|
+
* Descriptor of a `getCreditAccounts` call, so that it can be batched with
|
|
20
|
+
* calls to other contracts.
|
|
21
|
+
**/
|
|
22
|
+
type CreditAccountsCall = ContractFunctionParameters<typeof creditAccountCompressorAbi, "pure" | "view", "getCreditAccounts">;
|
|
23
|
+
/**
|
|
24
|
+
* @internal
|
|
25
|
+
* Filtering criteria applied to individual credit accounts when querying the compressor.
|
|
26
|
+
**/
|
|
27
|
+
interface CreditAccountFilter {
|
|
28
|
+
/**
|
|
29
|
+
* Filter by account owner address.
|
|
30
|
+
**/
|
|
31
|
+
owner: Address;
|
|
32
|
+
/**
|
|
33
|
+
* Whether to include accounts with zero outstanding debt.
|
|
34
|
+
**/
|
|
35
|
+
includeZeroDebt: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* Minimum health factor threshold (inclusive).
|
|
38
|
+
* 18 digits precision (10^18 = 1)
|
|
39
|
+
**/
|
|
40
|
+
minHealthFactor: bigint;
|
|
41
|
+
/**
|
|
42
|
+
* Maximum health factor threshold (inclusive).
|
|
43
|
+
* 18 digits precision (10^18 = 1)
|
|
44
|
+
**/
|
|
45
|
+
maxHealthFactor: bigint;
|
|
46
|
+
/**
|
|
47
|
+
* Whether to return only accounts whose health computation reverts.
|
|
48
|
+
**/
|
|
49
|
+
reverting: boolean;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* @internal
|
|
53
|
+
* Filtering criteria to select which credit managers to query.
|
|
54
|
+
**/
|
|
55
|
+
interface CreditManagerFilter {
|
|
56
|
+
/**
|
|
57
|
+
* Only include credit managers owned by these market configurators.
|
|
58
|
+
**/
|
|
59
|
+
configurators: readonly Address[];
|
|
60
|
+
/**
|
|
61
|
+
* Only include these specific credit manager addresses.
|
|
62
|
+
**/
|
|
63
|
+
creditManagers: readonly Address[];
|
|
64
|
+
/**
|
|
65
|
+
* Only include credit managers linked to these pool addresses.
|
|
66
|
+
**/
|
|
67
|
+
pools: readonly Address[];
|
|
68
|
+
/**
|
|
69
|
+
* Only include credit managers with this underlying token.
|
|
70
|
+
**/
|
|
71
|
+
underlying: Address;
|
|
72
|
+
}
|
|
73
|
+
/**
|
|
74
|
+
* @internal
|
|
75
|
+
* Credit managers a compressor query runs over: either one credit manager
|
|
76
|
+
* address, or a filter matching many of them.
|
|
77
|
+
**/
|
|
78
|
+
type CreditAccountsTarget = Address | CreditManagerFilter;
|
|
79
|
+
/**
|
|
80
|
+
* @internal
|
|
81
|
+
* Account-level criteria of a compressor query, without `reverting`: the
|
|
82
|
+
* compressor treats that flag as exclusive, so a full query has to run both
|
|
83
|
+
* passes and callers do not choose one.
|
|
84
|
+
**/
|
|
85
|
+
type CreditAccountsQuery = Omit<CreditAccountFilter, "reverting">;
|
|
86
|
+
/**
|
|
87
|
+
* @internal
|
|
88
|
+
* Common options of a credit account compressor read.
|
|
89
|
+
**/
|
|
90
|
+
interface CreditAccountReadOptions {
|
|
91
|
+
/**
|
|
92
|
+
* Block to read at. Defaults to the latest block.
|
|
93
|
+
**/
|
|
94
|
+
blockNumber?: bigint;
|
|
95
|
+
/**
|
|
96
|
+
* Price feed update transactions to execute before the read, so that
|
|
97
|
+
* accounts holding tokens with on-demand price feeds can be valued.
|
|
98
|
+
**/
|
|
99
|
+
priceUpdateTxs?: IPriceUpdateTx[];
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* @internal
|
|
103
|
+
* Options of a paginated credit account compressor read.
|
|
104
|
+
**/
|
|
105
|
+
interface CreditAccountsReadOptions extends CreditAccountReadOptions {
|
|
106
|
+
/**
|
|
107
|
+
* Maximum number of accounts to fetch per call. When set, accounts are
|
|
108
|
+
* loaded in pages of this size until all are fetched.
|
|
109
|
+
*
|
|
110
|
+
* @default undefined - no limit, the compressor returns as many accounts as
|
|
111
|
+
* it can per call
|
|
112
|
+
**/
|
|
113
|
+
batchSize?: bigint;
|
|
114
|
+
}
|
|
115
|
+
/**
|
|
116
|
+
* Options for fetching credit accounts, allowing filtering by credit manager, owner, and health factor range.
|
|
117
|
+
**/
|
|
118
|
+
interface GetCreditAccountsOptions {
|
|
119
|
+
/**
|
|
120
|
+
* If set, only return accounts from this credit manager; otherwise query all attached markets.
|
|
121
|
+
**/
|
|
122
|
+
creditManager?: Address;
|
|
123
|
+
/**
|
|
124
|
+
* If set, only return accounts owned by this address.
|
|
125
|
+
**/
|
|
126
|
+
owner?: Address;
|
|
127
|
+
/**
|
|
128
|
+
* Whether to include accounts with zero outstanding debt.
|
|
129
|
+
* @default false
|
|
130
|
+
**/
|
|
131
|
+
includeZeroDebt?: boolean;
|
|
132
|
+
/**
|
|
133
|
+
* Minimum health factor threshold (inclusive).
|
|
134
|
+
* 18 digits precision (10^18 = 1)
|
|
135
|
+
* @default 0n
|
|
136
|
+
**/
|
|
137
|
+
minHealthFactor?: bigint;
|
|
138
|
+
/**
|
|
139
|
+
* Maximum health factor threshold (inclusive).
|
|
140
|
+
* 18 digits precision (10^18 = 1)
|
|
141
|
+
* @default MAX_UINT256
|
|
142
|
+
**/
|
|
143
|
+
maxHealthFactor?: bigint;
|
|
144
|
+
/**
|
|
145
|
+
* If true, exclude reserve price feed updates from the query.
|
|
146
|
+
**/
|
|
147
|
+
ignoreReservePrices?: boolean;
|
|
148
|
+
}
|
|
149
|
+
/**
|
|
150
|
+
* Props for {@link CreditAccountCompressor.listPositions}.
|
|
151
|
+
**/
|
|
152
|
+
interface ListStrategyPositionsProps {
|
|
153
|
+
/**
|
|
154
|
+
* Wallet whose credit accounts to describe. RWA accounts are resolved from
|
|
155
|
+
* the investor EOA, see {@link CreditAccountCompressor.getBorrowerCreditAccounts}.
|
|
156
|
+
**/
|
|
157
|
+
owner: Address;
|
|
158
|
+
/**
|
|
159
|
+
* Whether to include accounts that carry no debt.
|
|
160
|
+
**/
|
|
161
|
+
includeZeroDebt: boolean;
|
|
162
|
+
}
|
|
163
|
+
//#endregion
|
|
164
|
+
export { CreditAccountDataCall, CreditAccountFilter, CreditAccountReadOptions, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsTarget, CreditManagerFilter, GetCreditAccountsArgs, GetCreditAccountsOptions, ListStrategyPositionsProps };
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
import { ClaimableWithdrawal, CurrentWithdrawals, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, PendingWithdrawal, RedemptionLog, RequestableWithdrawal, WithdrawableAsset, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, toWithdrawalStatus } from "./withdrawal-compressor/types.js";
|
|
2
|
+
import { CreditAccountDataCall, CreditAccountFilter, CreditAccountReadOptions, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsTarget, CreditManagerFilter, GetCreditAccountsArgs, GetCreditAccountsOptions, ListStrategyPositionsProps } from "./credit-account-compressor/types.js";
|
|
3
|
+
import { CreditAccountCompressor } from "./credit-account-compressor/CreditAccountCompressor.js";
|
|
4
|
+
import { CreditAccountCompressorV310Contract } from "./credit-account-compressor/CreditAccountCompressorV310Contract.js";
|
|
5
|
+
import "./credit-account-compressor/index.js";
|
|
2
6
|
import { AbstractWithdrawalCompressorContract, OnchainRequestableWithdrawal, iCreditAccountAbi, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal } from "./withdrawal-compressor/AbstractWithdrawalCompressorContract.js";
|
|
3
7
|
import { WithdrawalCompressorLocation, WithdrawalCompressorVersion, getWithdrawalCompressorAddress } from "./withdrawal-compressor/addresses.js";
|
|
4
8
|
import { createRedemptionLogger } from "./withdrawal-compressor/createRedemptionLogger.js";
|
|
@@ -10,8 +14,8 @@ import { WithdrawalCompressorV310Contract } from "./withdrawal-compressor/Withdr
|
|
|
10
14
|
import { WithdrawalCompressorV311Contract } from "./withdrawal-compressor/WithdrawalCompressorV311Contract.js";
|
|
11
15
|
import { WithdrawalCompressorV313Contract } from "./withdrawal-compressor/WithdrawalCompressorV313Contract.js";
|
|
12
16
|
import "./withdrawal-compressor/index.js";
|
|
13
|
-
import { AccountToCheck, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, ClaimFarmRewardsProps, CloseCreditAccountResult,
|
|
14
|
-
import {
|
|
17
|
+
import { AccountToCheck, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, ClaimFarmRewardsProps, CloseCreditAccountResult, CreditAccountOperationResult, CreditManagerOperationResult, EncodableCreditAccountOperation, FullyLiquidateProps, FullyLiquidateResult, GetApprovalAddressProps, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, ICreditAccountsService, OpenCAProps, PartiallyLiquidateProps, PermitResult, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, Rewards, SetBotProps } from "./types.js";
|
|
18
|
+
import { CreditAccountsServiceV310 } from "./CreditAccountsServiceV310.js";
|
|
15
19
|
import { CreditAccountSlice, IntentPreviewResult } from "./intents/types.js";
|
|
16
20
|
import { primaryInstantOutput } from "./intents/operations/claim-delayed/index.js";
|
|
17
21
|
import { CreditAccountOperationsService } from "./intents/index.js";
|
|
@@ -20,4 +24,4 @@ import { BuildLiquidationTxProps, BuildLiquidationTxPropsBase, GetLiquidatableAc
|
|
|
20
24
|
import { LiquidationsService } from "./liquidations/LiquidationsService.js";
|
|
21
25
|
import { MultichainLiquidationsService } from "./liquidations/MultichainLiquidationsService.js";
|
|
22
26
|
import "./liquidations/index.js";
|
|
23
|
-
export { AbstractWithdrawalCompressorContract, AccountToCheck, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, BuildLiquidationTxProps, BuildLiquidationTxPropsBase, ClaimFarmRewardsProps, ClaimableWithdrawal, CloseCreditAccountResult, CreditAccountFilter, CreditAccountOperationResult, CreditAccountOperationsService,
|
|
27
|
+
export { AbstractWithdrawalCompressorContract, AccountToCheck, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, BuildLiquidationTxProps, BuildLiquidationTxPropsBase, ClaimFarmRewardsProps, ClaimableWithdrawal, CloseCreditAccountResult, CreditAccountCompressor, CreditAccountCompressorV310Contract, CreditAccountDataCall, CreditAccountFilter, CreditAccountOperationResult, CreditAccountOperationsService, CreditAccountReadOptions, type CreditAccountSlice, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsServiceV310, CreditAccountsTarget, CreditManagerFilter, CreditManagerOperationResult, CurrentWithdrawals, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, EncodableCreditAccountOperation, FullyLiquidateProps, FullyLiquidateResult, GetApprovalAddressProps, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetCreditAccountsArgs, GetCreditAccountsOptions, GetLiquidatableAccountsProps, GetLiquidatableAccountsPropsBase, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, GetWithdrawalRequestResultProps, ICreditAccountsService, IRedemptionLoggerContract, IWithdrawalCompressorContract, type IntentPreviewResult, InvalidDelayedIntentError, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LiquidationsService, ListStrategyPositionsProps, LoadRWALiquidatorsProps, MultichainLiquidationsService, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, OnchainRequestableWithdrawal, OpenCAProps, PartiallyLiquidateProps, PendingWithdrawal, PermitResult, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, RWALiquidatorInfo, RedemptionLog, RedemptionLoggerV310Contract, RequestableWithdrawal, Rewards, SetBotProps, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, createRedemptionLogger, createWithdrawalCompressor, decodeDelayedIntent, encodeDelayedIntent, getWithdrawalCompressorAddress, iCreditAccountAbi, primaryInstantOutput, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal, toWithdrawalStatus };
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { creditAccountCompressorAbi } from "../../abi/compressors/creditAccountCompressor.js";
|
|
2
1
|
import { StrategyPosition } from "../../model/positions.js";
|
|
3
2
|
import "../../model/index.js";
|
|
4
3
|
import { ClaimableWithdrawal, DelayedIntent, PendingWithdrawal, RequestableWithdrawal } from "./withdrawal-compressor/types.js";
|
|
5
|
-
import { Asset, ConnectedBotData, CreditAccountData } from "../base/types.js";
|
|
4
|
+
import { Asset, ConnectedBotData, CreditAccountData, CreditAccountTokensSlice } from "../base/types.js";
|
|
6
5
|
import { RWAOpenAccountRequirements, RWAOperationArgs } from "../market/rwa/types.js";
|
|
7
6
|
import "../market/rwa/index.js";
|
|
8
7
|
import { RouterCASlice, RouterCloseResult } from "../router/types.js";
|
|
9
8
|
import "../router/index.js";
|
|
9
|
+
import { GetCreditAccountsOptions, ListStrategyPositionsProps } from "./credit-account-compressor/types.js";
|
|
10
|
+
import "./credit-account-compressor/index.js";
|
|
10
11
|
import "./withdrawal-compressor/index.js";
|
|
11
12
|
import { PriceUpdate } from "../market/pricefeeds/types.js";
|
|
12
13
|
import { PartialLiquidationParams } from "../market/credit/types.js";
|
|
@@ -17,116 +18,8 @@ import { OnchainSDK } from "../OnchainSDK.js";
|
|
|
17
18
|
import { Construct } from "../base/Construct.js";
|
|
18
19
|
import "../types/index.js";
|
|
19
20
|
import "../base/index.js";
|
|
20
|
-
import { Address,
|
|
21
|
+
import { Address, Hex } from "viem";
|
|
21
22
|
//#region src/sdk/accounts/types.d.ts
|
|
22
|
-
/**
|
|
23
|
-
* @internal
|
|
24
|
-
* Arguments tuple for the credit account compressor's `getCreditAccounts` view method.
|
|
25
|
-
**/
|
|
26
|
-
type GetCreditAccountsArgs = ContractFunctionArgs<typeof creditAccountCompressorAbi, "pure" | "view", "getCreditAccounts">;
|
|
27
|
-
/**
|
|
28
|
-
* @internal
|
|
29
|
-
* Filtering criteria applied to individual credit accounts when querying the compressor.
|
|
30
|
-
**/
|
|
31
|
-
interface CreditAccountFilter {
|
|
32
|
-
/**
|
|
33
|
-
* Filter by account owner address.
|
|
34
|
-
**/
|
|
35
|
-
owner: Address;
|
|
36
|
-
/**
|
|
37
|
-
* Whether to include accounts with zero outstanding debt.
|
|
38
|
-
**/
|
|
39
|
-
includeZeroDebt: boolean;
|
|
40
|
-
/**
|
|
41
|
-
* Minimum health factor threshold (inclusive).
|
|
42
|
-
* 18 digits precision (10^18 = 1)
|
|
43
|
-
**/
|
|
44
|
-
minHealthFactor: bigint;
|
|
45
|
-
/**
|
|
46
|
-
* Maximum health factor threshold (inclusive).
|
|
47
|
-
* 18 digits precision (10^18 = 1)
|
|
48
|
-
**/
|
|
49
|
-
maxHealthFactor: bigint;
|
|
50
|
-
/**
|
|
51
|
-
* Whether to return only accounts whose health computation reverts.
|
|
52
|
-
**/
|
|
53
|
-
reverting: boolean;
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* @internal
|
|
57
|
-
* Filtering criteria to select which credit managers to query.
|
|
58
|
-
**/
|
|
59
|
-
interface CreditManagerFilter {
|
|
60
|
-
/**
|
|
61
|
-
* Only include credit managers owned by these market configurators.
|
|
62
|
-
**/
|
|
63
|
-
configurators: readonly Address[];
|
|
64
|
-
/**
|
|
65
|
-
* Only include these specific credit manager addresses.
|
|
66
|
-
**/
|
|
67
|
-
creditManagers: readonly Address[];
|
|
68
|
-
/**
|
|
69
|
-
* Only include credit managers linked to these pool addresses.
|
|
70
|
-
**/
|
|
71
|
-
pools: readonly Address[];
|
|
72
|
-
/**
|
|
73
|
-
* Only include credit managers with this underlying token.
|
|
74
|
-
**/
|
|
75
|
-
underlying: Address;
|
|
76
|
-
}
|
|
77
|
-
/**
|
|
78
|
-
* Options for fetching credit accounts, allowing filtering by credit manager, owner, and health factor range.
|
|
79
|
-
**/
|
|
80
|
-
interface GetCreditAccountsOptions {
|
|
81
|
-
/**
|
|
82
|
-
* If set, only return accounts from this credit manager; otherwise query all attached markets.
|
|
83
|
-
**/
|
|
84
|
-
creditManager?: Address;
|
|
85
|
-
/**
|
|
86
|
-
* If set, only return accounts owned by this address.
|
|
87
|
-
**/
|
|
88
|
-
owner?: Address;
|
|
89
|
-
/**
|
|
90
|
-
* Whether to include accounts with zero outstanding debt.
|
|
91
|
-
* @default false
|
|
92
|
-
**/
|
|
93
|
-
includeZeroDebt?: boolean;
|
|
94
|
-
/**
|
|
95
|
-
* Minimum health factor threshold (inclusive).
|
|
96
|
-
* 18 digits precision (10^18 = 1)
|
|
97
|
-
* @default 0n
|
|
98
|
-
**/
|
|
99
|
-
minHealthFactor?: bigint;
|
|
100
|
-
/**
|
|
101
|
-
* Maximum health factor threshold (inclusive).
|
|
102
|
-
* 18 digits precision (10^18 = 1)
|
|
103
|
-
* @default MAX_UINT256
|
|
104
|
-
**/
|
|
105
|
-
maxHealthFactor?: bigint;
|
|
106
|
-
/**
|
|
107
|
-
* If true, exclude reserve price feed updates from the query.
|
|
108
|
-
**/
|
|
109
|
-
ignoreReservePrices?: boolean;
|
|
110
|
-
}
|
|
111
|
-
/**
|
|
112
|
-
* Props for {@link ICreditAccountsService.listPositions}.
|
|
113
|
-
**/
|
|
114
|
-
interface ListStrategyPositionsProps {
|
|
115
|
-
/**
|
|
116
|
-
* Wallet whose credit accounts to describe. RWA accounts are resolved from
|
|
117
|
-
* the investor EOA, see {@link ICreditAccountsService.getBorrowerCreditAccounts}.
|
|
118
|
-
**/
|
|
119
|
-
owner: Address;
|
|
120
|
-
/**
|
|
121
|
-
* Whether to include accounts that carry no debt.
|
|
122
|
-
**/
|
|
123
|
-
includeZeroDebt: boolean;
|
|
124
|
-
}
|
|
125
|
-
/**
|
|
126
|
-
* Lightweight slice of credit-account data containing only token
|
|
127
|
-
* balances and the enabled-tokens bitmask.
|
|
128
|
-
**/
|
|
129
|
-
type CreditAccountTokensSlice = Pick<CreditAccountData, "creditManager" | "creditAccount" | "tokens" | "enabledTokensMask">;
|
|
130
23
|
/**
|
|
131
24
|
* Result of closing or liquidating a credit account, including the router's optimal close path.
|
|
132
25
|
**/
|
|
@@ -918,4 +811,4 @@ interface ICreditAccountsService extends Construct {
|
|
|
918
811
|
claimFarmRewards(props: ClaimFarmRewardsProps): Promise<RawTx>;
|
|
919
812
|
}
|
|
920
813
|
//#endregion
|
|
921
|
-
export { AccountToCheck, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, ClaimFarmRewardsProps, CloseCreditAccountResult,
|
|
814
|
+
export { AccountToCheck, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, ClaimFarmRewardsProps, CloseCreditAccountResult, CreditAccountOperationResult, CreditManagerOperationResult, EncodableCreditAccountOperation, FullyLiquidateProps, FullyLiquidateResult, GetApprovalAddressProps, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, ICreditAccountsService, OpenCAProps, PartiallyLiquidateProps, PermitResult, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, Rewards, SetBotProps };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { AdapterData, AssertAssignable, Asset, BaseParams, BaseState, ConnectedBotData, CreditAccountData, CreditAccountDataPayload, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, GaugeData, IBaseContract, MarketData, MarketFilter, ParsedCall, ParsedCallArgs, ParsedCallV2, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RateKeeperState, RelaxedBaseParams, RewardInfo, TokenInfo, Unarray, VotingContractStatus } from "./types.js";
|
|
1
|
+
import { AdapterData, AssertAssignable, Asset, BaseParams, BaseState, ConnectedBotData, CreditAccountData, CreditAccountDataPayload, CreditAccountTokensSlice, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, GaugeData, IBaseContract, MarketData, MarketFilter, ParsedCall, ParsedCallArgs, ParsedCallV2, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RateKeeperState, RelaxedBaseParams, RewardInfo, TokenInfo, Unarray, VotingContractStatus } from "./types.js";
|
|
2
2
|
import { LPMonopolizedPoolMeta, PHANTOM_TOKEN_CONTRACT_TYPES, PhantomTokenContractType, PhantomTokenMeta, RWADefaultTokenMeta, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWATokenMeta, RWAUnderlyingContractType, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, SimpleTokenMeta, TokenMetaData } from "./token-types.js";
|
|
3
3
|
import { FormatBNOptions, TokensMeta } from "./TokensMeta.js";
|
|
4
4
|
import { ChainContractsRegister, ContractOrInterface } from "./ChainContractsRegister.js";
|
|
@@ -8,4 +8,4 @@ import { MissingSerializedParamsError } from "./errors.js";
|
|
|
8
8
|
import { ChainQueryProps, MultichainConstruct } from "./MultichainConstruct.js";
|
|
9
9
|
import { PlaceholderContract } from "./PlaceholderContract.js";
|
|
10
10
|
import { SDKConstruct } from "./SDKConstruct.js";
|
|
11
|
-
export { AdapterData, AssertAssignable, Asset, BaseContract, BaseContractArgs, BaseParams, BaseState, ChainContractsRegister, ChainQueryProps, ConnectedBotData, Construct, ConstructOptions, ContractOrInterface, ContractParseError, ContractParseErrorOptions, CreditAccountData, CreditAccountDataPayload, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, FormatBNOptions, GaugeData, IBaseContract, LPMonopolizedPoolMeta, MarketData, MarketFilter, MissingSerializedParamsError, MultichainConstruct, PHANTOM_TOKEN_CONTRACT_TYPES, ParsedCall, ParsedCallArgs, ParsedCallV2, PhantomTokenContractType, PhantomTokenMeta, PlaceholderContract, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RWADefaultTokenMeta, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWATokenMeta, RWAUnderlyingContractType, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RateKeeperState, RelaxedBaseParams, RewardInfo, SDKConstruct, SimpleTokenMeta, TokenInfo, TokenMetaData, TokensMeta, Unarray, VotingContractStatus };
|
|
11
|
+
export { AdapterData, AssertAssignable, Asset, BaseContract, BaseContractArgs, BaseParams, BaseState, ChainContractsRegister, ChainQueryProps, ConnectedBotData, Construct, ConstructOptions, ContractOrInterface, ContractParseError, ContractParseErrorOptions, CreditAccountData, CreditAccountDataPayload, CreditAccountTokensSlice, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, FormatBNOptions, GaugeData, IBaseContract, LPMonopolizedPoolMeta, MarketData, MarketFilter, MissingSerializedParamsError, MultichainConstruct, PHANTOM_TOKEN_CONTRACT_TYPES, ParsedCall, ParsedCallArgs, ParsedCallV2, PhantomTokenContractType, PhantomTokenMeta, PlaceholderContract, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RWADefaultTokenMeta, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWATokenMeta, RWAUnderlyingContractType, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RateKeeperState, RelaxedBaseParams, RewardInfo, SDKConstruct, SimpleTokenMeta, TokenInfo, TokenMetaData, TokensMeta, Unarray, VotingContractStatus };
|
|
@@ -210,6 +210,11 @@ type CreditAccountData<WithInvestor extends boolean = false> = WithInvestor exte
|
|
|
210
210
|
**/
|
|
211
211
|
investor: Address | undefined;
|
|
212
212
|
} : CreditAccountDataPayload;
|
|
213
|
+
/**
|
|
214
|
+
* Lightweight slice of credit-account data: everything needed to tell which
|
|
215
|
+
* tokens of an account have to be priced.
|
|
216
|
+
**/
|
|
217
|
+
type CreditAccountTokensSlice = Pick<CreditAccountDataPayload, "creditManager" | "creditAccount" | "underlying" | "tokens" | "enabledTokensMask">;
|
|
213
218
|
/**
|
|
214
219
|
* Reward distribution details for a single reward token.
|
|
215
220
|
**/
|
|
@@ -440,4 +445,4 @@ interface IBaseContract {
|
|
|
440
445
|
parseFunctionDataV2: (calldata: Hex, strict?: boolean) => ParsedCallV2;
|
|
441
446
|
}
|
|
442
447
|
//#endregion
|
|
443
|
-
export { AdapterData, AssertAssignable, Asset, BaseParams, BaseState, ConnectedBotData, CreditAccountData, CreditAccountDataPayload, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, GaugeData, IBaseContract, MarketData, MarketFilter, ParsedCall, ParsedCallArgs, ParsedCallV2, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RateKeeperState, RelaxedBaseParams, RewardInfo, TokenInfo, Unarray, VotingContractStatus };
|
|
448
|
+
export { AdapterData, AssertAssignable, Asset, BaseParams, BaseState, ConnectedBotData, CreditAccountData, CreditAccountDataPayload, CreditAccountTokensSlice, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, GaugeData, IBaseContract, MarketData, MarketFilter, ParsedCall, ParsedCallArgs, ParsedCallV2, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RateKeeperState, RelaxedBaseParams, RewardInfo, TokenInfo, Unarray, VotingContractStatus };
|
|
@@ -7,7 +7,7 @@ import "./chain/index.js";
|
|
|
7
7
|
import { SimulateCallOptions, SimulateCallParameters, SimulateCallReturnType, SimulationError, SimulationErrorType, simulateCall } from "./utils/viem/simulateCall.js";
|
|
8
8
|
import { AddressMap } from "./utils/AddressMap.js";
|
|
9
9
|
import { AddressSet } from "./utils/AddressSet.js";
|
|
10
|
-
import { AdapterData, AssertAssignable, Asset, BaseParams, BaseState, ConnectedBotData, CreditAccountData, CreditAccountDataPayload, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, GaugeData, IBaseContract, MarketData, MarketFilter, ParsedCall, ParsedCallArgs, ParsedCallV2, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RateKeeperState, RelaxedBaseParams, RewardInfo, TokenInfo, Unarray, VotingContractStatus } from "./base/types.js";
|
|
10
|
+
import { AdapterData, AssertAssignable, Asset, BaseParams, BaseState, ConnectedBotData, CreditAccountData, CreditAccountDataPayload, CreditAccountTokensSlice, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, GaugeData, IBaseContract, MarketData, MarketFilter, ParsedCall, ParsedCallArgs, ParsedCallV2, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RateKeeperState, RelaxedBaseParams, RewardInfo, TokenInfo, Unarray, VotingContractStatus } from "./base/types.js";
|
|
11
11
|
import { AssetsMap } from "./utils/AssetsMap.js";
|
|
12
12
|
import { functionArgsToMap, functionArgsToRecord, getFunctionSignature } from "./utils/abi-decode.js";
|
|
13
13
|
import { BigIntMath } from "./utils/bigint-math.js";
|
|
@@ -50,6 +50,9 @@ import { createRouter } from "./router/createRouter.js";
|
|
|
50
50
|
import { assetsMap } from "./router/helpers.js";
|
|
51
51
|
import { RouterV310Contract } from "./router/RouterV310Contract.js";
|
|
52
52
|
import "./router/index.js";
|
|
53
|
+
import { CreditAccountDataCall, CreditAccountFilter, CreditAccountReadOptions, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsTarget, CreditManagerFilter, GetCreditAccountsArgs, GetCreditAccountsOptions, ListStrategyPositionsProps } from "./accounts/credit-account-compressor/types.js";
|
|
54
|
+
import { CreditAccountCompressor } from "./accounts/credit-account-compressor/CreditAccountCompressor.js";
|
|
55
|
+
import { CreditAccountCompressorV310Contract } from "./accounts/credit-account-compressor/CreditAccountCompressorV310Contract.js";
|
|
53
56
|
import { AbstractWithdrawalCompressorContract, OnchainRequestableWithdrawal, iCreditAccountAbi, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal } from "./accounts/withdrawal-compressor/AbstractWithdrawalCompressorContract.js";
|
|
54
57
|
import { WithdrawalCompressorLocation, WithdrawalCompressorVersion, getWithdrawalCompressorAddress } from "./accounts/withdrawal-compressor/addresses.js";
|
|
55
58
|
import { createRedemptionLogger } from "./accounts/withdrawal-compressor/createRedemptionLogger.js";
|
|
@@ -60,7 +63,7 @@ import { RedemptionLoggerV310Contract } from "./accounts/withdrawal-compressor/R
|
|
|
60
63
|
import { WithdrawalCompressorV310Contract } from "./accounts/withdrawal-compressor/WithdrawalCompressorV310Contract.js";
|
|
61
64
|
import { WithdrawalCompressorV311Contract } from "./accounts/withdrawal-compressor/WithdrawalCompressorV311Contract.js";
|
|
62
65
|
import { WithdrawalCompressorV313Contract } from "./accounts/withdrawal-compressor/WithdrawalCompressorV313Contract.js";
|
|
63
|
-
import { AccountToCheck, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, ClaimFarmRewardsProps, CloseCreditAccountResult,
|
|
66
|
+
import { AccountToCheck, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, ClaimFarmRewardsProps, CloseCreditAccountResult, CreditAccountOperationResult, CreditManagerOperationResult, EncodableCreditAccountOperation, FullyLiquidateProps, FullyLiquidateResult, GetApprovalAddressProps, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, ICreditAccountsService, OpenCAProps, PartiallyLiquidateProps, PermitResult, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, Rewards, SetBotProps } from "./accounts/types.js";
|
|
64
67
|
import { AddressProviderV3StateHuman, AliasLossPolicyStateHuman, AssetPriceFeedStateHuman, BalancerWeightedPriceFeedStateHuman, BaseContractStateHuman, BasePriceFeedStateHuman, BotListStateHuman, BoundedOracleStateHuman, ConstantOracleStateHuman, CoreStateHuman, CreditConfiguratorStateHuman, CreditFacadeStateHuman, CreditManagerDebtParamsHuman, CreditManagerStateHuman, CreditSuiteStateHuman, GaugeParamsHuman, GaugeStateHuman, GearStakingV3StateHuman, GearboxStateHuman, InterestRateModelStateHuman, LPPriceFeedStateHuman, LinearInterestRateModelStateHuman, LossPolicyStateHuman, MarketStateHuman, MultichainStateHuman, PoolQuotaKeeperStateHuman, PoolStateHuman, PoolSuiteStateHuman, PriceFeedStateHuman, PriceOracleStateHuman, QuotaParamsHuman, RateKeeperStateHuman, RedstonePriceFeedStateHuman, TumblerStateHuman, ZapperStateHuman } from "./types/state-human.js";
|
|
65
68
|
import { IPriceFeedContract, IUpdatablePriceFeedContract, PriceFeedContractType, PriceFeedUsageType, PriceUpdate, UpdatePriceFeedsResult } from "./market/pricefeeds/types.js";
|
|
66
69
|
import { PriceFeedRef } from "./market/pricefeeds/PriceFeedRef.js";
|
|
@@ -93,7 +96,7 @@ import { CreditConfiguratorV310Contract, RampEvent } from "./market/credit/Credi
|
|
|
93
96
|
import { CreditFacadeV310Abi as abi, CreditFacadeV310BaseContract } from "./market/credit/CreditFacadeV310BaseContract.js";
|
|
94
97
|
import { CreditFacadeV310Contract } from "./market/credit/CreditFacadeV310Contract.js";
|
|
95
98
|
import { CreditManagerV310Contract } from "./market/credit/CreditManagerV310Contract.js";
|
|
96
|
-
import { IPriceOracleContract,
|
|
99
|
+
import { IPriceOracleContract, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions } from "./market/oracle/types.js";
|
|
97
100
|
import { createPriceOracle } from "./market/oracle/createPriceOracle.js";
|
|
98
101
|
import { PriceOracleV310Contract } from "./market/oracle/PriceOracleV310Contract.js";
|
|
99
102
|
import { IInterestRateModelContract, IPoolContract, IRateKeeperContract, InterestRateModelType, PoolQuotaKeeperContract, RateKeeperType } from "./market/pool/types.js";
|
|
@@ -155,7 +158,7 @@ import { ChainQueryProps, MultichainConstruct } from "./base/MultichainConstruct
|
|
|
155
158
|
import { PlaceholderContract } from "./base/PlaceholderContract.js";
|
|
156
159
|
import { SDKConstruct } from "./base/SDKConstruct.js";
|
|
157
160
|
import "./base/index.js";
|
|
158
|
-
import {
|
|
161
|
+
import { CreditAccountsServiceV310 } from "./accounts/CreditAccountsServiceV310.js";
|
|
159
162
|
import { CreditAccountSlice, IntentPreviewResult } from "./accounts/intents/types.js";
|
|
160
163
|
import { primaryInstantOutput } from "./accounts/intents/operations/claim-delayed/index.js";
|
|
161
164
|
import { CreditAccountOperationsService } from "./accounts/intents/index.js";
|
|
@@ -165,4 +168,4 @@ import { LiquidationsService } from "./accounts/liquidations/LiquidationsService
|
|
|
165
168
|
import { MultichainLiquidationsService } from "./accounts/liquidations/MultichainLiquidationsService.js";
|
|
166
169
|
import "./accounts/index.js";
|
|
167
170
|
import { SDKOptions, attachOptionsSchema, onchainSDKOptionsSchema } from "./options.js";
|
|
168
|
-
export { ADDRESS_0X0, ADDRESS_PROVIDER_V310, AP_ACCOUNT_FACTORY, AP_ACL, AP_BOT_LIST, AP_BYTECODE_REPOSITORY, AP_CONTRACTS_REGISTER, AP_CONTROLLER_TIMELOCK, AP_CREDIT_ACCOUNT_COMPRESSOR, AP_CREDIT_SUITE_COMPRESSOR, AP_DATA_COMPRESSOR, AP_DELEVERAGE_BOT_HV, AP_DELEVERAGE_BOT_LV, AP_DELEVERAGE_BOT_PEGGED, AP_GAUGE_COMPRESSOR, AP_GEAR_STAKING, AP_GEAR_TOKEN, AP_INFLATION_ATTACK_BLOCKER, AP_INSOLVENCY_CHECKER, AP_MARKET_COMPRESSOR, AP_MARKET_CONFIGURATOR, AP_PARTIAL_LIQUIDATION_BOT, AP_PERIPHERY_COMPRESSOR, AP_PRICE_FEED_COMPRESSOR, AP_PRICE_FEED_STORE, AP_PRICE_ORACLE, AP_REDEMPTION_LOGGER, AP_REWARDS_COMPRESSOR, AP_ROUTER, AP_RWA_COMPRESSOR, AP_TOKEN_COMPRESSOR, AP_TREASURY, AP_WETH_GATEWAY, AP_WETH_TOKEN, AP_ZAPPER_REGISTER, AP_ZERO_PRICE_FEED, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AbstractWithdrawalCompressorContract, AccountToCheck, AdapterData, AddLiquidityProps, AddressMap, AddressProviderAddresses, AddressProviderState, AddressProviderV310Contract, type AddressProviderV3StateHuman, AddressSet, type AliasLossPolicyStateHuman, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, AssertAssignable, Asset, type AssetPriceFeedStateHuman, AssetsMap, AttachOptions, BLOCKS_PER_WEEK_BY_NETWORK, BalanceDelta, BalancerStablePriceFeedContract, BalancerWeightedPriceFeedContract, type BalancerWeightedPriceFeedStateHuman, BaseContract, BaseContractArgs, type BaseContractStateHuman, BaseParams, BasePlugin, type BasePriceFeedStateHuman, BaseState, BigIntMath, type BotListStateHuman, BotPermissions, type BoundedOracleStateHuman, BoundedPriceFeedContract, BuildLiquidationTxProps, BuildLiquidationTxPropsBase, ChainConfig, ChainContractsRegister, ChainNotConfiguredError, ChainQueryProps, ClaimFarmRewardsProps, ClaimableWithdrawal, ClientOptions, CloseCreditAccountResult, ClosePathBalances, CompositePriceFeedContract, ConnectedBotData, type ConstantOracleStateHuman, Construct, ConstructOptions, type ContractMethod, ContractOrInterface, ContractParseError, ContractParseErrorOptions, type CoreStateHuman, CreditAccountData, CreditAccountDataPayload, CreditAccountFilter, CreditAccountOperationResult, CreditAccountOperationsService, CreditAccountServiceOptions, type CreditAccountSlice, CreditAccountTokenQuota, CreditAccountTokensSlice, CreditAccountsServiceV310, CreditConfiguratorState, type CreditConfiguratorStateHuman, CreditConfiguratorV310Contract, CreditFacadeState, type CreditFacadeStateHuman, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerDebtParams, type CreditManagerDebtParamsHuman, CreditManagerFilter, CreditManagerOperationResult, CreditManagerState, type CreditManagerStateHuman, CreditManagerV310Contract, CreditSuite, CreditSuiteState, type CreditSuiteStateHuman, Curator, CurrentWithdrawals, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DStokenData, DUST_THRESHOLD, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, DelegatedMulticall, DepositMetadata, EncodableCreditAccountOperation, Erc4626PriceFeedContract, EstimateRawTxGasParameters, EtherscanURLParam, ExternalPriceFeedContract, type FetchPythPayloadsOptions, type FetchRedstonePayloadsOptions, FilterDustUSDOptions, FindBestClosePathProps, FindClaimAllRewardsProps, FindManyToOnePathProps, FindOneTokenPathProps, FindOpenStrategyPathProps, FormatBNOptions, FullyLiquidateProps, FullyLiquidateResult, GaugeContract, GaugeData, GaugeParams, type GaugeParamsHuman, type GaugeStateHuman, type GearStakingV3StateHuman, GearboxChain, type GearboxState, type GearboxStateHuman, GetApprovalAddressProps, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetCreditAccountsArgs, GetCreditAccountsOptions, GetLiquidatableAccountsProps, GetLiquidatableAccountsPropsBase, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, GetWithdrawalRequestResultProps, HydrateOptions, IAdapterContract, IAddressProviderContract, IBaseContract, ICreditAccountsService, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, type ILogger, IOnchainSDKPlugin, IOnchainSDKPluginConstructor, IPluginState, IPoolContract, IPoolsService, IPriceFeedContract, IPriceOracleContract, type IPriceUpdateTx, IRWAFactory, IRateKeeperContract, IRedemptionLoggerContract, IRouterContract, IUpdatablePriceFeedContract, IWithdrawalCompressorContract, IZapperContract, type IntentPreviewResult, type InterestRateModelStateHuman, InterestRateModelType, InvalidDelayedIntentError, IsDustOptions, LEVERAGE_DECIMALS, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LPMonopolizedPoolMeta, type LPPriceFeedStateHuman, LatestUpdate, LinearInterestRateModelContract, type LinearInterestRateModelStateHuman, LiquidationFees, LiquidationsService, ListPoolPositionsProps, ListPositionsProps, ListStrategyPositionsProps, LoadRWALiquidatorsProps, type LogFn, type LossPolicyStateHuman, MAX_INT, MAX_UINT16, MAX_UINT256, MIN_INT96, MULTICALL_ADDRESS, MarketData, MarketFilter, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, type MarketStateHuman, MarketSuite, MarketType, MellowLRTPriceFeedContract, Methods, MidasLiquidatorContract, MissingSerializedParamsError, type MultiCall, MultichainAttachOptions, MultichainConstruct, MultichainHydrateOptions, MultichainLiquidationsService, type MultichainNetworkMeta, type MultichainNetworkProps, type MultichainNetworksProps, MultichainOpportunitiesService, MultichainPositionsService, type MultichainResult, MultichainSDK, MultichainSDKOptions, type MultichainState, type MultichainStateHuman, MultichainSyncStateOptions, NATIVE_ADDRESS, NOT_DEPLOYED, NO_VERSION, NetworkType, OnDemandPriceUpdates, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, OnchainRequestableWithdrawal, OnchainSDK, OnchainSDKOptions, OpenCAProps, OpenStrategyResult, OpportunitiesService, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, PERCENTAGE_DECIMALS, PERCENTAGE_FACTOR, PERCENTAGE_FACTOR_1KK, PERIPHERY_CONTRACTS, PHANTOM_TOKEN_CONTRACT_TYPES, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, PRICE_DECIMALS, PRICE_DECIMALS_POW, ParsedCall, ParsedCallArgs, ParsedCallV2, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem, PartialLiquidationParams, PartialPriceFeedInitError, PartialPriceFeedTreeNode, PartialRecord, PartiallyLiquidateProps, PendingWithdrawal, PendleTWAPPTPriceFeed, PeripheryContract, PermitResult, PhantomTokenContractType, PhantomTokenMeta, PickSomeRequired, PlaceholderAdapterContract, PlaceholderAdapterContractOptions, PlaceholderContract, PluginFactoriesMap, PluginFactory, PluginState, PluginStateVersionError, PluginStatesMap, PluginsMap, PoolQuotaKeeperContract, type PoolQuotaKeeperStateHuman, PoolService, PoolServiceCall, PoolServiceCallResult, PoolState, type PoolStateHuman, PoolSuite, type PoolSuiteStateHuman, PoolV310Contract, PositionsService, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, PriceFeedAnswer, PriceFeedConstructorArgs, PriceFeedContractType, PriceFeedMapEntry, PriceFeedRef, PriceFeedRegister, PriceFeedRegisterHooks, PriceFeedRegisterOptions, type PriceFeedStateHuman, PriceFeedTreeNode, PriceFeedUsageType, PriceFeedsForTokensOptions, PriceOracleData, type PriceOracleStateHuman, PriceOracleV310Contract, PriceUpdate, PythPriceFeed, QuotaKeeperState, type QuotaParamsHuman, QuotaState, RAMP_DURATION_BY_NETWORK, RAY, RAY_DECIMALS_POW, RWACompressorCall, RWACompressorInvestorData, RWACompressorResponse, RWADefaultTokenMeta, RWAFactoryData, RWAFactoryStateHuman, RWAFactoryType, RWAInvestorData, RWALiquidatorInfo, RWAMissingOpenAccountRequirements, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWAOpenAccountRequirements, RWAOperationArgs, RWARegistry, RWAState, RWAStateHuman, RWATokenMeta, RWAUnderlyingContractType, RWAUnderlyingData, RWA_FACTORY_SECURITIZE, RWA_FACTORY_TYPES, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RampEvent, RateKeeperState, type RateKeeperStateHuman, RateKeeperType, type RawTx, RedemptionLog, RedemptionLoggerV310Contract, RedstonePriceFeedContract, type RedstonePriceFeedStateHuman, RelaxedBaseParams, RemoveLiquidityProps, RequestableWithdrawal, RetryOptions, RewardInfo, Rewards, RouterCASlice, RouterCMSlice, RouterCloseResult, RouterResult, RouterRewardsResult, RouterV310Contract, SDKConstruct, SDKOptions, SECONDS_PER_YEAR, SECURITIZE_REGISTER_VAULT_TYPES, SLIPPAGE_DECIMALS, STATE_VERSION, SUPPORTED_NETWORKS, SdkAlreadyAttachedError, SdkChainMismatchError, SdkMissingChainStateError, SdkNotAttachedError, SdkStateVersionMismatchError, SdkSyncFailedError, SecuritizeCreditAccountData, SecuritizeInvestorData, SecuritizeLiquidatorContract, SecuritizeMissingOpenAccountRequirements, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, SendRawTxParameters, SetBotProps, SimpleTokenMeta, SimulateCallOptions, SimulateCallParameters, SimulateCallReturnType, SimulateMulticallParameters, SimulateMulticallReturnType, SimulateWithPriceUpdatesError, SimulateWithPriceUpdatesErrorParams, SimulateWithPriceUpdatesErrorType, SimulateWithPriceUpdatesParameters, SimulateWithPriceUpdatesReturnType, SimulationError, SimulationErrorType, StrategyRef, SunsetStrategy, SupportedValue, SwapOperation, SyncStateOptions, type TimestampedCalldata, TokenInfo, TokenMetaData, TokensMeta, type TumblerStateHuman, TypedObjectUtils, Unarray, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, VERSION_RANGE_310, VersionRange, VotingContractStatus, WAD, WAD_DECIMALS_POW, WatchBlocksAsyncParameters, WatchBlocksAsyncReturnType, type WithMultichain, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalMetadata, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, WstETHPriceFeedContract, YearnPriceFeedContract, ZapperContract, ZapperData, type ZapperStateHuman, ZeroPriceFeedContract, ZodAddress, ZodHex, additionalBorrowApyBps, assetsMap, attachOptionsSchema, borrowApyBps, botPermissionsToString, bytes32ToString, chains, childLogger, createAdapter, createAddressProvider, createPriceOracle, createRawTx, createRedemptionLogger, createRouter, createWithdrawalCompressor, createZapper, decodeDelayedIntent, detectNetwork, dominantCollateral, encodeDelayedIntent, estimateRawTxGas, etherscanApiUrl, etherscanUrl, executeDelegatedMulticalls, fetchPythPayloads, fetchRedstonePayloads, filterDust, filterDustUSD, findCuratorMarketConfigurator, fmtBinaryMask, formatBN, formatBNvalue, formatDuration, formatLeverage, formatNumberToString_, formatPercentage, formatTimestamp, functionArgsToMap, functionArgsToRecord, generateCastTraceCall, getAssetType, getCastTraceArgs, getChain, getCuratorName, getFunctionSignature, getNetworkType, getRawPriceUpdates, getSimulateWithPriceUpdatesError, getWithdrawalCompressorAddress, halfRAY, healthFactorBps, hexEq, hydrateAddressProvider, iCreditAccountAbi, isDust, isLPPriceFeed, isPublicNetwork, isRWAFactory, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, isUpdatablePriceFeed, isV310, isVersionRange, json_parse, json_stringify, maxLeverage, minSeizedAmount, mustGetDominantCollateral, numberWithCommas, onchainSDKOptionsSchema, optimalHFForPartialLiquidation, optimalRepaidAmount, percentFmt, positionLeverage, primaryInstantOutput, rayToBps, rayToNumber, retry, sendRawTx, shortAddress, shortHash, simulateCall, simulateMulticall, simulateWithPriceUpdates, toAddress, toBN, toBigInt, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal, toSignificant, toWithdrawalStatus, usdToNumber, utilizationBps, watchBlocksAsync };
|
|
171
|
+
export { ADDRESS_0X0, ADDRESS_PROVIDER_V310, AP_ACCOUNT_FACTORY, AP_ACL, AP_BOT_LIST, AP_BYTECODE_REPOSITORY, AP_CONTRACTS_REGISTER, AP_CONTROLLER_TIMELOCK, AP_CREDIT_ACCOUNT_COMPRESSOR, AP_CREDIT_SUITE_COMPRESSOR, AP_DATA_COMPRESSOR, AP_DELEVERAGE_BOT_HV, AP_DELEVERAGE_BOT_LV, AP_DELEVERAGE_BOT_PEGGED, AP_GAUGE_COMPRESSOR, AP_GEAR_STAKING, AP_GEAR_TOKEN, AP_INFLATION_ATTACK_BLOCKER, AP_INSOLVENCY_CHECKER, AP_MARKET_COMPRESSOR, AP_MARKET_CONFIGURATOR, AP_PARTIAL_LIQUIDATION_BOT, AP_PERIPHERY_COMPRESSOR, AP_PRICE_FEED_COMPRESSOR, AP_PRICE_FEED_STORE, AP_PRICE_ORACLE, AP_REDEMPTION_LOGGER, AP_REWARDS_COMPRESSOR, AP_ROUTER, AP_RWA_COMPRESSOR, AP_TOKEN_COMPRESSOR, AP_TREASURY, AP_WETH_GATEWAY, AP_WETH_TOKEN, AP_ZAPPER_REGISTER, AP_ZERO_PRICE_FEED, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AbstractWithdrawalCompressorContract, AccountToCheck, AdapterData, AddLiquidityProps, AddressMap, AddressProviderAddresses, AddressProviderState, AddressProviderV310Contract, type AddressProviderV3StateHuman, AddressSet, type AliasLossPolicyStateHuman, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, AssertAssignable, Asset, type AssetPriceFeedStateHuman, AssetsMap, AttachOptions, BLOCKS_PER_WEEK_BY_NETWORK, BalanceDelta, BalancerStablePriceFeedContract, BalancerWeightedPriceFeedContract, type BalancerWeightedPriceFeedStateHuman, BaseContract, BaseContractArgs, type BaseContractStateHuman, BaseParams, BasePlugin, type BasePriceFeedStateHuman, BaseState, BigIntMath, type BotListStateHuman, BotPermissions, type BoundedOracleStateHuman, BoundedPriceFeedContract, BuildLiquidationTxProps, BuildLiquidationTxPropsBase, ChainConfig, ChainContractsRegister, ChainNotConfiguredError, ChainQueryProps, ClaimFarmRewardsProps, ClaimableWithdrawal, ClientOptions, CloseCreditAccountResult, ClosePathBalances, CompositePriceFeedContract, ConnectedBotData, type ConstantOracleStateHuman, Construct, ConstructOptions, type ContractMethod, ContractOrInterface, ContractParseError, ContractParseErrorOptions, type CoreStateHuman, CreditAccountCompressor, CreditAccountCompressorV310Contract, CreditAccountData, CreditAccountDataCall, CreditAccountDataPayload, CreditAccountFilter, CreditAccountOperationResult, CreditAccountOperationsService, CreditAccountReadOptions, type CreditAccountSlice, CreditAccountTokenQuota, CreditAccountTokensSlice, CreditAccountsCall, CreditAccountsQuery, CreditAccountsReadOptions, CreditAccountsServiceV310, CreditAccountsTarget, CreditConfiguratorState, type CreditConfiguratorStateHuman, CreditConfiguratorV310Contract, CreditFacadeState, type CreditFacadeStateHuman, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerDebtParams, type CreditManagerDebtParamsHuman, CreditManagerFilter, CreditManagerOperationResult, CreditManagerState, type CreditManagerStateHuman, CreditManagerV310Contract, CreditSuite, CreditSuiteState, type CreditSuiteStateHuman, Curator, CurrentWithdrawals, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DStokenData, DUST_THRESHOLD, DelayedAddCollateralIntent, DelayedCloseAccountIntent, DelayedDecreaseLeverageIntent, DelayedDepositAndIncreaseLeverageIntent, DelayedDepositIntent, DelayedIncreaseLeverageIntent, DelayedIntent, DelayedIntentExtended, DelayedWithdrawCollateralIntent, DelegatedMulticall, DepositMetadata, EncodableCreditAccountOperation, Erc4626PriceFeedContract, EstimateRawTxGasParameters, EtherscanURLParam, ExternalPriceFeedContract, type FetchPythPayloadsOptions, type FetchRedstonePayloadsOptions, FilterDustUSDOptions, FindBestClosePathProps, FindClaimAllRewardsProps, FindManyToOnePathProps, FindOneTokenPathProps, FindOpenStrategyPathProps, FormatBNOptions, FullyLiquidateProps, FullyLiquidateResult, GaugeContract, GaugeData, GaugeParams, type GaugeParamsHuman, type GaugeStateHuman, type GearStakingV3StateHuman, GearboxChain, type GearboxState, type GearboxStateHuman, GetApprovalAddressProps, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetCreditAccountsArgs, GetCreditAccountsOptions, GetLiquidatableAccountsProps, GetLiquidatableAccountsPropsBase, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, GetWithdrawalRequestResultProps, HydrateOptions, IAdapterContract, IAddressProviderContract, IBaseContract, ICreditAccountsService, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, type ILogger, IOnchainSDKPlugin, IOnchainSDKPluginConstructor, IPluginState, IPoolContract, IPoolsService, IPriceFeedContract, IPriceOracleContract, type IPriceUpdateTx, IRWAFactory, IRateKeeperContract, IRedemptionLoggerContract, IRouterContract, IUpdatablePriceFeedContract, IWithdrawalCompressorContract, IZapperContract, type IntentPreviewResult, type InterestRateModelStateHuman, InterestRateModelType, InvalidDelayedIntentError, IsDustOptions, LEVERAGE_DECIMALS, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LPMonopolizedPoolMeta, type LPPriceFeedStateHuman, LatestUpdate, LinearInterestRateModelContract, type LinearInterestRateModelStateHuman, LiquidationFees, LiquidationsService, ListPoolPositionsProps, ListPositionsProps, ListStrategyPositionsProps, LoadRWALiquidatorsProps, type LogFn, type LossPolicyStateHuman, MAX_INT, MAX_UINT16, MAX_UINT256, MIN_INT96, MULTICALL_ADDRESS, MarketData, MarketFilter, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, type MarketStateHuman, MarketSuite, MarketType, MellowLRTPriceFeedContract, Methods, MidasLiquidatorContract, MissingSerializedParamsError, type MultiCall, MultichainAttachOptions, MultichainConstruct, MultichainHydrateOptions, MultichainLiquidationsService, type MultichainNetworkMeta, type MultichainNetworkProps, type MultichainNetworksProps, MultichainOpportunitiesService, MultichainPositionsService, type MultichainResult, MultichainSDK, MultichainSDKOptions, type MultichainState, type MultichainStateHuman, MultichainSyncStateOptions, NATIVE_ADDRESS, NOT_DEPLOYED, NO_VERSION, NetworkType, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, OnchainRequestableWithdrawal, OnchainSDK, OnchainSDKOptions, OpenCAProps, OpenStrategyResult, OpportunitiesService, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, PERCENTAGE_DECIMALS, PERCENTAGE_FACTOR, PERCENTAGE_FACTOR_1KK, PERIPHERY_CONTRACTS, PHANTOM_TOKEN_CONTRACT_TYPES, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, PRICE_DECIMALS, PRICE_DECIMALS_POW, ParsedCall, ParsedCallArgs, ParsedCallV2, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem, PartialLiquidationParams, PartialPriceFeedInitError, PartialPriceFeedTreeNode, PartialRecord, PartiallyLiquidateProps, PendingWithdrawal, PendleTWAPPTPriceFeed, PeripheryContract, PermitResult, PhantomTokenContractType, PhantomTokenMeta, PickSomeRequired, PlaceholderAdapterContract, PlaceholderAdapterContractOptions, PlaceholderContract, PluginFactoriesMap, PluginFactory, PluginState, PluginStateVersionError, PluginStatesMap, PluginsMap, PoolQuotaKeeperContract, type PoolQuotaKeeperStateHuman, PoolService, PoolServiceCall, PoolServiceCallResult, PoolState, type PoolStateHuman, PoolSuite, type PoolSuiteStateHuman, PoolV310Contract, PositionsService, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, PriceFeedAnswer, PriceFeedConstructorArgs, PriceFeedContractType, PriceFeedMapEntry, PriceFeedRef, PriceFeedRegister, PriceFeedRegisterHooks, PriceFeedRegisterOptions, type PriceFeedStateHuman, PriceFeedTreeNode, PriceFeedUsageType, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions, PriceOracleData, type PriceOracleStateHuman, PriceOracleV310Contract, PriceUpdate, PythPriceFeed, QuotaKeeperState, type QuotaParamsHuman, QuotaState, RAMP_DURATION_BY_NETWORK, RAY, RAY_DECIMALS_POW, RWACompressorCall, RWACompressorInvestorData, RWACompressorResponse, RWADefaultTokenMeta, RWAFactoryData, RWAFactoryStateHuman, RWAFactoryType, RWAInvestorData, RWALiquidatorInfo, RWAMissingOpenAccountRequirements, RWAOnDemandLPMeta, RWAOnDemandLPMonopolizedMeta, RWAOnDemandLpContractType, RWAOnDemandTokenMeta, RWAOpenAccountRequirements, RWAOperationArgs, RWARegistry, RWAState, RWAStateHuman, RWATokenMeta, RWAUnderlyingContractType, RWAUnderlyingData, RWA_FACTORY_SECURITIZE, RWA_FACTORY_TYPES, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RWA_ON_DEMAND_LP_MONOPOLIZED, RWA_UNDERLYING_DEFAULT, RWA_UNDERLYING_ON_DEMAND, RampEvent, RateKeeperState, type RateKeeperStateHuman, RateKeeperType, type RawTx, RedemptionLog, RedemptionLoggerV310Contract, RedstonePriceFeedContract, type RedstonePriceFeedStateHuman, RelaxedBaseParams, RemoveLiquidityProps, RequestableWithdrawal, RetryOptions, RewardInfo, Rewards, RouterCASlice, RouterCMSlice, RouterCloseResult, RouterResult, RouterRewardsResult, RouterV310Contract, SDKConstruct, SDKOptions, SECONDS_PER_YEAR, SECURITIZE_REGISTER_VAULT_TYPES, SLIPPAGE_DECIMALS, STATE_VERSION, SUPPORTED_NETWORKS, SdkAlreadyAttachedError, SdkChainMismatchError, SdkMissingChainStateError, SdkNotAttachedError, SdkStateVersionMismatchError, SdkSyncFailedError, SecuritizeCreditAccountData, SecuritizeInvestorData, SecuritizeLiquidatorContract, SecuritizeMissingOpenAccountRequirements, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, SendRawTxParameters, SetBotProps, SimpleTokenMeta, SimulateCallOptions, SimulateCallParameters, SimulateCallReturnType, SimulateMulticallParameters, SimulateMulticallReturnType, SimulateWithPriceUpdatesError, SimulateWithPriceUpdatesErrorParams, SimulateWithPriceUpdatesErrorType, SimulateWithPriceUpdatesParameters, SimulateWithPriceUpdatesReturnType, SimulationError, SimulationErrorType, StrategyRef, SunsetStrategy, SupportedValue, SwapOperation, SyncStateOptions, type TimestampedCalldata, TokenInfo, TokenMetaData, TokensMeta, type TumblerStateHuman, TypedObjectUtils, Unarray, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, VERSION_RANGE_310, VersionRange, VotingContractStatus, WAD, WAD_DECIMALS_POW, WatchBlocksAsyncParameters, WatchBlocksAsyncReturnType, type WithMultichain, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalMetadata, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, WstETHPriceFeedContract, YearnPriceFeedContract, ZapperContract, ZapperData, type ZapperStateHuman, ZeroPriceFeedContract, ZodAddress, ZodHex, additionalBorrowApyBps, assetsMap, attachOptionsSchema, borrowApyBps, botPermissionsToString, bytes32ToString, chains, childLogger, createAdapter, createAddressProvider, createPriceOracle, createRawTx, createRedemptionLogger, createRouter, createWithdrawalCompressor, createZapper, decodeDelayedIntent, detectNetwork, dominantCollateral, encodeDelayedIntent, estimateRawTxGas, etherscanApiUrl, etherscanUrl, executeDelegatedMulticalls, fetchPythPayloads, fetchRedstonePayloads, filterDust, filterDustUSD, findCuratorMarketConfigurator, fmtBinaryMask, formatBN, formatBNvalue, formatDuration, formatLeverage, formatNumberToString_, formatPercentage, formatTimestamp, functionArgsToMap, functionArgsToRecord, generateCastTraceCall, getAssetType, getCastTraceArgs, getChain, getCuratorName, getFunctionSignature, getNetworkType, getRawPriceUpdates, getSimulateWithPriceUpdatesError, getWithdrawalCompressorAddress, halfRAY, healthFactorBps, hexEq, hydrateAddressProvider, iCreditAccountAbi, isDust, isLPPriceFeed, isPublicNetwork, isRWAFactory, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, isUpdatablePriceFeed, isV310, isVersionRange, json_parse, json_stringify, maxLeverage, minSeizedAmount, mustGetDominantCollateral, numberWithCommas, onchainSDKOptionsSchema, optimalHFForPartialLiquidation, optimalRepaidAmount, percentFmt, positionLeverage, primaryInstantOutput, rayToBps, rayToNumber, retry, sendRawTx, shortAddress, shortHash, simulateCall, simulateMulticall, simulateWithPriceUpdates, toAddress, toBN, toBigInt, toClaimableWithdrawal, toPendingWithdrawal, toRequestableWithdrawal, toSignificant, toWithdrawalStatus, usdToNumber, utilizationBps, watchBlocksAsync };
|
|
@@ -43,7 +43,7 @@ import { CreditConfiguratorV310Contract, RampEvent } from "./credit/CreditConfig
|
|
|
43
43
|
import { CreditFacadeV310Abi as abi, CreditFacadeV310BaseContract } from "./credit/CreditFacadeV310BaseContract.js";
|
|
44
44
|
import { CreditFacadeV310Contract } from "./credit/CreditFacadeV310Contract.js";
|
|
45
45
|
import { CreditManagerV310Contract } from "./credit/CreditManagerV310Contract.js";
|
|
46
|
-
import { IPriceOracleContract,
|
|
46
|
+
import { IPriceOracleContract, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions } from "./oracle/types.js";
|
|
47
47
|
import { createPriceOracle } from "./oracle/createPriceOracle.js";
|
|
48
48
|
import { PriceOracleV310Contract } from "./oracle/PriceOracleV310Contract.js";
|
|
49
49
|
import "./oracle/index.js";
|
|
@@ -66,4 +66,4 @@ import { IERC20ZapperContract } from "./zapper/IERC20ZapperContract.js";
|
|
|
66
66
|
import { IETHZapperContract } from "./zapper/IETHZapperContract.js";
|
|
67
67
|
import "./zapper/index.js";
|
|
68
68
|
import { MarketRegister, MarketRegistryState, MarketRegistryStateHuman } from "./MarketRegister.js";
|
|
69
|
-
export { AbstractLPPriceFeedContract, AbstractPriceFeedContract, BalanceDelta, BalancerStablePriceFeedContract, BalancerWeightedPriceFeedContract, BoundedPriceFeedContract, CompositePriceFeedContract, CreditAccountTokenQuota, CreditConfiguratorV310Contract, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, DStokenData, Erc4626PriceFeedContract, ExternalPriceFeedContract, type FetchPythPayloadsOptions, type FetchRedstonePayloadsOptions, GaugeContract, GaugeParams, IAdapterContract, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, IPoolContract, IPriceFeedContract, IPriceOracleContract, IRWAFactory, IRateKeeperContract, IUpdatablePriceFeedContract, IZapperContract, InterestRateModelType, LatestUpdate, LinearInterestRateModelContract, LiquidationFees, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, MarketSuite, MellowLRTPriceFeedContract, MidasLiquidatorContract,
|
|
69
|
+
export { AbstractLPPriceFeedContract, AbstractPriceFeedContract, BalanceDelta, BalancerStablePriceFeedContract, BalancerWeightedPriceFeedContract, BoundedPriceFeedContract, CompositePriceFeedContract, CreditAccountTokenQuota, CreditConfiguratorV310Contract, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, CurveCryptoPriceFeedContract, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, DStokenData, Erc4626PriceFeedContract, ExternalPriceFeedContract, type FetchPythPayloadsOptions, type FetchRedstonePayloadsOptions, GaugeContract, GaugeParams, IAdapterContract, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, IPoolContract, IPriceFeedContract, IPriceOracleContract, IRWAFactory, IRateKeeperContract, IUpdatablePriceFeedContract, IZapperContract, InterestRateModelType, LatestUpdate, LinearInterestRateModelContract, LiquidationFees, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, MarketSuite, MellowLRTPriceFeedContract, MidasLiquidatorContract, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem, PartialLiquidationParams, PartialPriceFeedInitError, PartialPriceFeedTreeNode, PendleTWAPPTPriceFeed, PlaceholderAdapterContract, PlaceholderAdapterContractOptions, PoolQuotaKeeperContract, PoolSuite, PoolV310Contract, PriceFeedConstructorArgs, PriceFeedContractType, PriceFeedRef, PriceFeedRegister, PriceFeedRegisterHooks, PriceFeedRegisterOptions, PriceFeedUsageType, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions, PriceOracleV310Contract, PriceUpdate, PythPriceFeed, RWACompressorCall, RWACompressorInvestorData, RWACompressorResponse, RWAFactoryData, RWAFactoryStateHuman, RWAFactoryType, RWAInvestorData, RWAMissingOpenAccountRequirements, RWAOpenAccountRequirements, RWAOperationArgs, RWARegistry, RWAState, RWAStateHuman, RWAUnderlyingData, RWA_FACTORY_SECURITIZE, RWA_FACTORY_TYPES, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RampEvent, RateKeeperType, RedstonePriceFeedContract, SECURITIZE_REGISTER_VAULT_TYPES, SecuritizeCreditAccountData, SecuritizeInvestorData, SecuritizeLiquidatorContract, SecuritizeMissingOpenAccountRequirements, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, StrategyRef, type TimestampedCalldata, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, WstETHPriceFeedContract, YearnPriceFeedContract, ZapperContract, ZapperData, ZeroPriceFeedContract, createAdapter, createPriceOracle, createZapper, dominantCollateral, fetchPythPayloads, fetchRedstonePayloads, getRawPriceUpdates, isLPPriceFeed, isRWAFactory, isUpdatablePriceFeed, mustGetDominantCollateral };
|
|
@@ -2,15 +2,15 @@ import { Amount, TokenAmount } from "../../../model/primitives.js";
|
|
|
2
2
|
import { PriceFeedData, PriceFeedSummary } from "../../../model/opportunities.js";
|
|
3
3
|
import "../../../model/index.js";
|
|
4
4
|
import { AddressMap } from "../../utils/AddressMap.js";
|
|
5
|
-
import { PriceOracleData } from "../../base/types.js";
|
|
5
|
+
import { CreditAccountTokensSlice, PriceOracleData } from "../../base/types.js";
|
|
6
6
|
import { DelegatedMulticall } from "../../utils/viem/executeDelegatedMulticalls.js";
|
|
7
7
|
import "../../utils/viem/index.js";
|
|
8
8
|
import { PriceOracleStateHuman } from "../../types/state-human.js";
|
|
9
|
-
import { IPriceFeedContract, UpdatePriceFeedsResult } from "../pricefeeds/types.js";
|
|
9
|
+
import { IPriceFeedContract, PriceUpdate, UpdatePriceFeedsResult } from "../pricefeeds/types.js";
|
|
10
10
|
import { PriceFeedRef } from "../pricefeeds/PriceFeedRef.js";
|
|
11
11
|
import "../pricefeeds/index.js";
|
|
12
12
|
import PriceFeedAnswerMap from "./PriceFeedAnswerMap.js";
|
|
13
|
-
import { IPriceOracleContract,
|
|
13
|
+
import { IPriceOracleContract, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions } from "./types.js";
|
|
14
14
|
import { OnchainSDK } from "../../OnchainSDK.js";
|
|
15
15
|
import "../../utils/index.js";
|
|
16
16
|
import "../../types/index.js";
|
|
@@ -51,7 +51,18 @@ declare abstract class PriceOracleBaseContract<abi extends Abi | readonly unknow
|
|
|
51
51
|
* {@inheritDoc IPriceOracleContract.priceFeedsForTokens}
|
|
52
52
|
**/
|
|
53
53
|
priceFeedsForTokens(tokens: Address[], opts?: PriceFeedsForTokensOptions): IPriceFeedContract[];
|
|
54
|
-
|
|
54
|
+
/**
|
|
55
|
+
* {@inheritDoc IPriceOracleContract.priceUpdateTxsForAccount}
|
|
56
|
+
**/
|
|
57
|
+
priceUpdateTxsForAccount(account: CreditAccountTokensSlice, opts?: PriceFeedsForAccountOptions): Promise<UpdatePriceFeedsResult>;
|
|
58
|
+
/**
|
|
59
|
+
* {@inheritDoc IPriceOracleContract.priceUpdatesForAccount}
|
|
60
|
+
**/
|
|
61
|
+
priceUpdatesForAccount(account: CreditAccountTokensSlice, opts?: PriceFeedsForAccountOptions): Promise<PriceUpdate[]>;
|
|
62
|
+
/**
|
|
63
|
+
* {@inheritDoc IPriceOracleContract.priceUpdatesForTokens}
|
|
64
|
+
**/
|
|
65
|
+
priceUpdatesForTokens(tokens: Address[], opts?: PriceFeedsForTokensOptions): Promise<PriceUpdate[]>;
|
|
55
66
|
/**
|
|
56
67
|
* {@inheritDoc IPriceOracleContract.mainPrice}
|
|
57
68
|
**/
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { PriceOracleData } from "../../base/types.js";
|
|
2
|
-
import { UpdatePriceFeedsResult } from "../pricefeeds/types.js";
|
|
3
|
-
import "../pricefeeds/index.js";
|
|
4
|
-
import { OnDemandPriceUpdates } from "./types.js";
|
|
5
2
|
import { PriceOracleBaseContract } from "./PriceOracleBaseContract.js";
|
|
6
3
|
import { OnchainSDK } from "../../OnchainSDK.js";
|
|
7
4
|
import "../../base/index.js";
|
|
@@ -345,14 +342,6 @@ declare const abi: readonly [{
|
|
|
345
342
|
type abi = typeof abi;
|
|
346
343
|
declare class PriceOracleV310Contract extends PriceOracleBaseContract<abi> {
|
|
347
344
|
constructor(sdk: OnchainSDK, data: PriceOracleData);
|
|
348
|
-
/**
|
|
349
|
-
* Converts previously obtained price updates into CreditFacade multicall entry
|
|
350
|
-
* @param creditFacade
|
|
351
|
-
* @param updates
|
|
352
|
-
* @returns
|
|
353
|
-
* @throws If `creditFacade` does not belong to a loaded market.
|
|
354
|
-
*/
|
|
355
|
-
onDemandPriceUpdates(creditFacade: Address, updates?: UpdatePriceFeedsResult): OnDemandPriceUpdates;
|
|
356
345
|
/**
|
|
357
346
|
* {@inheritDoc IPriceOracleContract.updateAndConvert}
|
|
358
347
|
**/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IPriceOracleContract,
|
|
1
|
+
import { IPriceOracleContract, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions } from "./types.js";
|
|
2
2
|
import { createPriceOracle } from "./createPriceOracle.js";
|
|
3
3
|
import { PriceOracleV310Contract } from "./PriceOracleV310Contract.js";
|
|
4
|
-
export { IPriceOracleContract,
|
|
4
|
+
export { IPriceOracleContract, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions, PriceOracleV310Contract, createPriceOracle };
|