@gearbox-protocol/sdk 15.1.0-next.19 → 15.1.0-next.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/dist/cjs/common-utils/charts/credit-session.js +1 -1
  2. package/dist/cjs/model/opportunities.js +4 -4
  3. package/dist/cjs/model/opportunities.schema.js +1 -2
  4. package/dist/cjs/new-sdk/prepare/PrepareApi.js +14 -10
  5. package/dist/cjs/offchain/opportunities/OffchainOpportunities.js +1 -1
  6. package/dist/cjs/plugins/accounts-counter/AccountsCounterPlugin.js +1 -1
  7. package/dist/cjs/sdk/OnchainSDK.js +2 -2
  8. package/dist/cjs/sdk/accounts/intents/testing/market.js +2 -1
  9. package/dist/cjs/sdk/accounts/intents/testing/sdk-mock.js +1 -0
  10. package/dist/cjs/sdk/accounts/intents/utils/pick-token.js +2 -2
  11. package/dist/cjs/sdk/accounts/intents/utils/quotas-for-update.js +1 -1
  12. package/dist/cjs/sdk/accounts/liquidations/LiquidationsService.js +2 -2
  13. package/dist/cjs/sdk/chain/chains.js +140 -51
  14. package/dist/cjs/sdk/chain/index.js +3 -0
  15. package/dist/cjs/sdk/constants/networks.js +1 -1
  16. package/dist/cjs/sdk/core/AbstractAddressProviderContract.js +1 -1
  17. package/dist/cjs/sdk/index.js +11 -7
  18. package/dist/cjs/sdk/market/MarketSuite.js +8 -39
  19. package/dist/cjs/sdk/market/credit/CreditSuite.js +61 -37
  20. package/dist/cjs/sdk/market/credit/{isStrategyCollateral.js → collateralUtils.js} +52 -5
  21. package/dist/cjs/sdk/market/credit/index.js +5 -6
  22. package/dist/cjs/sdk/market/index.js +7 -6
  23. package/dist/cjs/sdk/market/strategyName.js +19 -0
  24. package/dist/cjs/sdk/opportunities/OpportunitiesService.js +5 -3
  25. package/dist/cjs/sdk/positions/PositionsService.js +5 -10
  26. package/dist/cjs/sdk/utils/index.js +1 -1
  27. package/dist/esm/common-utils/charts/credit-session.js +1 -1
  28. package/dist/esm/model/opportunities.js +4 -4
  29. package/dist/esm/model/opportunities.schema.js +1 -2
  30. package/dist/esm/new-sdk/prepare/PrepareApi.js +14 -10
  31. package/dist/esm/offchain/opportunities/OffchainOpportunities.js +1 -1
  32. package/dist/esm/plugins/accounts-counter/AccountsCounterPlugin.js +1 -1
  33. package/dist/esm/sdk/OnchainSDK.js +2 -2
  34. package/dist/esm/sdk/accounts/intents/testing/market.js +2 -1
  35. package/dist/esm/sdk/accounts/intents/testing/sdk-mock.js +1 -0
  36. package/dist/esm/sdk/accounts/intents/utils/pick-token.js +1 -1
  37. package/dist/esm/sdk/accounts/intents/utils/quotas-for-update.js +1 -1
  38. package/dist/esm/sdk/accounts/liquidations/LiquidationsService.js +1 -1
  39. package/dist/esm/sdk/chain/chains.js +139 -53
  40. package/dist/esm/sdk/chain/index.js +2 -2
  41. package/dist/esm/sdk/constants/networks.js +1 -1
  42. package/dist/esm/sdk/core/AbstractAddressProviderContract.js +1 -1
  43. package/dist/esm/sdk/index.js +5 -5
  44. package/dist/esm/sdk/market/MarketSuite.js +8 -39
  45. package/dist/esm/sdk/market/credit/CreditSuite.js +62 -38
  46. package/dist/esm/sdk/market/credit/{isStrategyCollateral.js → collateralUtils.js} +51 -6
  47. package/dist/esm/sdk/market/credit/index.js +2 -3
  48. package/dist/esm/sdk/market/index.js +3 -3
  49. package/dist/esm/sdk/market/strategyName.js +18 -0
  50. package/dist/esm/sdk/opportunities/OpportunitiesService.js +5 -3
  51. package/dist/esm/sdk/positions/PositionsService.js +5 -10
  52. package/dist/esm/sdk/utils/index.js +1 -1
  53. package/dist/types/model/index.d.ts +1 -1
  54. package/dist/types/model/opportunities.d.ts +8 -15
  55. package/dist/types/model/opportunities.schema.d.ts +0 -2
  56. package/dist/types/model/positions.d.ts +2 -10
  57. package/dist/types/new-sdk/errors/SourceChainMismatchError.d.ts +1 -1
  58. package/dist/types/new-sdk/positions/mergePositionList.d.ts +3 -2
  59. package/dist/types/new-sdk/types.d.ts +1 -1
  60. package/dist/types/sdk/accounts/intents/testing/sdk-mock.d.ts +5 -0
  61. package/dist/types/sdk/accounts/liquidations/types.d.ts +1 -1
  62. package/dist/types/sdk/base/MultichainConstruct.d.ts +1 -1
  63. package/dist/types/sdk/base/TokensMeta.d.ts +1 -1
  64. package/dist/types/sdk/chain/chains.d.ts +51 -7
  65. package/dist/types/sdk/chain/index.d.ts +2 -2
  66. package/dist/types/sdk/index.d.ts +7 -7
  67. package/dist/types/sdk/market/MarketRegister.d.ts +1 -1
  68. package/dist/types/sdk/market/MarketSuite.d.ts +4 -34
  69. package/dist/types/sdk/market/ZapperRegister.d.ts +1 -1
  70. package/dist/types/sdk/market/credit/CreditSuite.d.ts +23 -14
  71. package/dist/types/sdk/market/credit/{isStrategyCollateral.d.ts → collateralUtils.d.ts} +36 -8
  72. package/dist/types/sdk/market/credit/index.d.ts +2 -3
  73. package/dist/types/sdk/market/index.d.ts +4 -4
  74. package/dist/types/sdk/market/oracle/PriceOracleBaseContract.d.ts +1 -1
  75. package/dist/types/sdk/market/oracle/types.d.ts +1 -1
  76. package/dist/types/sdk/market/strategyName.d.ts +18 -0
  77. package/dist/types/sdk/opportunities/OpportunitiesService.d.ts +2 -2
  78. package/dist/types/sdk/positions/types.d.ts +1 -1
  79. package/package.json +1 -1
  80. package/dist/cjs/sdk/market/credit/dominantCollateral.js +0 -47
  81. package/dist/esm/sdk/market/credit/dominantCollateral.js +0 -45
  82. package/dist/types/sdk/market/credit/dominantCollateral.d.ts +0 -29
@@ -1,7 +1,7 @@
1
1
  import { iLiquidationCompressorV313Abi } from "../../../abi/ILiquidationCompressorV313.js";
2
- import { MultichainChainIdsProps, MultichainNetworkProps, WithBlock, WithMultichain } from "../../types/multichain.js";
3
2
  import { LiquidatableAccountFilter } from "../../../model/liquidations.js";
4
3
  import "../../../model/index.js";
4
+ import { MultichainChainIdsProps, MultichainNetworkProps, WithBlock, WithMultichain } from "../../types/multichain.js";
5
5
  import "../../types/index.js";
6
6
  import { Address, ContractFunctionReturnType } from "viem";
7
7
  //#region src/sdk/accounts/liquidations/types.d.ts
@@ -1,7 +1,7 @@
1
1
  import { ChainId } from "../../model/primitives.js";
2
- import { NetworkType } from "../chain/chains.js";
3
2
  import { DataResponse } from "../../model/response.js";
4
3
  import "../../model/index.js";
4
+ import { NetworkType } from "../chain/chains.js";
5
5
  import { PluginsMap } from "../plugins/types.js";
6
6
  import "../plugins/index.js";
7
7
  import { OnchainSDK } from "../OnchainSDK.js";
@@ -1,7 +1,7 @@
1
1
  import { ILogger } from "../types/logger.js";
2
2
  import { Token } from "../../model/primitives.js";
3
- import { MulticallBatch } from "../utils/viem/executeMulticallBatches.js";
4
3
  import { AddressMap } from "../utils/AddressMap.js";
4
+ import { MulticallBatch } from "../utils/viem/executeMulticallBatches.js";
5
5
  import { Asset } from "./types.js";
6
6
  import "../utils/index.js";
7
7
  import { PhantomTokenMeta, RWATokenMeta, TokenMetaData } from "./token-types.js";
@@ -1,5 +1,8 @@
1
1
  import { AssetType, ChainId } from "../../model/primitives.js";
2
2
  import { CuratorName } from "../../model/curators.js";
3
+ import "../../model/index.js";
4
+ import { AddressMap } from "../utils/AddressMap.js";
5
+ import { AddressSet } from "../utils/AddressSet.js";
3
6
  import { Address, Chain } from "viem";
4
7
  import { z } from "zod/v4";
5
8
  //#region src/sdk/chain/chains.d.ts
@@ -17,7 +20,7 @@ interface GearboxChain extends Chain {
17
20
  /**
18
21
  * Market configurator addresses operated by known curators on this chain.
19
22
  **/
20
- defaultMarketConfigurators: Record<Address, CuratorName>;
23
+ defaultMarketConfigurators: AddressMap<CuratorName>;
21
24
  /**
22
25
  * Known RWA factory addresses on this chain
23
26
  */
@@ -25,7 +28,7 @@ interface GearboxChain extends Chain {
25
28
  /**
26
29
  * Market configurators used in test/staging environments.
27
30
  **/
28
- testMarketConfigurators?: Record<Address, CuratorName>;
31
+ testMarketConfigurators?: AddressMap<CuratorName>;
29
32
  /**
30
33
  * Denomination class of the market underlyings on this chain.
31
34
  *
@@ -35,21 +38,37 @@ interface GearboxChain extends Chain {
35
38
  * wrapper does not belong here: it is unwrapped before the lookup, so the
36
39
  * token it holds is what needs an entry.
37
40
  **/
38
- underlyingAssetTypes?: Record<Address, AssetType>;
41
+ underlyingAssetTypes?: AddressMap<AssetType>;
39
42
  /**
40
43
  * Tokens on this chain that represent a real-world asset. A market that
41
44
  * accepts one of them as collateral is reported as an RWA opportunity.
42
45
  **/
43
- rwaTokens?: Address[];
46
+ rwaTokens?: AddressSet;
44
47
  /**
45
48
  * Pools being wound down. Curated, and unrelated to any on-chain flag.
46
49
  **/
47
- sunsetPools?: Address[];
50
+ sunsetPools?: AddressSet;
48
51
  /**
49
52
  * Credit managers whose strategies are being wound down. Curated, and
50
53
  * unrelated to the credit facade's expiration date.
51
54
  **/
52
- sunsetStrategies?: Address[];
55
+ sunsetStrategies?: AddressSet;
56
+ /**
57
+ * Legacy credit managers whose target collateral cannot be inferred from
58
+ * the collateral list. Maps credit manager → target collateral.
59
+ **/
60
+ legacyStrategyTargets?: AddressMap<Address>;
61
+ /**
62
+ * Existing credit accounts whose target collateral must stay pinned, even
63
+ * when the credit manager's current target would say otherwise. Maps credit
64
+ * account → target collateral.
65
+ **/
66
+ accountTargetCollaterals?: AddressMap<Address>;
67
+ /**
68
+ * Display names for tokens whose ticker is not what a strategy row should
69
+ * show, e.g. a Pendle PT symbol rewritten as `"PT-sUSDe"`.
70
+ **/
71
+ tokenPrettyNames?: AddressMap<string>;
53
72
  /**
54
73
  * Whether this chain is production-ready
55
74
  **/
@@ -191,5 +210,30 @@ declare function isSunsetPool(pool: Address, network: NetworkType): boolean;
191
210
  * @param network - Network the credit manager lives on.
192
211
  **/
193
212
  declare function isSunsetStrategy(creditManager: Address, network: NetworkType): boolean;
213
+ /**
214
+ * Hardcoded target collateral of a legacy credit manager, or `undefined` when
215
+ * the manager is not in the table and the on-chain rule should apply.
216
+ *
217
+ * @param creditManager - Credit manager address.
218
+ * @param network - Chain id or {@link NetworkType} label.
219
+ **/
220
+ declare function getLegacyStrategyTarget(creditManager: Address, network: number | bigint | NetworkType): Address | undefined;
221
+ /**
222
+ * Hardcoded target collateral of an already-existing credit account, or
223
+ * `undefined` when the account is not in the table and the credit manager's
224
+ * target should apply.
225
+ *
226
+ * @param creditAccount - Credit account address.
227
+ * @param network - Chain id or {@link NetworkType} label.
228
+ **/
229
+ declare function getAccountTargetCollateral(creditAccount: Address, network: number | bigint | NetworkType): Address | undefined;
230
+ /**
231
+ * Curated display name of a token, or `undefined` when the token has none and
232
+ * its ticker symbol should be used instead.
233
+ *
234
+ * @param token - Token address.
235
+ * @param network - Chain id or {@link NetworkType} label.
236
+ **/
237
+ declare function getTokenPrettyName(token: Address, network: number | bigint | NetworkType): string | undefined;
194
238
  //#endregion
195
- export { GearboxChain, NetworkType, SUPPORTED_NETWORKS, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds };
239
+ export { GearboxChain, NetworkType, SUPPORTED_NETWORKS, chains, findCuratorMarketConfigurator, getAccountTargetCollateral, getAssetType, getChain, getCuratorName, getLegacyStrategyTarget, getNetworkType, getTokenPrettyName, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds };
@@ -1,3 +1,3 @@
1
- import { GearboxChain, NetworkType, SUPPORTED_NETWORKS, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds } from "./chains.js";
1
+ import { GearboxChain, NetworkType, SUPPORTED_NETWORKS, chains, findCuratorMarketConfigurator, getAccountTargetCollateral, getAssetType, getChain, getCuratorName, getLegacyStrategyTarget, getNetworkType, getTokenPrettyName, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds } from "./chains.js";
2
2
  import { detectNetwork } from "./detectNetwork.js";
3
- export { GearboxChain, NetworkType, SUPPORTED_NETWORKS, chains, detectNetwork, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds };
3
+ export { GearboxChain, NetworkType, SUPPORTED_NETWORKS, chains, detectNetwork, findCuratorMarketConfigurator, getAccountTargetCollateral, getAssetType, getChain, getCuratorName, getLegacyStrategyTarget, getNetworkType, getTokenPrettyName, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds };
@@ -1,5 +1,7 @@
1
1
  import { ILogger, LogFn } from "./types/logger.js";
2
- import { GearboxChain, NetworkType, SUPPORTED_NETWORKS, chains, findCuratorMarketConfigurator, getAssetType, getChain, getCuratorName, getNetworkType, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds } from "./chain/chains.js";
2
+ import { AddressMap } from "./utils/AddressMap.js";
3
+ import { AddressSet } from "./utils/AddressSet.js";
4
+ import { GearboxChain, NetworkType, SUPPORTED_NETWORKS, chains, findCuratorMarketConfigurator, getAccountTargetCollateral, getAssetType, getChain, getCuratorName, getLegacyStrategyTarget, getNetworkType, getTokenPrettyName, isPublicNetwork, isRWAToken, isSunsetPool, isSunsetStrategy, isSupportedNetwork, toChainIds } from "./chain/chains.js";
3
5
  import { BlockNumberProps, MultichainChainIdsProps, MultichainNetworkProps, WithBlock, WithMultichain } from "./types/multichain.js";
4
6
  import { generateCastTraceCall, getCastTraceArgs } from "./utils/viem/cast.js";
5
7
  import { DelegatedMulticall, executeDelegatedMulticalls } from "./utils/viem/executeDelegatedMulticalls.js";
@@ -13,8 +15,6 @@ import "./utils/viem/index.js";
13
15
  import { ClaimableWithdrawal, CurrentWithdrawals, DelayedIntentExtended, GetExternalAccountCurrentWithdrawalsProps, GetWithdrawalRequestResultProps, IRedemptionLoggerContract, IWithdrawalCompressorContract, PendingWithdrawal, RedemptionLog, RequestableWithdrawal, WithdrawableAsset, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, toWithdrawalStatus } from "./accounts/withdrawal-compressor/types.js";
14
16
  import { detectNetwork } from "./chain/detectNetwork.js";
15
17
  import "./chain/index.js";
16
- import { AddressMap } from "./utils/AddressMap.js";
17
- import { AddressSet } from "./utils/AddressSet.js";
18
18
  import { AdapterData, AssertAssignable, Asset, BaseParams, BaseState, ConnectedBotData, CreditAccountData, CreditAccountDataPayload, CreditAccountTokensSlice, CreditConfiguratorState, CreditFacadeState, CreditManagerDebtParams, CreditManagerState, CreditSuiteState, GaugeData, IBaseContract, MarketData, MarketFilter, ParsedCall, ParsedCallArgs, ParsedCallV2, PermitResult, PoolState, PriceFeedAnswer, PriceFeedMapEntry, PriceFeedTreeNode, PriceOracleData, QuotaKeeperState, QuotaState, RateKeeperState, RelaxedBaseParams, RewardInfo, TokenInfo, Unarray, VotingContractStatus } from "./base/types.js";
19
19
  import { AssetsMap } from "./utils/AssetsMap.js";
20
20
  import { functionArgsToMap, functionArgsToRecord, getFunctionSignature } from "./utils/abi-decode.js";
@@ -169,11 +169,10 @@ import { GaugeContract, GaugeParams } from "./market/pool/GaugeContract.js";
169
169
  import { LinearInterestRateModelContract } from "./market/pool/LinearInterestRateModelContract.js";
170
170
  import { PoolSuite } from "./market/pool/PoolSuite.js";
171
171
  import { PoolV310Contract } from "./market/pool/PoolV310Contract.js";
172
- import { MarketSuite, StrategyRef } from "./market/MarketSuite.js";
172
+ import { MarketSuite } from "./market/MarketSuite.js";
173
173
  import { CreditSuite } from "./market/credit/CreditSuite.js";
174
- import { dominantCollateral, mustGetDominantCollateral } from "./market/credit/dominantCollateral.js";
174
+ import { NON_STRATEGY_PHANTOM_TOKEN_TYPES, StrategyCollateralProps, dominantCollateral, isStrategyCollateral, pickStrategyTargetCollateral } from "./market/credit/collateralUtils.js";
175
175
  import { ExpectedBalanceDeltasProps, ExpectedOutput, expectedBalanceDeltas } from "./market/credit/expectedBalanceDeltas.js";
176
- import { IsStrategyCollateralProps, NON_STRATEGY_PHANTOM_TOKEN_TYPES, isStrategyCollateral } from "./market/credit/isStrategyCollateral.js";
177
176
  import { CompressorZapperData, ZapperData } from "./market/types.js";
178
177
  import { IZapperContract, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem } from "./market/zapper/types.js";
179
178
  import { createZapper } from "./market/zapper/createZapper.js";
@@ -183,6 +182,7 @@ import { IERC20ZapperContract } from "./market/zapper/IERC20ZapperContract.js";
183
182
  import { IETHZapperContract } from "./market/zapper/IETHZapperContract.js";
184
183
  import { MarketRegister, MarketRegistryState, MarketRegistryStateHuman } from "./market/MarketRegister.js";
185
184
  import { MAX_LEVERAGE_BUFFER_BPS, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, calcAdditionalBorrowApy, calcBorrowApy, calcMaxLeverage, calcPositionLeverage, calcUtilization, healthFactorBps, minSeizedAmount, optimalHFForPartialLiquidation, optimalRepaidAmount, rayToBps, usdToNumber } from "./market/math.js";
185
+ import { strategyName } from "./market/strategyName.js";
186
186
  import "./market/index.js";
187
187
  import { BasePlugin } from "./plugins/BasePlugin.js";
188
188
  import { IOnchainSDKPlugin, IOnchainSDKPluginConstructor, IPluginState, PluginFactoriesMap, PluginFactory, PluginState, PluginStatesMap, PluginsMap } from "./plugins/types.js";
@@ -262,4 +262,4 @@ import { LiquidationsService } from "./accounts/liquidations/LiquidationsService
262
262
  import { MultichainLiquidationsService } from "./accounts/liquidations/MultichainLiquidationsService.js";
263
263
  import "./accounts/index.js";
264
264
  import { SDKOptions, attachOptionsSchema, onchainSDKOptionsSchema } from "./options.js";
265
- 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, AbstractAdapterContract, AbstractAdapterContractOptions, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AbstractWithdrawalCompressorContract, AccountBotsService, type AccountCalculatorOperation, AccountMigratorAdapterContract, AccountSnapshot, AccountToCheck, AdapterContractStateHuman, AdapterContractType, AdapterData, AdapterFactoryArgs, AdapterProtocolOperation, AdapterType, type AddCollateralIntent, AddLiquidityProps, AddressMap, AddressProviderAddresses, AddressProviderState, AddressProviderV310Contract, type AddressProviderV3StateHuman, AddressSet, type AdjustLeverageIntent, type AliasLossPolicyStateHuman, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, AssertAssignable, Asset, type AssetPriceFeedStateHuman, AssetsMap, AttachOptions, BLOCKS_PER_WEEK_BY_NETWORK, BalanceDelta, BalancerStablePriceFeedContract, BalancerSwap, BalancerV3Pool, BalancerV3PoolStatus, BalancerV3RouterAdapterContract, BalancerV3WrapperAdapterContract, BalancerWeightedPriceFeedContract, type BalancerWeightedPriceFeedStateHuman, BaseContract, BaseContractArgs, type BaseContractStateHuman, BaseParams, BasePlugin, type BasePriceFeedStateHuman, BaseState, BasicSwapCall, BigIntMath, type BlockNumberProps, type BotListStateHuman, BotPermissions, BotStatusCall, BotsDirectResponse, type BoundedOracleStateHuman, BoundedPriceFeedContract, BuildLiquidationTxProps, BuildLiquidationTxPropsBase, CMSlice, CalcBorrowRateProps, CalcHealthFactorProps, CalcLiquidationPriceForTargetProps, CalcLiquidationPriceProps, CamelotPool, CamelotV3AdapterContract, ChainBlock, ChainBlockPin, ChainBlockSource, ChainConfig, ChainContractsRegister, ChainNotConfiguredError, ChainQueryOneProps, ChainQueryProps, ClaimFarmRewardsProps, ClaimableWithdrawal, ClientOptions, CloseCreditAccountResult, ClosePathBalances, CompositePriceFeedContract, CompressorZapperData, ConcreteAdapterContractOptions, ConnectedBotData, ConnectedBotsCall, ConnectedBotsPerAccount, type ConstantOracleStateHuman, Construct, ConstructOptions, type ContractMethod, ContractOrInterface, ContractParseError, ContractParseErrorOptions, ConvexDeposit, ConvexDepositAndStake, ConvexStake, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, ConvexWithdraw, ConvexWithdrawAndClaim, 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, CurrentWithdrawals, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveAddLiquidity, CurveClaims, CurveCryptoPriceFeedContract, CurveExchange, CurveRemoveLiquidity, CurveRemoveLiquidityOneCoin, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, CurveWithdrawal, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DStokenData, DUST_THRESHOLD, DaiUsdsAdapterContract, type DelayableIntent, DelayedIntentExtended, type DelayedRoute, type DelayedStart, type DelayedStartResult, DelayedWithdrawalClaim, DelayedWithdrawalRequest, DelegatedMulticall, DepositMetadata, type DepositStrategyIntent, ERC4626AdapterContract, ERC4626ReferralAdapterContract, EncodableCreditAccountOperation, Erc4626PriceFeedContract, EstimateRawTxGasParameters, EtherscanURLParam, ExecuteMulticallBatchesOptions, ExpectedBalanceDeltasProps, ExpectedOutput, ExternalPriceFeedContract, type FetchRedstonePayloadsOptions, FilterDustUSDOptions, FindBestClosePathProps, FindClaimAllRewardsProps, FindManyToOnePathProps, FindOneTokenPathProps, FindOpenStrategyPathProps, type FinishIntentProps, FluidDexAdapterContract, FormatBNOptions, FullyLiquidateProps, FullyLiquidateResult, GaugeContract, GaugeData, GaugeParams, type GaugeParamsHuman, type GaugeStateHuman, type GearStakingV3StateHuman, GearboxChain, type GearboxState, type GearboxStateHuman, GetApprovalAddressProps, GetConnectedBotsResponse, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetCreditAccountsArgs, GetCreditAccountsOptions, GetExternalAccountCurrentWithdrawalsProps, GetLiquidatableAccountsProps, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, GetReward, 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, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, type InstantRoute, IntentPreviewError, type IntentPreviewResult, type IntentRoutesResult, type InterestRateModelStateHuman, InterestRateModelType, InvalidDelayedIntentError, IsDustOptions, IsStrategyCollateralProps, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, LEVERAGE_DECIMALS, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LPMonopolizedPoolMeta, type LPPriceFeedStateHuman, LatestUpdate, LegacyAdapterOperation, LidoSubmit, LidoV1AdapterContract, LinearInterestRateModelContract, type LinearInterestRateModelStateHuman, LiquidationFees, LiquidationsService, ListPoolPositionsProps, ListPositionsProps, ListPositionsPropsBase, ListStrategyPositionsProps, LoadRWALiquidatorsProps, type LogFn, type LossPolicyStateHuman, MAX_INT, MAX_LEVERAGE_BUFFER_BPS, MAX_UINT16, MAX_UINT256, MIN_INT96, MULTICALL_ADDRESS, MakerDeposit, MakerRedeem, MarketData, MarketFilter, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, type MarketStateHuman, MarketSuite, MarketType, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, Methods, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, MissingSerializedParamsError, type MultiCall, MulticallBatch, MulticallWithFailure, MultichainAttachOptions, type MultichainChainIdsProps, MultichainConstruct, MultichainHydrateOptions, MultichainLiquidationsService, type MultichainNetworkProps, MultichainOpportunitiesService, MultichainPositionsService, MultichainSDK, MultichainSDKOptions, type MultichainState, type MultichainStateHuman, MultichainSyncStateOptions, NATIVE_ADDRESS, NON_STRATEGY_PHANTOM_TOKEN_TYPES, NOT_DEPLOYED, NO_VERSION, NetworkType, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, OnchainRequestableWithdrawal, OnchainSDK, OnchainSDKOptions, OpenCAProps, type OpenStrategyPreview, OpenStrategyPreviewResult, type OpenStrategyProps, OpenStrategyResult, type OperationState, 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, PendlePair, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PeripheryCompressorV310Contract, PeripheryContract, PermitResult, PhantomTokenContractType, PhantomTokenMeta, PickSomeRequired, PluginFactoriesMap, PluginFactory, PluginState, PluginStateVersionError, PluginStatesMap, PluginsMap, PoolQuotaKeeperContract, type PoolQuotaKeeperStateHuman, PoolService, PoolServiceCall, PoolServiceCallResult, PoolSimulation, PoolState, type PoolStateHuman, PoolSuite, type PoolSuiteStateHuman, PoolV310Contract, PositionsService, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, type PreviewErrorReason, 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, type RepayStrategyIntent, RequestableWithdrawal, type ResumableIntent, RetryOptions, RewardInfo, Rewards, type RouteRefusals, 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, SecuritizeOnRampAdapterContract, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRedemptionGatewayAdapterContract, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, SendRawTxParameters, SetBotProps, SetBotResult, SimpleTokenMeta, SimulateCallOptions, SimulateCallParameters, SimulateCallReturnType, SimulateMulticallParameters, SimulateMulticallReturnType, SimulatePoolOperationProps, SimulateWithPriceUpdatesError, SimulateWithPriceUpdatesErrorParams, SimulateWithPriceUpdatesErrorType, SimulateWithPriceUpdatesParameters, SimulateWithPriceUpdatesReturnType, SimulationError, SimulationErrorType, StakingRewardsAdapterContract, type StartIntent, StrategyRef, SupportedValue, Swap, SwapOperation, SyncStateOptions, type TimestampedCalldata, TokenAmount, TokenInfo, TokenMetaData, TokensMeta, TokensMetaState, TraderJoePool, TraderJoePoolVersion, TraderJoeRouterAdapterContract, Transfers, type TumblerStateHuman, TypedObjectUtils, Unarray, UniswapSwap, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, UpshiftVaultAdapterContract, VERSION_RANGE_310, VaultDeposit, VelodromeV2RouterAdapterContract, VersionRange, VersionedAbi, VotingContractStatus, WAD, WAD_DECIMALS_POW, WatchBlocksAsyncParameters, WatchBlocksAsyncReturnType, type WithBlock, type WithMultichain, type WithdrawAssetIntent, WithdrawCollateral, type WithdrawStrategyIntent, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalMetadata, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, WstETHPriceFeedContract, WstETHUnwrap, WstETHV1AdapterContract, WstETHWrap, YearnPriceFeedContract, ZapperContract, ZapperData, type ZapperStateHuman, ZeroPriceFeedContract, ZodAddress, ZodBigInt, ZodHex, accountSnapshotFromCreditAccountData, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, assetsMap, attachOptionsSchema, botPermissionsToString, bytes32ToString, calcAdditionalBorrowApy, calcBorrowApy, calcBorrowRate, calcHealthFactor, calcLiquidationPrice, calcLiquidationPriceForTarget, calcMaxLeverage, calcPositionLeverage, calcTimeToLiquidationMs, calcUtilization, chains, childLogger, classifyCurveOperation, createAdapter, createAddressProvider, createPriceOracle, createRawTx, createRedemptionLogger, createRouter, createWithdrawalCompressor, createZapper, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, decodeDelayedIntent, detectNetwork, dominantCollateral, encodeDelayedIntent, erc4626ReferralAdapterAbi, estimateRawTxGas, etherscanApiUrl, etherscanUrl, executeDelegatedMulticalls, executeMulticallBatches, expectedBalanceDeltas, fetchCreditAccountSlice, fetchRedstonePayloads, filterDust, filterDustUSD, findCuratorMarketConfigurator, fmtBinaryMask, fnSigToName, formatBN, formatBNvalue, formatDuration, formatLeverage, formatNumberToString_, formatPercentage, formatTimestamp, functionArgsToMap, functionArgsToRecord, generateCastTraceCall, getAdapterActionAbi, getAdapterDeployParamsAbi, getAdapterType, getAssetType, getCastTraceArgs, getChain, getCuratorName, getFunctionSignature, getNetworkType, getRawPriceUpdates, getSimulateWithPriceUpdatesError, getWithdrawalCompressorAddress, halfRAY, hasAdapterDeployParamsAbi, healthFactorBps, hexEq, hydrateAddressProvider, iBalancerV3RouterAbi, iBalancerV3RouterAdapterAbi, iBalancerV3WrapperAbi, iBalancerV3WrapperAdapterAbi, iBaseOnRampAbi, iBaseRewardPoolAbi, iBoosterAbi, iCamelotV3AdapterAbi, iCamelotV3RouterAbi, iConvexV1BaseRewardPoolAdapterAbi, iConvexV1BoosterAdapterAbi, iCreditAccountAbi, iCurvePoolAbi, iCurvePoolStableNGAbi, iCurvePool_2Abi, iCurvePool_3Abi, iCurvePool_4Abi, iCurveV1StableNgAdapterAbi, iCurveV1_2AssetsAdapterAbi, iCurveV1_3AssetsAdapterAbi, iCurveV1_4AssetsAdapterAbi, iDaiUsdsAbi, iDaiUsdsAdapterAbi, iERC4626Abi, iERC4626ReferralAbi, iFluidDexAbi, iFluidDexAdapterAbi, iInfinifiGatewayAbi, iInfinifiGatewayAdapterAbi, iInfinifiUnwindingGatewayAbi, iInfinifiUnwindingGatewayAdapterAbi, iKelpLRTDepositPoolGatewayAbi, iKelpLRTWithdrawalManagerGatewayAbi, iKelpLrtDepositPoolAdapterAbi, iKelpLrtDepositPoolGatewayAbi, iKelpLrtWithdrawalManagerAdapterAbi, iKelpLrtWithdrawalManagerGatewayAbi, iLidoV1AdapterAbi, iMellow4626VaultAdapterAbi, iMellowClaimerAbi, iMellowClaimerAdapterAbi, iMellowWrapperAbi, iMellowWrapperAdapterAbi, iMidasGatewayAdapterV311Abi, iMidasGatewayV311Abi, iMidasIssuanceVaultAdapterV310Abi, iMidasIssuanceVaultV310Abi, iMidasRedemptionVaultAdapterV310Abi, iMidasRedemptionVaultGatewayV310Abi, iPendleRouterAbi, iPendleRouterAdapterAbi, iSecuritizeOnRampAbi, iSecuritizeOnRampAdapterV310Abi, iSecuritizeRedemptionGatewayAdapterV311Abi, iSecuritizeRedemptionGatewayV311Abi, iStakingRewardsAbi, iStakingRewardsAdapterAbi, iTraderJoeRouterAbi, iTraderJoeRouterAdapterAbi, iUniswapV2AdapterAbi, iUniswapV2Router02Abi, iUniswapV3Abi, iUniswapV3AdapterAbi, iUniswapV4AdapterAbi, iUniswapV4GatewayAbi, iUpshiftVaultAdapterAbi, iUpshiftVaultGatewayAbi, iVelodromeV2RouterAbi, iVelodromeV2RouterAdapterAbi, isDust, isLPPriceFeed, isPublicNetwork, isRWAFactory, isRWAToken, isStrategyCollateral, isSunsetPool, isSunsetStrategy, isSupportedNetwork, isUpdatablePriceFeed, isV310, isVersionRange, iwstETHAbi, iwstEthv1AdapterAbi, json_parse, json_stringify, lidoV1_WETHGatewayAbi, mellowDvvAdapterAbi, minSeizedAmount, mustGetDominantCollateral, numberWithCommas, onchainSDKOptionsSchema, optimalHFForPartialLiquidation, optimalRepaidAmount, parseAdapterAction, parseAdapterDeployParams, parsePosNegAmount, percentFmt, rayToBps, rayToNumber, retry, rewardsFromTransfers, sendRawTx, shortAddress, shortHash, simulateCall, simulateMulticall, simulateWithPriceUpdates, swapFromTransfers, toAddress, toBN, toBigInt, toChainIds, toClaimableWithdrawal, toCreditAccountSlice, toNetTransfers, toPendingWithdrawal, toRequestableWithdrawal, toShares, toSharesUp, toSignificant, toWithdrawalStatus, usdToNumber, watchBlocksAsync };
265
+ 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, AbstractAdapterContract, AbstractAdapterContractOptions, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AbstractWithdrawalCompressorContract, AccountBotsService, type AccountCalculatorOperation, AccountMigratorAdapterContract, AccountSnapshot, AccountToCheck, AdapterContractStateHuman, AdapterContractType, AdapterData, AdapterFactoryArgs, AdapterProtocolOperation, AdapterType, type AddCollateralIntent, AddLiquidityProps, AddressMap, AddressProviderAddresses, AddressProviderState, AddressProviderV310Contract, type AddressProviderV3StateHuman, AddressSet, type AdjustLeverageIntent, type AliasLossPolicyStateHuman, AssembleCaOperationsProps, AssembleClaimDelayedCallsProps, AssembleCloseCreditAccountCallsProps, AssembleRepayCreditAccountCallsProps, AssembleStartDelayedWithdrawalCallsProps, AssertAssignable, Asset, type AssetPriceFeedStateHuman, AssetsMap, AttachOptions, BLOCKS_PER_WEEK_BY_NETWORK, BalanceDelta, BalancerStablePriceFeedContract, BalancerSwap, BalancerV3Pool, BalancerV3PoolStatus, BalancerV3RouterAdapterContract, BalancerV3WrapperAdapterContract, BalancerWeightedPriceFeedContract, type BalancerWeightedPriceFeedStateHuman, BaseContract, BaseContractArgs, type BaseContractStateHuman, BaseParams, BasePlugin, type BasePriceFeedStateHuman, BaseState, BasicSwapCall, BigIntMath, type BlockNumberProps, type BotListStateHuman, BotPermissions, BotStatusCall, BotsDirectResponse, type BoundedOracleStateHuman, BoundedPriceFeedContract, BuildLiquidationTxProps, BuildLiquidationTxPropsBase, CMSlice, CalcBorrowRateProps, CalcHealthFactorProps, CalcLiquidationPriceForTargetProps, CalcLiquidationPriceProps, CamelotPool, CamelotV3AdapterContract, ChainBlock, ChainBlockPin, ChainBlockSource, ChainConfig, ChainContractsRegister, ChainNotConfiguredError, ChainQueryOneProps, ChainQueryProps, ClaimFarmRewardsProps, ClaimableWithdrawal, ClientOptions, CloseCreditAccountResult, ClosePathBalances, CompositePriceFeedContract, CompressorZapperData, ConcreteAdapterContractOptions, ConnectedBotData, ConnectedBotsCall, ConnectedBotsPerAccount, type ConstantOracleStateHuman, Construct, ConstructOptions, type ContractMethod, ContractOrInterface, ContractParseError, ContractParseErrorOptions, ConvexDeposit, ConvexDepositAndStake, ConvexStake, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, ConvexWithdraw, ConvexWithdrawAndClaim, 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, CurrentWithdrawals, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveAddLiquidity, CurveClaims, CurveCryptoPriceFeedContract, CurveExchange, CurveRemoveLiquidity, CurveRemoveLiquidityOneCoin, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, CurveWithdrawal, DELAYED_INTENT_TYPES, DELAYED_INTENT_VERSION, DStokenData, DUST_THRESHOLD, DaiUsdsAdapterContract, type DelayableIntent, DelayedIntentExtended, type DelayedRoute, type DelayedStart, type DelayedStartResult, DelayedWithdrawalClaim, DelayedWithdrawalRequest, DelegatedMulticall, DepositMetadata, type DepositStrategyIntent, ERC4626AdapterContract, ERC4626ReferralAdapterContract, EncodableCreditAccountOperation, Erc4626PriceFeedContract, EstimateRawTxGasParameters, EtherscanURLParam, ExecuteMulticallBatchesOptions, ExpectedBalanceDeltasProps, ExpectedOutput, ExternalPriceFeedContract, type FetchRedstonePayloadsOptions, FilterDustUSDOptions, FindBestClosePathProps, FindClaimAllRewardsProps, FindManyToOnePathProps, FindOneTokenPathProps, FindOpenStrategyPathProps, type FinishIntentProps, FluidDexAdapterContract, FormatBNOptions, FullyLiquidateProps, FullyLiquidateResult, GaugeContract, GaugeData, GaugeParams, type GaugeParamsHuman, type GaugeStateHuman, type GearStakingV3StateHuman, GearboxChain, type GearboxState, type GearboxStateHuman, GetApprovalAddressProps, GetConnectedBotsResponse, GetConnectedBotsResult, GetConnectedMigrationBotsResult, GetCreditAccountsArgs, GetCreditAccountsOptions, GetExternalAccountCurrentWithdrawalsProps, GetLiquidatableAccountsProps, GetLiquidationDetailsProps, GetLiquidationDetailsPropsBase, GetLiquidationPositionsProps, GetLiquidationPositionsPropsBase, GetOpenAccountRequirementsProps, GetPendingWithdrawalsProps, GetPendingWithdrawalsResult, GetReward, 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, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, type InstantRoute, IntentPreviewError, type IntentPreviewResult, type IntentRoutesResult, type InterestRateModelStateHuman, InterestRateModelType, InvalidDelayedIntentError, IsDustOptions, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, LEVERAGE_DECIMALS, LIQUIDATION_APPROVAL_BUFFER, LIQUIDATION_COMPRESSOR_V313_ADDRESS, LPMonopolizedPoolMeta, type LPPriceFeedStateHuman, LatestUpdate, LegacyAdapterOperation, LidoSubmit, LidoV1AdapterContract, LinearInterestRateModelContract, type LinearInterestRateModelStateHuman, LiquidationFees, LiquidationsService, ListPoolPositionsProps, ListPositionsProps, ListPositionsPropsBase, ListStrategyPositionsProps, LoadRWALiquidatorsProps, type LogFn, type LossPolicyStateHuman, MAX_INT, MAX_LEVERAGE_BUFFER_BPS, MAX_UINT16, MAX_UINT256, MIN_INT96, MULTICALL_ADDRESS, MakerDeposit, MakerRedeem, MarketData, MarketFilter, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, type MarketStateHuman, MarketSuite, MarketType, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, Methods, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, MissingSerializedParamsError, type MultiCall, MulticallBatch, MulticallWithFailure, MultichainAttachOptions, type MultichainChainIdsProps, MultichainConstruct, MultichainHydrateOptions, MultichainLiquidationsService, type MultichainNetworkProps, MultichainOpportunitiesService, MultichainPositionsService, MultichainSDK, MultichainSDKOptions, type MultichainState, type MultichainStateHuman, MultichainSyncStateOptions, NATIVE_ADDRESS, NON_STRATEGY_PHANTOM_TOKEN_TYPES, NOT_DEPLOYED, NO_VERSION, NetworkType, OnchainLiquidationCall, OnchainLiquidationData, OnchainLiquidationOutput, OnchainRequestableWithdrawal, OnchainSDK, OnchainSDKOptions, OpenCAProps, type OpenStrategyPreview, OpenStrategyPreviewResult, type OpenStrategyProps, OpenStrategyResult, type OperationState, 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, PendlePair, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PeripheryCompressorV310Contract, PeripheryContract, PermitResult, PhantomTokenContractType, PhantomTokenMeta, PickSomeRequired, PluginFactoriesMap, PluginFactory, PluginState, PluginStateVersionError, PluginStatesMap, PluginsMap, PoolQuotaKeeperContract, type PoolQuotaKeeperStateHuman, PoolService, PoolServiceCall, PoolServiceCallResult, PoolSimulation, PoolState, type PoolStateHuman, PoolSuite, type PoolSuiteStateHuman, PoolV310Contract, PositionsService, PrepareUpdateQuotasProps, PreviewDelayedWithdrawalProps, type PreviewErrorReason, 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, type RepayStrategyIntent, RequestableWithdrawal, type ResumableIntent, RetryOptions, RewardInfo, Rewards, type RouteRefusals, 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, SecuritizeOnRampAdapterContract, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRedemptionGatewayAdapterContract, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, SendRawTxParameters, SetBotProps, SetBotResult, SimpleTokenMeta, SimulateCallOptions, SimulateCallParameters, SimulateCallReturnType, SimulateMulticallParameters, SimulateMulticallReturnType, SimulatePoolOperationProps, SimulateWithPriceUpdatesError, SimulateWithPriceUpdatesErrorParams, SimulateWithPriceUpdatesErrorType, SimulateWithPriceUpdatesParameters, SimulateWithPriceUpdatesReturnType, SimulationError, SimulationErrorType, StakingRewardsAdapterContract, type StartIntent, StrategyCollateralProps, SupportedValue, Swap, SwapOperation, SyncStateOptions, type TimestampedCalldata, TokenAmount, TokenInfo, TokenMetaData, TokensMeta, TokensMetaState, TraderJoePool, TraderJoePoolVersion, TraderJoeRouterAdapterContract, Transfers, type TumblerStateHuman, TypedObjectUtils, Unarray, UniswapSwap, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, UpshiftVaultAdapterContract, VERSION_RANGE_310, VaultDeposit, VelodromeV2RouterAdapterContract, VersionRange, VersionedAbi, VotingContractStatus, WAD, WAD_DECIMALS_POW, WatchBlocksAsyncParameters, WatchBlocksAsyncReturnType, type WithBlock, type WithMultichain, type WithdrawAssetIntent, WithdrawCollateral, type WithdrawStrategyIntent, WithdrawableAsset, WithdrawalCompressorLocation, WithdrawalCompressorV310Contract, WithdrawalCompressorV311Contract, WithdrawalCompressorV313Contract, WithdrawalCompressorVersion, WithdrawalMetadata, WithdrawalOutput, WithdrawalStatus, WithdrawalsState, WstETHPriceFeedContract, WstETHUnwrap, WstETHV1AdapterContract, WstETHWrap, YearnPriceFeedContract, ZapperContract, ZapperData, type ZapperStateHuman, ZeroPriceFeedContract, ZodAddress, ZodBigInt, ZodHex, accountSnapshotFromCreditAccountData, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, assetsMap, attachOptionsSchema, botPermissionsToString, bytes32ToString, calcAdditionalBorrowApy, calcBorrowApy, calcBorrowRate, calcHealthFactor, calcLiquidationPrice, calcLiquidationPriceForTarget, calcMaxLeverage, calcPositionLeverage, calcTimeToLiquidationMs, calcUtilization, chains, childLogger, classifyCurveOperation, createAdapter, createAddressProvider, createPriceOracle, createRawTx, createRedemptionLogger, createRouter, createWithdrawalCompressor, createZapper, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, decodeDelayedIntent, detectNetwork, dominantCollateral, encodeDelayedIntent, erc4626ReferralAdapterAbi, estimateRawTxGas, etherscanApiUrl, etherscanUrl, executeDelegatedMulticalls, executeMulticallBatches, expectedBalanceDeltas, fetchCreditAccountSlice, fetchRedstonePayloads, filterDust, filterDustUSD, findCuratorMarketConfigurator, fmtBinaryMask, fnSigToName, formatBN, formatBNvalue, formatDuration, formatLeverage, formatNumberToString_, formatPercentage, formatTimestamp, functionArgsToMap, functionArgsToRecord, generateCastTraceCall, getAccountTargetCollateral, getAdapterActionAbi, getAdapterDeployParamsAbi, getAdapterType, getAssetType, getCastTraceArgs, getChain, getCuratorName, getFunctionSignature, getLegacyStrategyTarget, getNetworkType, getRawPriceUpdates, getSimulateWithPriceUpdatesError, getTokenPrettyName, getWithdrawalCompressorAddress, halfRAY, hasAdapterDeployParamsAbi, healthFactorBps, hexEq, hydrateAddressProvider, iBalancerV3RouterAbi, iBalancerV3RouterAdapterAbi, iBalancerV3WrapperAbi, iBalancerV3WrapperAdapterAbi, iBaseOnRampAbi, iBaseRewardPoolAbi, iBoosterAbi, iCamelotV3AdapterAbi, iCamelotV3RouterAbi, iConvexV1BaseRewardPoolAdapterAbi, iConvexV1BoosterAdapterAbi, iCreditAccountAbi, iCurvePoolAbi, iCurvePoolStableNGAbi, iCurvePool_2Abi, iCurvePool_3Abi, iCurvePool_4Abi, iCurveV1StableNgAdapterAbi, iCurveV1_2AssetsAdapterAbi, iCurveV1_3AssetsAdapterAbi, iCurveV1_4AssetsAdapterAbi, iDaiUsdsAbi, iDaiUsdsAdapterAbi, iERC4626Abi, iERC4626ReferralAbi, iFluidDexAbi, iFluidDexAdapterAbi, iInfinifiGatewayAbi, iInfinifiGatewayAdapterAbi, iInfinifiUnwindingGatewayAbi, iInfinifiUnwindingGatewayAdapterAbi, iKelpLRTDepositPoolGatewayAbi, iKelpLRTWithdrawalManagerGatewayAbi, iKelpLrtDepositPoolAdapterAbi, iKelpLrtDepositPoolGatewayAbi, iKelpLrtWithdrawalManagerAdapterAbi, iKelpLrtWithdrawalManagerGatewayAbi, iLidoV1AdapterAbi, iMellow4626VaultAdapterAbi, iMellowClaimerAbi, iMellowClaimerAdapterAbi, iMellowWrapperAbi, iMellowWrapperAdapterAbi, iMidasGatewayAdapterV311Abi, iMidasGatewayV311Abi, iMidasIssuanceVaultAdapterV310Abi, iMidasIssuanceVaultV310Abi, iMidasRedemptionVaultAdapterV310Abi, iMidasRedemptionVaultGatewayV310Abi, iPendleRouterAbi, iPendleRouterAdapterAbi, iSecuritizeOnRampAbi, iSecuritizeOnRampAdapterV310Abi, iSecuritizeRedemptionGatewayAdapterV311Abi, iSecuritizeRedemptionGatewayV311Abi, iStakingRewardsAbi, iStakingRewardsAdapterAbi, iTraderJoeRouterAbi, iTraderJoeRouterAdapterAbi, iUniswapV2AdapterAbi, iUniswapV2Router02Abi, iUniswapV3Abi, iUniswapV3AdapterAbi, iUniswapV4AdapterAbi, iUniswapV4GatewayAbi, iUpshiftVaultAdapterAbi, iUpshiftVaultGatewayAbi, iVelodromeV2RouterAbi, iVelodromeV2RouterAdapterAbi, isDust, isLPPriceFeed, isPublicNetwork, isRWAFactory, isRWAToken, isStrategyCollateral, isSunsetPool, isSunsetStrategy, isSupportedNetwork, isUpdatablePriceFeed, isV310, isVersionRange, iwstETHAbi, iwstEthv1AdapterAbi, json_parse, json_stringify, lidoV1_WETHGatewayAbi, mellowDvvAdapterAbi, minSeizedAmount, numberWithCommas, onchainSDKOptionsSchema, optimalHFForPartialLiquidation, optimalRepaidAmount, parseAdapterAction, parseAdapterDeployParams, parsePosNegAmount, percentFmt, pickStrategyTargetCollateral, rayToBps, rayToNumber, retry, rewardsFromTransfers, sendRawTx, shortAddress, shortHash, simulateCall, simulateMulticall, simulateWithPriceUpdates, strategyName, swapFromTransfers, toAddress, toBN, toBigInt, toChainIds, toClaimableWithdrawal, toCreditAccountSlice, toNetTransfers, toPendingWithdrawal, toRequestableWithdrawal, toShares, toSharesUp, toSignificant, toWithdrawalStatus, usdToNumber, watchBlocksAsync };
@@ -1,6 +1,6 @@
1
+ import { AddressMap } from "../utils/AddressMap.js";
1
2
  import { DelegatedMulticall } from "../utils/viem/executeDelegatedMulticalls.js";
2
3
  import "../utils/viem/index.js";
3
- import { AddressMap } from "../utils/AddressMap.js";
4
4
  import { MarketData, MarketFilter } from "../base/types.js";
5
5
  import { MarketStateHuman, ZapperStateHuman } from "../types/state-human.js";
6
6
  import { ICreditFacadeContract } from "./credit/types.js";
@@ -1,6 +1,6 @@
1
1
  import { Token } from "../../model/primitives.js";
2
2
  import { Curator } from "../../model/curators.js";
3
- import { Opportunity, OpportunityFilter, PoolOpportunity, PoolOpportunityDetail, PriceFeedSummary, QuotaAsset, StrategyOpportunityDetail } from "../../model/opportunities.js";
3
+ import { Opportunity, OpportunityFilter, PoolOpportunity, PoolOpportunityDetail, PriceFeedSummary, QuotaAsset } from "../../model/opportunities.js";
4
4
  import "../../model/index.js";
5
5
  import { MarketData } from "../base/types.js";
6
6
  import { IRWAFactory } from "./rwa/types.js";
@@ -20,14 +20,6 @@ import { SDKConstruct } from "../base/SDKConstruct.js";
20
20
  import "../base/index.js";
21
21
  import { Address } from "viem";
22
22
  //#region src/sdk/market/MarketSuite.d.ts
23
- /**
24
- * One `(credit suite, target collateral)` pair that qualifies as a leveraged
25
- * position.
26
- */
27
- interface StrategyRef {
28
- suite: CreditSuite;
29
- collateral: Address;
30
- }
31
23
  /**
32
24
  * Aggregates all SDK wrappers that make up one Gearbox market.
33
25
  *
@@ -117,11 +109,6 @@ declare class MarketSuite extends SDKConstruct {
117
109
  * {@inheritDoc MarketConfiguratorContract.curator}
118
110
  */
119
111
  get curator(): Curator;
120
- /**
121
- * Every `(credit suite, collateral)` pair of this market that qualifies as a
122
- * leveraged position.
123
- */
124
- get strategies(): StrategyRef[];
125
112
  /**
126
113
  * Tokens a position can actually be built on in this market, deduplicated
127
114
  * across its credit suites.
@@ -152,8 +139,8 @@ declare class MarketSuite extends SDKConstruct {
152
139
  */
153
140
  priceFeedSummary(collateral: Address): PriceFeedSummary;
154
141
  /**
155
- * Every opportunity this market offers: its pool, plus one row per
156
- * `(credit manager, target collateral)` pair.
142
+ * Every opportunity this market offers: its pool, plus one row per credit
143
+ * manager that qualifies as a strategy.
157
144
  *
158
145
  * @param filter - Optional narrowing. A filter naming a kind skips building
159
146
  * the other kind entirely; every built row is then checked in full by
@@ -170,23 +157,6 @@ declare class MarketSuite extends SDKConstruct {
170
157
  * {@link poolOpportunity} plus the data only its detail screen needs.
171
158
  */
172
159
  poolOpportunityDetail(): PoolOpportunityDetail;
173
- /**
174
- * Resolves a strategy of this market by its two halves.
175
- *
176
- * @param creditManager - Credit manager the position is opened in.
177
- * @param collateral - Target collateral of the position.
178
- * @throws If this market has no such credit manager, or if that manager does
179
- * not accept the collateral as a strategy.
180
- */
181
- mustFindStrategy(creditManager: Address, collateral: Address): StrategyRef;
182
- /**
183
- * Detailed view of one leveraged position of this market.
184
- *
185
- * @param creditManager - Credit manager the position is opened in.
186
- * @param collateral - Target collateral of the position.
187
- * @throws If this market has no such strategy, see {@link mustFindStrategy}.
188
- */
189
- strategyOpportunityDetail(creditManager: Address, collateral: Address): StrategyOpportunityDetail;
190
160
  /**
191
161
  * Whether any child contract wrapper has observed events that require a
192
162
  * market resync.
@@ -207,4 +177,4 @@ declare class MarketSuite extends SDKConstruct {
207
177
  stateHuman(raw?: boolean): MarketStateHuman;
208
178
  }
209
179
  //#endregion
210
- export { MarketSuite, StrategyRef };
180
+ export { MarketSuite };
@@ -1,6 +1,6 @@
1
+ import { AddressMap } from "../utils/AddressMap.js";
1
2
  import { MulticallBatch } from "../utils/viem/executeMulticallBatches.js";
2
3
  import "../utils/viem/index.js";
3
- import { AddressMap } from "../utils/AddressMap.js";
4
4
  import { ZapperStateHuman } from "../types/state-human.js";
5
5
  import { ZapperData } from "./types.js";
6
6
  import { IZapperContract } from "./zapper/types.js";
@@ -143,6 +143,21 @@ declare class CreditSuite extends SDKConstruct {
143
143
  * whatever its collaterals are.
144
144
  */
145
145
  get strategyCollaterals(): Address[];
146
+ /**
147
+ * The single target collateral of this suite's strategy, or `undefined` when
148
+ * none can be resolved.
149
+ *
150
+ * Resolution, in order:
151
+ * 1. a hardcoded legacy mapping for this credit manager, when that token is
152
+ * still a collateral of the manager (it may be absent on an older
153
+ * snapshot, or after it was delisted);
154
+ * 2. the collateral with the biggest index in
155
+ * {@link ICreditManagerContract.collateralTokens} that
156
+ * {@link isStrategyCollateral} accepts with quota required;
157
+ * 3. the biggest-index collateral that {@link isStrategyCollateral} accepts
158
+ * without quota.
159
+ */
160
+ get strategyTargetCollateral(): Address | undefined;
146
161
  /**
147
162
  * Largest debt a single new position can take on right now: the tightest of
148
163
  * this manager's remaining debt limit, the pool's free liquidity and the
@@ -150,26 +165,20 @@ declare class CreditSuite extends SDKConstruct {
150
165
  */
151
166
  get maxBorrowAmount(): bigint;
152
167
  /**
153
- * Display name of a leveraged position built on one collateral token, e.g.
154
- * `"wstETH / WETH"`.
155
- *
156
- * @param collateral - Target collateral of the position.
168
+ * Display name of this suite's leveraged strategy, e.g. `"wstETH / WETH"`,
169
+ * or `undefined` when {@link strategyTargetCollateral} cannot be resolved.
157
170
  */
158
- strategyName(collateral: Address): string;
171
+ get strategyName(): string | undefined;
159
172
  /**
160
- * Describes a leveraged position built on one collateral token as the shared
161
- * read model does.
162
- *
163
- * @param collateral - Target collateral of the position.
164
- * @throws If the credit manager does not value the collateral.
173
+ * Describes this suite's leveraged strategy as the shared read model does,
174
+ * or `undefined` when {@link strategyTargetCollateral} cannot be resolved or
175
+ * {@link maxBorrowAmount} is `0`.
165
176
  */
166
- strategyOpportunity(collateral: Address): StrategyOpportunity;
177
+ strategyOpportunity(): StrategyOpportunity | undefined;
167
178
  /**
168
179
  * {@link strategyOpportunity} plus the data only its detail screen needs.
169
- *
170
- * @param collateral - Target collateral of the position.
171
180
  */
172
- strategyOpportunityDetail(collateral: Address): StrategyOpportunityDetail;
181
+ strategyOpportunityDetail(): StrategyOpportunityDetail | undefined;
173
182
  /**
174
183
  * Everything a partial liquidation of credit account needs, with any parameter the
175
184
  * caller pinned down taken as given and the rest derived from current state.
@@ -1,5 +1,8 @@
1
+ import { CreditAccountData } from "../../base/types.js";
2
+ import { MarketSuite } from "../MarketSuite.js";
3
+ import "../../base/index.js";
1
4
  import { Address } from "viem";
2
- //#region src/sdk/market/credit/isStrategyCollateral.d.ts
5
+ //#region src/sdk/market/credit/collateralUtils.d.ts
3
6
  /**
4
7
  * Withdrawal and redemption phantom tokens that can never be acquired as a
5
8
  * strategy target. Other `PHANTOM_TOKEN::*` types (Convex, Infrared, staking
@@ -7,10 +10,11 @@ import { Address } from "viem";
7
10
  */
8
11
  declare const NON_STRATEGY_PHANTOM_TOKEN_TYPES: readonly ["PHANTOM_TOKEN::INFINIFI_UNWIND", "PHANTOM_TOKEN::MELLOW_WITHDRAWAL", "PHANTOM_TOKEN::MIDAS_REDEMPTION", "PHANTOM_TOKEN::SECURITIZE_RD", "PHANTOM_TOKEN::UPSHIFT_WITHDRAW"];
9
12
  /**
10
- * Inputs of {@link isStrategyCollateral}, all resolved against the credit
11
- * manager, market, and token metadata by the caller.
13
+ * Inputs of {@link isStrategyCollateral} and {@link pickStrategyTargetCollateral},
14
+ * all resolved against the credit manager, market, and token metadata by the
15
+ * caller.
12
16
  */
13
- interface IsStrategyCollateralProps {
17
+ interface StrategyCollateralProps {
14
18
  /**
15
19
  * Candidate collateral token.
16
20
  **/
@@ -66,9 +70,33 @@ interface IsStrategyCollateralProps {
66
70
  * - is not an expired token, e.g. a matured Pendle PT;
67
71
  * - has a non-zero main price in the market's oracle — a zero or missing
68
72
  * answer (e.g. a failed or zero price feed) means the position cannot be
69
- * valued;
70
- * - the market still accepts quota for.
73
+ * valued.
74
+ *
75
+ * Pass `requireQuota` as `true` to also require that the market still accepts
76
+ * quota for the token.
71
77
  */
72
- declare function isStrategyCollateral({ token, underlying, unwrappedUnderlying, liquidationThreshold, contractType, isExpired, mainPrice, hasActiveQuota }: IsStrategyCollateralProps): boolean;
78
+ declare function isStrategyCollateral({ token, underlying, unwrappedUnderlying, liquidationThreshold, contractType, isExpired, mainPrice, hasActiveQuota }: StrategyCollateralProps, requireQuota?: boolean): boolean;
79
+ /**
80
+ * Picks the single strategy target from a credit manager's collateral list.
81
+ *
82
+ * Walks {@link tokens} from the end (biggest index first) and returns the
83
+ * first token that {@link isStrategyCollateral} accepts with quota required.
84
+ * If none has an active quota, returns the biggest-index candidate that
85
+ * qualifies without quota. `undefined` when nothing qualifies. A hardcoded
86
+ * legacy mapping, when present, is applied by the caller before this function.
87
+ **/
88
+ declare function pickStrategyTargetCollateral(tokens: StrategyCollateralProps[]): Address | undefined;
89
+ /**
90
+ * The account's dominant collateral: the most valuable enabled non-underlying
91
+ * token it holds above dust, by USD value.
92
+ *
93
+ * Used to pick the collateral a partial liquidation seizes by default.
94
+ *
95
+ * @param account - Account to inspect.
96
+ * @param market - Market of the account, whose oracle prices the candidates.
97
+ * @returns The dominant collateral, or `undefined` when the account holds
98
+ * nothing but its underlying, or nothing the oracle can price.
99
+ **/
100
+ declare function dominantCollateral(account: CreditAccountData, market: MarketSuite): Address | undefined;
73
101
  //#endregion
74
- export { IsStrategyCollateralProps, NON_STRATEGY_PHANTOM_TOKEN_TYPES, isStrategyCollateral };
102
+ export { NON_STRATEGY_PHANTOM_TOKEN_TYPES, StrategyCollateralProps, dominantCollateral, isStrategyCollateral, pickStrategyTargetCollateral };
@@ -4,7 +4,6 @@ import { CreditFacadeV310Abi as abi, CreditFacadeV310BaseContract } from "./Cred
4
4
  import { CreditFacadeV310Contract } from "./CreditFacadeV310Contract.js";
5
5
  import { CreditManagerV310Contract } from "./CreditManagerV310Contract.js";
6
6
  import { CreditSuite } from "./CreditSuite.js";
7
- import { dominantCollateral, mustGetDominantCollateral } from "./dominantCollateral.js";
7
+ import { NON_STRATEGY_PHANTOM_TOKEN_TYPES, StrategyCollateralProps, dominantCollateral, isStrategyCollateral, pickStrategyTargetCollateral } from "./collateralUtils.js";
8
8
  import { ExpectedBalanceDeltasProps, ExpectedOutput, expectedBalanceDeltas } from "./expectedBalanceDeltas.js";
9
- import { IsStrategyCollateralProps, NON_STRATEGY_PHANTOM_TOKEN_TYPES, isStrategyCollateral } from "./isStrategyCollateral.js";
10
- export { BalanceDelta, CreditAccountTokenQuota, CreditConfiguratorV310Contract, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, ExpectedBalanceDeltasProps, ExpectedOutput, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IsStrategyCollateralProps, LiquidationFees, NON_STRATEGY_PHANTOM_TOKEN_TYPES, PartialLiquidationParams, PrepareUpdateQuotasProps, RampEvent, dominantCollateral, expectedBalanceDeltas, isStrategyCollateral, mustGetDominantCollateral };
9
+ export { BalanceDelta, CreditAccountTokenQuota, CreditConfiguratorV310Contract, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, ExpectedBalanceDeltasProps, ExpectedOutput, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, LiquidationFees, NON_STRATEGY_PHANTOM_TOKEN_TYPES, PartialLiquidationParams, PrepareUpdateQuotasProps, RampEvent, StrategyCollateralProps, dominantCollateral, expectedBalanceDeltas, isStrategyCollateral, pickStrategyTargetCollateral };
@@ -135,11 +135,10 @@ import { LinearInterestRateModelContract } from "./pool/LinearInterestRateModelC
135
135
  import { PoolSuite } from "./pool/PoolSuite.js";
136
136
  import { PoolV310Contract } from "./pool/PoolV310Contract.js";
137
137
  import "./pool/index.js";
138
- import { MarketSuite, StrategyRef } from "./MarketSuite.js";
138
+ import { MarketSuite } from "./MarketSuite.js";
139
139
  import { CreditSuite } from "./credit/CreditSuite.js";
140
- import { dominantCollateral, mustGetDominantCollateral } from "./credit/dominantCollateral.js";
140
+ import { NON_STRATEGY_PHANTOM_TOKEN_TYPES, StrategyCollateralProps, dominantCollateral, isStrategyCollateral, pickStrategyTargetCollateral } from "./credit/collateralUtils.js";
141
141
  import { ExpectedBalanceDeltasProps, ExpectedOutput, expectedBalanceDeltas } from "./credit/expectedBalanceDeltas.js";
142
- import { IsStrategyCollateralProps, NON_STRATEGY_PHANTOM_TOKEN_TYPES, isStrategyCollateral } from "./credit/isStrategyCollateral.js";
143
142
  import "./credit/index.js";
144
143
  import { CompressorZapperData, ZapperData } from "./types.js";
145
144
  import { IZapperContract, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem } from "./zapper/types.js";
@@ -151,4 +150,5 @@ import { IETHZapperContract } from "./zapper/IETHZapperContract.js";
151
150
  import "./zapper/index.js";
152
151
  import { MarketRegister, MarketRegistryState, MarketRegistryStateHuman } from "./MarketRegister.js";
153
152
  import { MAX_LEVERAGE_BUFFER_BPS, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, calcAdditionalBorrowApy, calcBorrowApy, calcMaxLeverage, calcPositionLeverage, calcUtilization, healthFactorBps, minSeizedAmount, optimalHFForPartialLiquidation, optimalRepaidAmount, rayToBps, usdToNumber } from "./math.js";
154
- export { AbstractAdapterContract, AbstractAdapterContractOptions, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AccountMigratorAdapterContract, AdapterContractStateHuman, AdapterContractType, AdapterFactoryArgs, AdapterProtocolOperation, AdapterType, BalanceDelta, BalancerStablePriceFeedContract, BalancerSwap, BalancerV3Pool, BalancerV3PoolStatus, BalancerV3RouterAdapterContract, BalancerV3WrapperAdapterContract, BalancerWeightedPriceFeedContract, BasicSwapCall, BoundedPriceFeedContract, CamelotPool, CamelotV3AdapterContract, CompositePriceFeedContract, CompressorZapperData, ConcreteAdapterContractOptions, ConvexDeposit, ConvexDepositAndStake, ConvexStake, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, ConvexWithdraw, ConvexWithdrawAndClaim, CreditAccountTokenQuota, CreditConfiguratorV310Contract, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveAddLiquidity, CurveClaims, CurveCryptoPriceFeedContract, CurveExchange, CurveRemoveLiquidity, CurveRemoveLiquidityOneCoin, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, CurveWithdrawal, DStokenData, DaiUsdsAdapterContract, DelayedWithdrawalClaim, DelayedWithdrawalRequest, ERC4626AdapterContract, ERC4626ReferralAdapterContract, Erc4626PriceFeedContract, ExpectedBalanceDeltasProps, ExpectedOutput, ExternalPriceFeedContract, type FetchRedstonePayloadsOptions, FluidDexAdapterContract, GaugeContract, GaugeParams, GetOpenAccountRequirementsProps, GetReward, IAdapterContract, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, IPoolContract, IPriceFeedContract, IPriceOracleContract, IRWAFactory, IRateKeeperContract, IUpdatablePriceFeedContract, IZapperContract, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, InterestRateModelType, IsStrategyCollateralProps, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, LatestUpdate, LegacyAdapterOperation, LidoSubmit, LidoV1AdapterContract, LinearInterestRateModelContract, LiquidationFees, MAX_LEVERAGE_BUFFER_BPS, MakerDeposit, MakerRedeem, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, MarketSuite, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, NON_STRATEGY_PHANTOM_TOKEN_TYPES, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem, PartialLiquidationParams, PartialPriceFeedInitError, PartialPriceFeedTreeNode, PendlePair, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PoolQuotaKeeperContract, PoolSuite, PoolV310Contract, PrepareUpdateQuotasProps, 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, SecuritizeOnRampAdapterContract, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRedemptionGatewayAdapterContract, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, StakingRewardsAdapterContract, StrategyRef, Swap, type TimestampedCalldata, TokenAmount, TraderJoePool, TraderJoePoolVersion, TraderJoeRouterAdapterContract, Transfers, UniswapSwap, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, UpshiftVaultAdapterContract, VaultDeposit, VelodromeV2RouterAdapterContract, VersionedAbi, WithdrawCollateral, WstETHPriceFeedContract, WstETHUnwrap, WstETHV1AdapterContract, WstETHWrap, YearnPriceFeedContract, ZapperContract, ZapperData, ZeroPriceFeedContract, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, calcAdditionalBorrowApy, calcBorrowApy, calcMaxLeverage, calcPositionLeverage, calcUtilization, classifyCurveOperation, createAdapter, createPriceOracle, createZapper, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, dominantCollateral, erc4626ReferralAdapterAbi, expectedBalanceDeltas, fetchRedstonePayloads, fnSigToName, getAdapterActionAbi, getAdapterDeployParamsAbi, getAdapterType, getRawPriceUpdates, hasAdapterDeployParamsAbi, healthFactorBps, iBalancerV3RouterAbi, iBalancerV3RouterAdapterAbi, iBalancerV3WrapperAbi, iBalancerV3WrapperAdapterAbi, iBaseOnRampAbi, iBaseRewardPoolAbi, iBoosterAbi, iCamelotV3AdapterAbi, iCamelotV3RouterAbi, iConvexV1BaseRewardPoolAdapterAbi, iConvexV1BoosterAdapterAbi, iCurvePoolAbi, iCurvePoolStableNGAbi, iCurvePool_2Abi, iCurvePool_3Abi, iCurvePool_4Abi, iCurveV1StableNgAdapterAbi, iCurveV1_2AssetsAdapterAbi, iCurveV1_3AssetsAdapterAbi, iCurveV1_4AssetsAdapterAbi, iDaiUsdsAbi, iDaiUsdsAdapterAbi, iERC4626Abi, iERC4626ReferralAbi, iFluidDexAbi, iFluidDexAdapterAbi, iInfinifiGatewayAbi, iInfinifiGatewayAdapterAbi, iInfinifiUnwindingGatewayAbi, iInfinifiUnwindingGatewayAdapterAbi, iKelpLRTDepositPoolGatewayAbi, iKelpLRTWithdrawalManagerGatewayAbi, iKelpLrtDepositPoolAdapterAbi, iKelpLrtDepositPoolGatewayAbi, iKelpLrtWithdrawalManagerAdapterAbi, iKelpLrtWithdrawalManagerGatewayAbi, iLidoV1AdapterAbi, iMellow4626VaultAdapterAbi, iMellowClaimerAbi, iMellowClaimerAdapterAbi, iMellowWrapperAbi, iMellowWrapperAdapterAbi, iMidasGatewayAdapterV311Abi, iMidasGatewayV311Abi, iMidasIssuanceVaultAdapterV310Abi, iMidasIssuanceVaultV310Abi, iMidasRedemptionVaultAdapterV310Abi, iMidasRedemptionVaultGatewayV310Abi, iPendleRouterAbi, iPendleRouterAdapterAbi, iSecuritizeOnRampAbi, iSecuritizeOnRampAdapterV310Abi, iSecuritizeRedemptionGatewayAdapterV311Abi, iSecuritizeRedemptionGatewayV311Abi, iStakingRewardsAbi, iStakingRewardsAdapterAbi, iTraderJoeRouterAbi, iTraderJoeRouterAdapterAbi, iUniswapV2AdapterAbi, iUniswapV2Router02Abi, iUniswapV3Abi, iUniswapV3AdapterAbi, iUniswapV4AdapterAbi, iUniswapV4GatewayAbi, iUpshiftVaultAdapterAbi, iUpshiftVaultGatewayAbi, iVelodromeV2RouterAbi, iVelodromeV2RouterAdapterAbi, isLPPriceFeed, isRWAFactory, isStrategyCollateral, isUpdatablePriceFeed, iwstETHAbi, iwstEthv1AdapterAbi, lidoV1_WETHGatewayAbi, mellowDvvAdapterAbi, minSeizedAmount, mustGetDominantCollateral, optimalHFForPartialLiquidation, optimalRepaidAmount, parseAdapterAction, parseAdapterDeployParams, parsePosNegAmount, rayToBps, rewardsFromTransfers, swapFromTransfers, toNetTransfers, usdToNumber };
153
+ import { strategyName } from "./strategyName.js";
154
+ export { AbstractAdapterContract, AbstractAdapterContractOptions, AbstractLPPriceFeedContract, AbstractPriceFeedContract, AccountMigratorAdapterContract, AdapterContractStateHuman, AdapterContractType, AdapterFactoryArgs, AdapterProtocolOperation, AdapterType, BalanceDelta, BalancerStablePriceFeedContract, BalancerSwap, BalancerV3Pool, BalancerV3PoolStatus, BalancerV3RouterAdapterContract, BalancerV3WrapperAdapterContract, BalancerWeightedPriceFeedContract, BasicSwapCall, BoundedPriceFeedContract, CamelotPool, CamelotV3AdapterContract, CompositePriceFeedContract, CompressorZapperData, ConcreteAdapterContractOptions, ConvexDeposit, ConvexDepositAndStake, ConvexStake, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, ConvexWithdraw, ConvexWithdrawAndClaim, CreditAccountTokenQuota, CreditConfiguratorV310Contract, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveAddLiquidity, CurveClaims, CurveCryptoPriceFeedContract, CurveExchange, CurveRemoveLiquidity, CurveRemoveLiquidityOneCoin, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, CurveWithdrawal, DStokenData, DaiUsdsAdapterContract, DelayedWithdrawalClaim, DelayedWithdrawalRequest, ERC4626AdapterContract, ERC4626ReferralAdapterContract, Erc4626PriceFeedContract, ExpectedBalanceDeltasProps, ExpectedOutput, ExternalPriceFeedContract, type FetchRedstonePayloadsOptions, FluidDexAdapterContract, GaugeContract, GaugeParams, GetOpenAccountRequirementsProps, GetReward, IAdapterContract, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, IPoolContract, IPriceFeedContract, IPriceOracleContract, IRWAFactory, IRateKeeperContract, IUpdatablePriceFeedContract, IZapperContract, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, InterestRateModelType, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, LatestUpdate, LegacyAdapterOperation, LidoSubmit, LidoV1AdapterContract, LinearInterestRateModelContract, LiquidationFees, MAX_LEVERAGE_BUFFER_BPS, MakerDeposit, MakerRedeem, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, MarketSuite, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, NON_STRATEGY_PHANTOM_TOKEN_TYPES, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem, PartialLiquidationParams, PartialPriceFeedInitError, PartialPriceFeedTreeNode, PendlePair, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PoolQuotaKeeperContract, PoolSuite, PoolV310Contract, PrepareUpdateQuotasProps, 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, SecuritizeOnRampAdapterContract, SecuritizeOpenAccountRequirements, SecuritizeOperationArgs, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRedemptionGatewayAdapterContract, SecuritizeRegisterMessage, SecuritizeRegisterVaultMessage, SecuritizeSignature, StakingRewardsAdapterContract, StrategyCollateralProps, Swap, type TimestampedCalldata, TokenAmount, TraderJoePool, TraderJoePoolVersion, TraderJoeRouterAdapterContract, Transfers, UniswapSwap, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UnsupportedZapperFunctionError, UpdatePriceFeedsResult, UpshiftVaultAdapterContract, VaultDeposit, VelodromeV2RouterAdapterContract, VersionedAbi, WithdrawCollateral, WstETHPriceFeedContract, WstETHUnwrap, WstETHV1AdapterContract, WstETHWrap, YearnPriceFeedContract, ZapperContract, ZapperData, ZeroPriceFeedContract, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, calcAdditionalBorrowApy, calcBorrowApy, calcMaxLeverage, calcPositionLeverage, calcUtilization, classifyCurveOperation, createAdapter, createPriceOracle, createZapper, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, dominantCollateral, erc4626ReferralAdapterAbi, expectedBalanceDeltas, fetchRedstonePayloads, fnSigToName, getAdapterActionAbi, getAdapterDeployParamsAbi, getAdapterType, getRawPriceUpdates, hasAdapterDeployParamsAbi, healthFactorBps, iBalancerV3RouterAbi, iBalancerV3RouterAdapterAbi, iBalancerV3WrapperAbi, iBalancerV3WrapperAdapterAbi, iBaseOnRampAbi, iBaseRewardPoolAbi, iBoosterAbi, iCamelotV3AdapterAbi, iCamelotV3RouterAbi, iConvexV1BaseRewardPoolAdapterAbi, iConvexV1BoosterAdapterAbi, iCurvePoolAbi, iCurvePoolStableNGAbi, iCurvePool_2Abi, iCurvePool_3Abi, iCurvePool_4Abi, iCurveV1StableNgAdapterAbi, iCurveV1_2AssetsAdapterAbi, iCurveV1_3AssetsAdapterAbi, iCurveV1_4AssetsAdapterAbi, iDaiUsdsAbi, iDaiUsdsAdapterAbi, iERC4626Abi, iERC4626ReferralAbi, iFluidDexAbi, iFluidDexAdapterAbi, iInfinifiGatewayAbi, iInfinifiGatewayAdapterAbi, iInfinifiUnwindingGatewayAbi, iInfinifiUnwindingGatewayAdapterAbi, iKelpLRTDepositPoolGatewayAbi, iKelpLRTWithdrawalManagerGatewayAbi, iKelpLrtDepositPoolAdapterAbi, iKelpLrtDepositPoolGatewayAbi, iKelpLrtWithdrawalManagerAdapterAbi, iKelpLrtWithdrawalManagerGatewayAbi, iLidoV1AdapterAbi, iMellow4626VaultAdapterAbi, iMellowClaimerAbi, iMellowClaimerAdapterAbi, iMellowWrapperAbi, iMellowWrapperAdapterAbi, iMidasGatewayAdapterV311Abi, iMidasGatewayV311Abi, iMidasIssuanceVaultAdapterV310Abi, iMidasIssuanceVaultV310Abi, iMidasRedemptionVaultAdapterV310Abi, iMidasRedemptionVaultGatewayV310Abi, iPendleRouterAbi, iPendleRouterAdapterAbi, iSecuritizeOnRampAbi, iSecuritizeOnRampAdapterV310Abi, iSecuritizeRedemptionGatewayAdapterV311Abi, iSecuritizeRedemptionGatewayV311Abi, iStakingRewardsAbi, iStakingRewardsAdapterAbi, iTraderJoeRouterAbi, iTraderJoeRouterAdapterAbi, iUniswapV2AdapterAbi, iUniswapV2Router02Abi, iUniswapV3Abi, iUniswapV3AdapterAbi, iUniswapV4AdapterAbi, iUniswapV4GatewayAbi, iUpshiftVaultAdapterAbi, iUpshiftVaultGatewayAbi, iVelodromeV2RouterAbi, iVelodromeV2RouterAdapterAbi, isLPPriceFeed, isRWAFactory, isStrategyCollateral, isUpdatablePriceFeed, iwstETHAbi, iwstEthv1AdapterAbi, lidoV1_WETHGatewayAbi, mellowDvvAdapterAbi, minSeizedAmount, optimalHFForPartialLiquidation, optimalRepaidAmount, parseAdapterAction, parseAdapterDeployParams, parsePosNegAmount, pickStrategyTargetCollateral, rayToBps, rewardsFromTransfers, strategyName, swapFromTransfers, toNetTransfers, usdToNumber };
@@ -1,9 +1,9 @@
1
1
  import { Amount, TokenAmount } from "../../../model/primitives.js";
2
2
  import { PriceFeedData, PriceFeedSummary } from "../../../model/opportunities.js";
3
3
  import "../../../model/index.js";
4
+ import { AddressMap } from "../../utils/AddressMap.js";
4
5
  import { DelegatedMulticall } from "../../utils/viem/executeDelegatedMulticalls.js";
5
6
  import "../../utils/viem/index.js";
6
- import { AddressMap } from "../../utils/AddressMap.js";
7
7
  import { CreditAccountTokensSlice, PriceOracleData } from "../../base/types.js";
8
8
  import { PriceOracleStateHuman } from "../../types/state-human.js";
9
9
  import { IPriceFeedContract, PriceUpdate, UpdatePriceFeedsResult } from "../pricefeeds/types.js";
@@ -1,9 +1,9 @@
1
1
  import { Amount, TokenAmount } from "../../../model/primitives.js";
2
2
  import { PriceFeedData, PriceFeedSummary } from "../../../model/opportunities.js";
3
3
  import "../../../model/index.js";
4
+ import { AddressMap } from "../../utils/AddressMap.js";
4
5
  import { DelegatedMulticall } from "../../utils/viem/executeDelegatedMulticalls.js";
5
6
  import "../../utils/viem/index.js";
6
- import { AddressMap } from "../../utils/AddressMap.js";
7
7
  import { CreditAccountTokensSlice, IBaseContract } from "../../base/types.js";
8
8
  import { PriceOracleStateHuman } from "../../types/state-human.js";
9
9
  import { IPriceFeedContract, PriceUpdate, UpdatePriceFeedsResult } from "../pricefeeds/types.js";
@@ -0,0 +1,18 @@
1
+ import { Token } from "../../model/primitives.js";
2
+ import "../../model/index.js";
3
+ import { NetworkType } from "../chain/chains.js";
4
+ //#region src/sdk/market/strategyName.d.ts
5
+ /**
6
+ * Display name of a leveraged strategy: the target collateral over the
7
+ * borrowed underlying, e.g. `"wstETH / WETH"`.
8
+ *
9
+ * A curated pretty name from {@link getTokenPrettyName} wins over the target's
10
+ * ticker when one is configured.
11
+ *
12
+ * @param target - Collateral the position is built around.
13
+ * @param underlying - Token the position borrows.
14
+ * @param network - Chain id or network type label of the market.
15
+ **/
16
+ declare function strategyName(target: Token, underlying: Token, network: number | bigint | NetworkType): string;
17
+ //#endregion
18
+ export { strategyName };
@@ -33,8 +33,8 @@ declare class OpportunitiesService extends SDKConstruct {
33
33
  * A single strategy opportunity plus the rate curve of the pool it borrows
34
34
  * from and the price feeds its liquidation price depends on.
35
35
  *
36
- * @throws If the credit manager is unknown, or does not accept the requested
37
- * collateral as a strategy.
36
+ * @throws If the credit manager is unknown, or does not currently offer a
37
+ * strategy.
38
38
  **/
39
39
  getStrategy(key: StrategyOpportunityKey): Promise<StrategyOpportunityDetail>;
40
40
  }
@@ -1,6 +1,6 @@
1
- import { WithBlock } from "../types/multichain.js";
2
1
  import { PositionFilter } from "../../model/positions.js";
3
2
  import "../../model/index.js";
3
+ import { WithBlock } from "../types/multichain.js";
4
4
  import { Asset, CreditAccountData } from "../base/types.js";
5
5
  import "../types/index.js";
6
6
  import "../base/index.js";