@gearbox-protocol/sdk 17.12.2 → 17.13.0-next.10
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/dev/index.js +2 -0
- package/dist/cjs/dev/lowerHealthFactor.js +32 -0
- package/dist/cjs/dev/ltUtils.js +3 -2
- package/dist/cjs/model/analytics.schema.js +71 -7
- package/dist/cjs/model/errors/index.js +4 -0
- package/dist/cjs/model/errors/liquidation-errors.js +9 -0
- package/dist/cjs/model/errors/operation-errors.js +27 -0
- package/dist/cjs/model/index.js +9 -1
- package/dist/cjs/model/liquidations.schema.js +5 -3
- package/dist/cjs/model/opportunities.schema.js +1 -1
- package/dist/cjs/model/positions.schema.js +3 -0
- package/dist/cjs/offchain/analytics/OffchainAnalyticsPositions.js +8 -0
- package/dist/cjs/onchain/accounts/CreditAccountsServiceV310.js +0 -37
- package/dist/cjs/onchain/accounts/index.js +3 -0
- package/dist/cjs/onchain/accounts/intents/index.js +1 -0
- package/dist/cjs/onchain/accounts/intents/operations.js +1 -1
- package/dist/cjs/onchain/accounts/intents/plan.js +21 -0
- package/dist/cjs/onchain/accounts/intents/realize.js +29 -7
- package/dist/cjs/onchain/accounts/intents/resolveQuotaUpdate.js +149 -0
- package/dist/cjs/onchain/accounts/intents/testing/sdk-mock.js +1 -0
- package/dist/cjs/onchain/accounts/intents/tests/update-quota.fixtures.js +102 -0
- package/dist/cjs/onchain/accounts/intents/utils/index.js +1 -0
- package/dist/cjs/onchain/accounts/intents/utils/quotas-for-update.js +28 -10
- package/dist/cjs/onchain/accounts/liquidations/LiquidationsService.js +175 -5
- package/dist/cjs/onchain/accounts/liquidations/MultichainLiquidationsService.js +28 -0
- package/dist/cjs/onchain/accounts/liquidations/constants.js +1 -1
- package/dist/cjs/onchain/accounts/liquidations/index.js +3 -0
- package/dist/cjs/onchain/accounts/liquidations/partialLiquidation.js +70 -0
- package/dist/cjs/onchain/base/TokensMeta.js +15 -0
- package/dist/cjs/onchain/constants/index.js +1 -0
- package/dist/cjs/onchain/constants/math.js +6 -0
- package/dist/cjs/onchain/index.js +15 -1
- package/dist/cjs/onchain/market/credit/CreditSuite.js +0 -60
- package/dist/cjs/onchain/market/credit/collateralUtils.js +3 -2
- package/dist/cjs/onchain/market/index.js +1 -1
- package/dist/cjs/onchain/market/math.js +34 -12
- package/dist/cjs/onchain/pools/PoolService.js +1 -0
- package/dist/cjs/onchain/positions/PositionsService.js +1 -0
- package/dist/cjs/onchain/positions/calcHealthFactor.js +1 -1
- package/dist/cjs/onchain/preview/preview/CreditAccountState.js +4 -2
- package/dist/cjs/onchain/validation/bundles/checkCreditOperation.js +2 -0
- package/dist/cjs/onchain/validation/bundles/checkLiquidationEligibility.js +8 -1
- package/dist/cjs/onchain/validation/bundles/checkLiquidationFunding.js +2 -1
- package/dist/cjs/onchain/validation/bundles/checkQuotaUpdates.js +45 -0
- package/dist/cjs/onchain/validation/bundles/index.js +2 -0
- package/dist/cjs/onchain/validation/checkLiquidation.js +2 -1
- package/dist/cjs/onchain/validation/checks/checkMaxQuota.js +18 -0
- package/dist/cjs/onchain/validation/checks/checkPartiallyLiquidatable.js +13 -0
- package/dist/cjs/onchain/validation/checks/checkQuotaActive.js +10 -0
- package/dist/cjs/onchain/validation/checks/checkQuotaChange.js +18 -0
- package/dist/cjs/onchain/validation/checks/index.js +8 -0
- package/dist/cjs/onchain/validation/index.js +10 -0
- package/dist/cjs/sdk/liquidations/LiquidationsNamespace.js +14 -0
- package/dist/cjs/sdk/prepare/PrepareApi.js +67 -0
- package/dist/cjs/sdk/rewards/merkl-api.js +1 -1
- package/dist/cjs/sdk/rewards/turtle-api.js +1 -1
- package/dist/esm/dev/index.js +2 -1
- package/dist/esm/dev/lowerHealthFactor.js +31 -0
- package/dist/esm/dev/ltUtils.js +3 -2
- package/dist/esm/dev/mint/index.js +1 -2
- package/dist/esm/model/analytics.schema.js +69 -9
- package/dist/esm/model/errors/index.js +3 -3
- package/dist/esm/model/errors/liquidation-errors.js +9 -1
- package/dist/esm/model/errors/operation-errors.js +25 -1
- package/dist/esm/model/index.js +5 -5
- package/dist/esm/model/liquidations.schema.js +5 -3
- package/dist/esm/model/opportunities.schema.js +1 -1
- package/dist/esm/model/positions.schema.js +3 -0
- package/dist/esm/offchain/analytics/OffchainAnalyticsPositions.js +9 -1
- package/dist/esm/offchain/notices/index.js +1 -2
- package/dist/esm/offchain/opportunities/index.js +1 -2
- package/dist/esm/offchain/positions/index.js +1 -2
- package/dist/esm/onchain/abi/index.js +1 -2
- package/dist/esm/onchain/accounts/CreditAccountsServiceV310.js +0 -37
- package/dist/esm/onchain/accounts/index.js +2 -1
- package/dist/esm/onchain/accounts/intents/index.js +2 -1
- package/dist/esm/onchain/accounts/intents/operations.js +1 -1
- package/dist/esm/onchain/accounts/intents/plan.js +22 -2
- package/dist/esm/onchain/accounts/intents/realize.js +29 -7
- package/dist/esm/onchain/accounts/intents/resolveQuotaUpdate.js +148 -0
- package/dist/esm/onchain/accounts/intents/testing/sdk-mock.js +1 -0
- package/dist/esm/onchain/accounts/intents/tests/update-quota.fixtures.js +92 -0
- package/dist/esm/onchain/accounts/intents/utils/index.js +2 -2
- package/dist/esm/onchain/accounts/intents/utils/quotas-for-update.js +28 -11
- package/dist/esm/onchain/accounts/liquidations/LiquidationsService.js +175 -5
- package/dist/esm/onchain/accounts/liquidations/MultichainLiquidationsService.js +28 -0
- package/dist/esm/onchain/accounts/liquidations/constants.js +1 -1
- package/dist/esm/onchain/accounts/liquidations/index.js +2 -1
- package/dist/esm/onchain/accounts/liquidations/partialLiquidation.js +68 -0
- package/dist/esm/onchain/base/TokensMeta.js +15 -0
- package/dist/esm/onchain/constants/index.js +2 -2
- package/dist/esm/onchain/constants/math.js +6 -1
- package/dist/esm/onchain/index.js +9 -3
- package/dist/esm/onchain/market/adapters/abi/midas/index.js +1 -2
- package/dist/esm/onchain/market/credit/CreditSuite.js +2 -62
- package/dist/esm/onchain/market/credit/collateralUtils.js +3 -2
- package/dist/esm/onchain/market/index.js +2 -2
- package/dist/esm/onchain/market/math.js +34 -12
- package/dist/esm/onchain/pools/PoolService.js +1 -0
- package/dist/esm/onchain/pools/index.js +1 -2
- package/dist/esm/onchain/positions/PositionsService.js +1 -0
- package/dist/esm/onchain/positions/calcHealthFactor.js +1 -1
- package/dist/esm/onchain/preview/preview/CreditAccountState.js +4 -2
- package/dist/esm/onchain/utils/internal/index.js +1 -2
- package/dist/esm/onchain/validation/bundles/checkCreditOperation.js +2 -0
- package/dist/esm/onchain/validation/bundles/checkLiquidationEligibility.js +8 -1
- package/dist/esm/onchain/validation/bundles/checkLiquidationFunding.js +2 -1
- package/dist/esm/onchain/validation/bundles/checkQuotaUpdates.js +44 -0
- package/dist/esm/onchain/validation/bundles/index.js +2 -1
- package/dist/esm/onchain/validation/checkLiquidation.js +2 -1
- package/dist/esm/onchain/validation/checks/checkMaxQuota.js +17 -0
- package/dist/esm/onchain/validation/checks/checkPartiallyLiquidatable.js +12 -0
- package/dist/esm/onchain/validation/checks/checkQuotaActive.js +9 -0
- package/dist/esm/onchain/validation/checks/checkQuotaChange.js +17 -0
- package/dist/esm/onchain/validation/checks/index.js +5 -1
- package/dist/esm/onchain/validation/index.js +6 -1
- package/dist/esm/permissionless/api/chains/index.js +1 -2
- package/dist/esm/permissionless/api/oracles/index.js +1 -2
- package/dist/esm/permissionless/api/transactions/index.js +1 -2
- package/dist/esm/permissionless/bindings/router/index.js +1 -2
- package/dist/esm/permissionless/core/index.js +1 -2
- package/dist/esm/plugins/accounts/index.js +1 -2
- package/dist/esm/plugins/accounts-counter/index.js +1 -2
- package/dist/esm/plugins/bots/abi/index.js +1 -2
- package/dist/esm/sdk/analytics/index.js +1 -2
- package/dist/esm/sdk/execute/index.js +1 -2
- package/dist/esm/sdk/liquidations/LiquidationsNamespace.js +14 -0
- package/dist/esm/sdk/liquidations/index.js +1 -2
- package/dist/esm/sdk/opportunities/index.js +1 -2
- package/dist/esm/sdk/positions/index.js +1 -2
- package/dist/esm/sdk/prepare/PrepareApi.js +67 -0
- package/dist/esm/sdk/preview/index.js +1 -2
- package/dist/esm/sdk/rewards/merkl-api.js +1 -1
- package/dist/esm/sdk/rewards/turtle-api.js +1 -1
- package/dist/types/abi/310/configure/creditSuiteParams.d.ts +4 -5
- package/dist/types/abi/310/configure/iCreditConfigureActions.d.ts +2 -3
- package/dist/types/abi/310/configure/iPoolConfigureActions.d.ts +2 -3
- package/dist/types/abi/310/configure/iPriceOracleConfigureActions.d.ts +2 -3
- package/dist/types/abi/310/crossChainMultisig.d.ts +2 -3
- package/dist/types/abi/310/generated.d.ts +15 -16
- package/dist/types/abi/310/iBytecodeRepository.d.ts +2 -3
- package/dist/types/abi/310/iLinearInterestRateModelV310.d.ts +2 -3
- package/dist/types/abi/310/iMarketConfiguratorFactory.d.ts +2 -3
- package/dist/types/abi/310/iPriceFeedStore.d.ts +2 -3
- package/dist/types/abi/310/iTreasurySplitter.d.ts +2 -3
- package/dist/types/abi/310/instanceManager.d.ts +2 -3
- package/dist/types/abi/AccountMigrator.d.ts +2 -3
- package/dist/types/abi/ILiquidationCompressorV313.d.ts +2 -3
- package/dist/types/abi/IWithdrawalCompressorV310.d.ts +2 -3
- package/dist/types/abi/IWithdrawalCompressorV311.d.ts +2 -3
- package/dist/types/abi/IWithdrawalCompressorV313.d.ts +2 -3
- package/dist/types/abi/compressors/creditAccountCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/creditSuiteCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/defillamaCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/gaugeCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/liquidationCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/marketCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/peripheryCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/priceFeedCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/rewardsCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/rwaCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/liquidation/midasLiquidationSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/liquidation/securitizeLiquidationSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/rwa/onDemandRWAUnderlyingSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/rwa/securitizeRWAFactorySubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/withdrawal/infinifiWithdrawalSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/withdrawal/kelpLRTWithdrawalSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/withdrawal/mellowFlexibleDepositSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/withdrawal/mellowFlexibleRedeemSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/withdrawal/mellowWithdrawalSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/withdrawal/midasWithdrawalSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/withdrawal/securitizeRedemptionSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/subcompressors/withdrawal/upshiftWithdrawalSubcompressor.d.ts +2 -3
- package/dist/types/abi/compressors/tokenCompressor.d.ts +2 -3
- package/dist/types/abi/compressors/withdrawalCompressor.d.ts +2 -3
- package/dist/types/abi/errors.d.ts +11 -12
- package/dist/types/abi/governance/batchesChain.d.ts +2 -3
- package/dist/types/abi/governance/governor.d.ts +2 -3
- package/dist/types/abi/governance/iTimeLock.d.ts +2 -3
- package/dist/types/abi/helpers/redemptionLogger.d.ts +2 -3
- package/dist/types/abi/iAirdropDistributor.d.ts +2 -3
- package/dist/types/abi/iBaseRewardPool.d.ts +2 -3
- package/dist/types/abi/iCurvePool.d.ts +2 -3
- package/dist/types/abi/iDefaultAccountFactoryV3.d.ts +2 -3
- package/dist/types/abi/iDegenNFTV2.d.ts +2 -3
- package/dist/types/abi/iERC20.d.ts +2 -3
- package/dist/types/abi/iERC20Permit.d.ts +2 -3
- package/dist/types/abi/iERC20Zapper.d.ts +2 -3
- package/dist/types/abi/iERC20ZapperDeposits.d.ts +2 -3
- package/dist/types/abi/iETHZapper.d.ts +2 -3
- package/dist/types/abi/iETHZapperDeposits.d.ts +2 -3
- package/dist/types/abi/iExpirable.d.ts +2 -3
- package/dist/types/abi/iFarmingPool.d.ts +2 -3
- package/dist/types/abi/iInterestRateModel.d.ts +2 -3
- package/dist/types/abi/iMulticall3.d.ts +2 -3
- package/dist/types/abi/iOffchainOracle.d.ts +2 -3
- package/dist/types/abi/iPausable.d.ts +2 -3
- package/dist/types/abi/iPhantomToken.d.ts +2 -3
- package/dist/types/abi/iPriceFeed.d.ts +2 -3
- package/dist/types/abi/iRedemptionLoggerV310.d.ts +2 -3
- package/dist/types/abi/iStateSerializer.d.ts +2 -3
- package/dist/types/abi/iUpdatablePriceFeed.d.ts +2 -3
- package/dist/types/abi/iVersion.d.ts +2 -3
- package/dist/types/abi/iZapper.d.ts +2 -3
- package/dist/types/abi/ierc4626Adapter.d.ts +2 -3
- package/dist/types/abi/mellow.d.ts +6 -7
- package/dist/types/abi/migration.d.ts +3 -4
- package/dist/types/abi/router/balancerV2Worker.d.ts +2 -3
- package/dist/types/abi/router/balancerV3Worker.d.ts +2 -3
- package/dist/types/abi/router/balancerV3WrapperWorker.d.ts +2 -3
- package/dist/types/abi/router/camelotV3Worker.d.ts +2 -3
- package/dist/types/abi/router/convexWorker.d.ts +2 -3
- package/dist/types/abi/router/curveWorker.d.ts +2 -3
- package/dist/types/abi/router/daiUsdsWorker.d.ts +2 -3
- package/dist/types/abi/router/equalizerRouterWorker.d.ts +2 -3
- package/dist/types/abi/router/erc4626Worker.d.ts +2 -3
- package/dist/types/abi/router/fluidDexWorker.d.ts +2 -3
- package/dist/types/abi/router/gearboxRouter.d.ts +2 -3
- package/dist/types/abi/router/infinifiWorker.d.ts +2 -3
- package/dist/types/abi/router/infraredVaultWorker.d.ts +2 -3
- package/dist/types/abi/router/kelpLRTDepositPoolWorker.d.ts +2 -3
- package/dist/types/abi/router/kodiakWorker.d.ts +2 -3
- package/dist/types/abi/router/lidoWorker.d.ts +2 -3
- package/dist/types/abi/router/mellow4626Worker.d.ts +2 -3
- package/dist/types/abi/router/mellowDVVWorker.d.ts +2 -3
- package/dist/types/abi/router/mellowVaultWorker.d.ts +2 -3
- package/dist/types/abi/router/midasWorker.d.ts +2 -3
- package/dist/types/abi/router/pendleRouterWorker.d.ts +2 -3
- package/dist/types/abi/router/routingManager.d.ts +2 -3
- package/dist/types/abi/router/securitizeOnrampWorker.d.ts +2 -3
- package/dist/types/abi/router/stakingRewardsWorker.d.ts +2 -3
- package/dist/types/abi/router/traderJoeWorker.d.ts +2 -3
- package/dist/types/abi/router/uniswapV2Worker.d.ts +2 -3
- package/dist/types/abi/router/uniswapV3Worker.d.ts +2 -3
- package/dist/types/abi/router/uniswapV4Worker.d.ts +2 -3
- package/dist/types/abi/router/upshiftWorker.d.ts +2 -3
- package/dist/types/abi/router/velodromeV2Worker.d.ts +2 -3
- package/dist/types/abi/router/wstETHWorker.d.ts +2 -3
- package/dist/types/abi/router/yearnV2Worker.d.ts +2 -3
- package/dist/types/abi/rwa/iDSRegistryService.d.ts +2 -3
- package/dist/types/abi/rwa/iDSToken.d.ts +2 -3
- package/dist/types/abi/rwa/iMidasAccessControl.d.ts +2 -3
- package/dist/types/abi/rwa/iMidasDegenNFT.d.ts +2 -3
- package/dist/types/abi/rwa/iMidasLiquidatorV311.d.ts +2 -3
- package/dist/types/abi/rwa/iRWACompressor.d.ts +2 -3
- package/dist/types/abi/rwa/iRWAFactory.d.ts +2 -3
- package/dist/types/abi/rwa/iRWAGateway.d.ts +2 -3
- package/dist/types/abi/rwa/iRWAUnderlying.d.ts +2 -3
- package/dist/types/abi/rwa/iSecuritizeDegenNFT.d.ts +2 -3
- package/dist/types/abi/rwa/iSecuritizeLiquidatorV311.d.ts +2 -3
- package/dist/types/abi/rwa/iSecuritizeRWAFactory.d.ts +2 -3
- package/dist/types/dev/AccountOpener.d.ts +9 -9
- package/dist/types/dev/EthCallSpy.d.ts +6 -7
- package/dist/types/dev/RevolverTransport.d.ts +12 -12
- package/dist/types/dev/abi.d.ts +6 -7
- package/dist/types/dev/calcLiquidatableLTs.d.ts +2 -3
- package/dist/types/dev/claimFromFaucet.d.ts +2 -2
- package/dist/types/dev/create2.d.ts +10 -11
- package/dist/types/dev/createAnvilClient.d.ts +13 -14
- package/dist/types/dev/detectChain.d.ts +2 -3
- package/dist/types/dev/index.d.ts +2 -1
- package/dist/types/dev/isOutOfSyncError.d.ts +2 -3
- package/dist/types/dev/isRateLimitError.d.ts +2 -3
- package/dist/types/dev/isTransientError.d.ts +2 -3
- package/dist/types/dev/kycUtils.d.ts +13 -14
- package/dist/types/dev/logSplitterTransport.d.ts +10 -10
- package/dist/types/dev/lowerHealthFactor.d.ts +34 -0
- package/dist/types/dev/ltUtils.d.ts +3 -4
- package/dist/types/dev/midasUtils.d.ts +8 -9
- package/dist/types/dev/migrateFaucet.d.ts +2 -3
- package/dist/types/dev/mint/AbstractMinter.d.ts +2 -3
- package/dist/types/dev/mint/DealMinter.d.ts +2 -3
- package/dist/types/dev/mint/DirectMinter.d.ts +2 -3
- package/dist/types/dev/mint/FallbackMinter.d.ts +2 -3
- package/dist/types/dev/mint/TransferMinter.d.ts +2 -3
- package/dist/types/dev/mint/factory.d.ts +2 -3
- package/dist/types/dev/mint/types.d.ts +2 -3
- package/dist/types/dev/mode-parity/compareOpportunities.d.ts +8 -8
- package/dist/types/dev/mode-parity/comparePositions.d.ts +12 -13
- package/dist/types/dev/mode-parity/compareRules.d.ts +6 -7
- package/dist/types/dev/mode-parity/fieldDiff.d.ts +29 -30
- package/dist/types/dev/mode-parity/scriptUtils.d.ts +18 -19
- package/dist/types/dev/providers.d.ts +10 -11
- package/dist/types/dev/replaceStorage.d.ts +3 -4
- package/dist/types/dev/resilientTransport.d.ts +6 -7
- package/dist/types/dev/securitizeUtils.d.ts +6 -6
- package/dist/types/dev/transports.d.ts +2 -3
- package/dist/types/dev/types.d.ts +4 -5
- package/dist/types/dev/verifyTestnet.d.ts +4 -5
- package/dist/types/dev/withdrawalAbi.d.ts +9 -10
- package/dist/types/dev/withdrawalUtils.d.ts +3 -4
- package/dist/types/history/assembleOperations.d.ts +3 -4
- package/dist/types/history/classifyMulticallOperations.d.ts +3 -4
- package/dist/types/history/mapOperations.d.ts +3 -4
- package/dist/types/history/parseCreditAccountTransaction.d.ts +3 -4
- package/dist/types/history/populateContractsRegister.d.ts +4 -5
- package/dist/types/history/toLegacyOperation.d.ts +6 -7
- package/dist/types/history/trace/errors.d.ts +6 -7
- package/dist/types/history/trace/extractAdapterCallTraces.d.ts +2 -3
- package/dist/types/history/trace/extractTransfers.d.ts +4 -4
- package/dist/types/history/trace/findFacadeCalls.d.ts +2 -3
- package/dist/types/history/trace/types.d.ts +3 -4
- package/dist/types/history/types.d.ts +13 -13
- package/dist/types/model/analytics.d.ts +66 -13
- package/dist/types/model/analytics.schema.d.ts +182 -39
- package/dist/types/model/charts.d.ts +29 -29
- package/dist/types/model/charts.schema.d.ts +16 -17
- package/dist/types/model/compare.schema.d.ts +9 -10
- package/dist/types/model/curators.d.ts +3 -4
- package/dist/types/model/curators.schema.d.ts +3 -4
- package/dist/types/model/delayed-intent.schema.d.ts +2 -3
- package/dist/types/model/delayed-intents.d.ts +9 -10
- package/dist/types/model/errors/base.d.ts +2 -3
- package/dist/types/model/errors/index.d.ts +3 -3
- package/dist/types/model/errors/liquidation-errors.d.ts +20 -8
- package/dist/types/model/errors/operation-errors.d.ts +76 -39
- package/dist/types/model/errors/oracle-errors.d.ts +3 -4
- package/dist/types/model/errors/prepare-errors.d.ts +21 -22
- package/dist/types/model/errors/preview-errors.d.ts +9 -10
- package/dist/types/model/filters.d.ts +6 -7
- package/dist/types/model/filters.schema.d.ts +5 -6
- package/dist/types/model/index.d.ts +6 -6
- package/dist/types/model/liquidations.d.ts +37 -18
- package/dist/types/model/liquidations.schema.d.ts +12 -10
- package/dist/types/model/notices.d.ts +4 -5
- package/dist/types/model/notices.schema.d.ts +3 -4
- package/dist/types/model/opportunities.d.ts +32 -33
- package/dist/types/model/opportunities.schema.d.ts +26 -27
- package/dist/types/model/positions.d.ts +34 -30
- package/dist/types/model/positions.schema.d.ts +102 -23
- package/dist/types/model/previews.d.ts +21 -21
- package/dist/types/model/primitives.d.ts +12 -13
- package/dist/types/model/primitives.schema.d.ts +11 -12
- package/dist/types/model/response.d.ts +8 -9
- package/dist/types/model/response.schema.d.ts +7 -8
- package/dist/types/model/result.d.ts +8 -9
- package/dist/types/model/rewards.d.ts +4 -5
- package/dist/types/model/rwa.d.ts +20 -21
- package/dist/types/model/rwa.schema.d.ts +3 -4
- package/dist/types/model/withdrawals.d.ts +5 -6
- package/dist/types/model/withdrawals.schema.d.ts +5 -6
- package/dist/types/offchain/AbstractOffchainNamespace.d.ts +4 -5
- package/dist/types/offchain/GearboxAPI.d.ts +2 -3
- package/dist/types/offchain/analytics/OffchainAnalytics.d.ts +2 -3
- package/dist/types/offchain/analytics/OffchainAnalyticsPositions.d.ts +6 -4
- package/dist/types/offchain/analytics/types.d.ts +17 -5
- package/dist/types/offchain/errors/OffchainInvalidJsonError.d.ts +2 -3
- package/dist/types/offchain/errors/OffchainNotConfiguredError.d.ts +2 -3
- package/dist/types/offchain/errors/OffchainNotImplementedError.d.ts +2 -3
- package/dist/types/offchain/errors/OffchainRequestFailedError.d.ts +2 -3
- package/dist/types/offchain/errors/OffchainStatusError.d.ts +2 -3
- package/dist/types/offchain/errors/OffchainTransportError.d.ts +3 -4
- package/dist/types/offchain/errors/OffchainValidationError.d.ts +2 -3
- package/dist/types/offchain/errors/backendMessage.d.ts +2 -3
- package/dist/types/offchain/errors/errorCause.d.ts +3 -4
- package/dist/types/offchain/errors/readResponseBody.d.ts +2 -3
- package/dist/types/offchain/notices/OffchainNotices.d.ts +2 -3
- package/dist/types/offchain/opportunities/OffchainOpportunities.d.ts +2 -3
- package/dist/types/offchain/opportunities/types.d.ts +3 -4
- package/dist/types/offchain/positions/OffchainPositions.d.ts +2 -3
- package/dist/types/offchain/positions/types.d.ts +3 -4
- package/dist/types/offchain/types.d.ts +2 -3
- package/dist/types/onchain/MultichainSDK.d.ts +7 -8
- package/dist/types/onchain/OnchainSDK.d.ts +8 -9
- package/dist/types/onchain/abi/oracles.d.ts +27 -28
- package/dist/types/onchain/accounts/CreditAccountsServiceV310.d.ts +3 -12
- package/dist/types/onchain/accounts/bots/AccountBotsService.d.ts +2 -3
- package/dist/types/onchain/accounts/bots/PeripheryCompressorV310Contract.d.ts +2 -2
- package/dist/types/onchain/accounts/bots/abi.d.ts +2 -3
- package/dist/types/onchain/accounts/bots/types.d.ts +13 -14
- package/dist/types/onchain/accounts/credit-account-compressor/CreditAccountCompressor.d.ts +2 -3
- package/dist/types/onchain/accounts/credit-account-compressor/CreditAccountCompressorV310Contract.d.ts +2 -2
- package/dist/types/onchain/accounts/credit-account-compressor/types.d.ts +11 -12
- package/dist/types/onchain/accounts/index.d.ts +5 -4
- package/dist/types/onchain/accounts/intents/borrow.d.ts +6 -7
- package/dist/types/onchain/accounts/intents/collateral-valuation.d.ts +4 -5
- package/dist/types/onchain/accounts/intents/guards.d.ts +7 -7
- package/dist/types/onchain/accounts/intents/index.d.ts +6 -6
- package/dist/types/onchain/accounts/intents/leverage-band.d.ts +4 -5
- package/dist/types/onchain/accounts/intents/math.d.ts +8 -8
- package/dist/types/onchain/accounts/intents/maxBorrow.d.ts +3 -4
- package/dist/types/onchain/accounts/intents/maxWithdrawCollateral.d.ts +3 -4
- package/dist/types/onchain/accounts/intents/open-strategy.d.ts +4 -5
- package/dist/types/onchain/accounts/intents/operations.d.ts +34 -28
- package/dist/types/onchain/accounts/intents/plan.d.ts +35 -19
- package/dist/types/onchain/accounts/intents/realize.d.ts +4 -5
- package/dist/types/onchain/accounts/intents/resolveQuotaUpdate.d.ts +38 -0
- package/dist/types/onchain/accounts/intents/strategyLimits.d.ts +2 -2
- package/dist/types/onchain/accounts/intents/tail.d.ts +4 -4
- package/dist/types/onchain/accounts/intents/testing/delayed.d.ts +2 -2
- package/dist/types/onchain/accounts/intents/testing/expect.d.ts +2 -2
- package/dist/types/onchain/accounts/intents/testing/market.d.ts +6 -6
- package/dist/types/onchain/accounts/intents/testing/sdk-mock.d.ts +3 -3
- package/dist/types/onchain/accounts/intents/tests/add-collateral.fixtures.d.ts +15 -16
- package/dist/types/onchain/accounts/intents/tests/adjust-leverage.fixtures.d.ts +22 -23
- package/dist/types/onchain/accounts/intents/tests/deposit.fixtures.d.ts +24 -25
- package/dist/types/onchain/accounts/intents/tests/finish-decrease-leverage.fixtures.d.ts +21 -21
- package/dist/types/onchain/accounts/intents/tests/finish-withdraw.fixtures.d.ts +30 -31
- package/dist/types/onchain/accounts/intents/tests/open-strategy.fixtures.d.ts +16 -17
- package/dist/types/onchain/accounts/intents/tests/update-quota.fixtures.d.ts +48 -0
- package/dist/types/onchain/accounts/intents/tests/withdraw-asset.fixtures.d.ts +16 -17
- package/dist/types/onchain/accounts/intents/tests/withdraw.fixtures.d.ts +26 -27
- package/dist/types/onchain/accounts/intents/types.d.ts +46 -30
- package/dist/types/onchain/accounts/intents/utils/adjust-state-to-snapshot.d.ts +2 -3
- package/dist/types/onchain/accounts/intents/utils/assemble-operation-calls.d.ts +2 -2
- package/dist/types/onchain/accounts/intents/utils/borrowed-amount-plus-interest-and-fees.d.ts +2 -3
- package/dist/types/onchain/accounts/intents/utils/common.d.ts +5 -6
- package/dist/types/onchain/accounts/intents/utils/credit-account-slice.d.ts +4 -5
- package/dist/types/onchain/accounts/intents/utils/index.d.ts +2 -2
- package/dist/types/onchain/accounts/intents/utils/ledger.d.ts +3 -4
- package/dist/types/onchain/accounts/intents/utils/pick-token.d.ts +6 -7
- package/dist/types/onchain/accounts/intents/utils/price-impact.d.ts +5 -6
- package/dist/types/onchain/accounts/intents/utils/quotas-for-update.d.ts +27 -9
- package/dist/types/onchain/accounts/intents/utils/router-path.d.ts +6 -7
- package/dist/types/onchain/accounts/intents/view.d.ts +2 -3
- package/dist/types/onchain/accounts/intents/withdraw-limits.d.ts +5 -6
- package/dist/types/onchain/accounts/liquidations/LiquidationsService.d.ts +50 -4
- package/dist/types/onchain/accounts/liquidations/MultichainLiquidationsService.d.ts +13 -4
- package/dist/types/onchain/accounts/liquidations/constants.d.ts +4 -5
- package/dist/types/onchain/accounts/liquidations/index.d.ts +3 -2
- package/dist/types/onchain/accounts/liquidations/partialLiquidation.d.ts +88 -0
- package/dist/types/onchain/accounts/liquidations/skipLiquidatableAccount.d.ts +2 -3
- package/dist/types/onchain/accounts/liquidations/types.d.ts +146 -21
- package/dist/types/onchain/accounts/multicall-utils.d.ts +4 -5
- package/dist/types/onchain/accounts/quota-utils.d.ts +11 -11
- package/dist/types/onchain/accounts/types.d.ts +18 -95
- package/dist/types/onchain/accounts/withdrawal-compressor/AbstractWithdrawalCompressorContract.d.ts +7 -7
- package/dist/types/onchain/accounts/withdrawal-compressor/RedemptionLoggerV310Contract.d.ts +2 -2
- package/dist/types/onchain/accounts/withdrawal-compressor/WithdrawalCompressorV310Contract.d.ts +2 -2
- package/dist/types/onchain/accounts/withdrawal-compressor/WithdrawalCompressorV311Contract.d.ts +2 -2
- package/dist/types/onchain/accounts/withdrawal-compressor/WithdrawalCompressorV313Contract.d.ts +2 -2
- package/dist/types/onchain/accounts/withdrawal-compressor/addresses.d.ts +4 -5
- package/dist/types/onchain/accounts/withdrawal-compressor/createRedemptionLogger.d.ts +2 -3
- package/dist/types/onchain/accounts/withdrawal-compressor/createWithdrawalCompressor.d.ts +2 -3
- package/dist/types/onchain/accounts/withdrawal-compressor/intent-codec.d.ts +5 -6
- package/dist/types/onchain/accounts/withdrawal-compressor/types.d.ts +16 -17
- package/dist/types/onchain/base/BaseContract.d.ts +5 -6
- package/dist/types/onchain/base/ChainContractsRegister.d.ts +3 -4
- package/dist/types/onchain/base/Construct.d.ts +3 -4
- package/dist/types/onchain/base/MultichainConstruct.d.ts +7 -8
- package/dist/types/onchain/base/SDKConstruct.d.ts +2 -3
- package/dist/types/onchain/base/TokensMeta.d.ts +13 -6
- package/dist/types/onchain/base/errors.d.ts +2 -3
- package/dist/types/onchain/base/token-types.d.ts +18 -18
- package/dist/types/onchain/base/types.d.ts +37 -38
- package/dist/types/onchain/chain/chains.d.ts +20 -21
- package/dist/types/onchain/chain/detectNetwork.d.ts +2 -3
- package/dist/types/onchain/constants/address-provider.d.ts +36 -37
- package/dist/types/onchain/constants/addresses.d.ts +5 -6
- package/dist/types/onchain/constants/bot-permissions.d.ts +3 -4
- package/dist/types/onchain/constants/index.d.ts +2 -2
- package/dist/types/onchain/constants/math.d.ts +25 -21
- package/dist/types/onchain/constants/networks.d.ts +3 -4
- package/dist/types/onchain/constants/periphery.d.ts +3 -4
- package/dist/types/onchain/constants/versions.d.ts +5 -6
- package/dist/types/onchain/core/AbstractAddressProviderContract.d.ts +2 -3
- package/dist/types/onchain/core/AddressProviderV310Contract.d.ts +2 -2
- package/dist/types/onchain/core/createAddressProvider.d.ts +3 -4
- package/dist/types/onchain/core/errors.d.ts +9 -10
- package/dist/types/onchain/core/types.d.ts +4 -5
- package/dist/types/onchain/index.d.ts +13 -7
- package/dist/types/onchain/market/MarketConfiguratorContract.d.ts +2 -2
- package/dist/types/onchain/market/MarketRegister.d.ts +4 -5
- package/dist/types/onchain/market/MarketSuite.d.ts +2 -3
- package/dist/types/onchain/market/ZapperRegister.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/actionAbi.d.ts +4 -5
- package/dist/types/onchain/market/adapters/abi/adapters/erc4626ReferralAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iBalancerV3RouterAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iBalancerV3WrapperAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iCamelotV3Adapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iConvexV1BaseRewardPoolAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iConvexV1BoosterAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iCurveV1StableNgAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iCurveV1_2AssetsAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iCurveV1_3AssetsAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iCurveV1_4AssetsAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iDaiUsdsAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iFluidDexAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iInfinifiGatewayAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iInfinifiUnwindingGateway.d.ts +3 -4
- package/dist/types/onchain/market/adapters/abi/adapters/iKelpLrtDepositPool.d.ts +3 -4
- package/dist/types/onchain/market/adapters/abi/adapters/iKelpLrtWithdrawalManager.d.ts +3 -4
- package/dist/types/onchain/market/adapters/abi/adapters/iLidoV1Adapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iMellow4626VaultAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iMellowClaimerAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iMellowWrapperAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iMidasGatewayAdapterV311.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iMidasIssuanceVaultAdapterV310.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iMidasRedemptionVaultAdapterV310.d.ts +3 -4
- package/dist/types/onchain/market/adapters/abi/adapters/iPendleRouterAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iSecuritizeOnRampAdapterV310.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iSecuritizeRedemptionGatewayAdapterV311.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iStakingRewardsAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iTraderJoeRouterAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iUniswapV2Adapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iUniswapV3Adapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iUniswapV4Adapter.d.ts +3 -4
- package/dist/types/onchain/market/adapters/abi/adapters/iUpshiftVaultAdapter.d.ts +3 -4
- package/dist/types/onchain/market/adapters/abi/adapters/iVelodromeV2RouterAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/iwstEthv1Adapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/adapters/mellowDvvAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/conctructorAbi.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/conctructorAbiPatterns.d.ts +12 -13
- package/dist/types/onchain/market/adapters/abi/midas/iMidasGatewayV311.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/securitize/iBaseOnRamp.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/securitize/iSecuritizeOnRamp.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/securitize/iSecuritizeRedemptionGatewayV311.d.ts +2 -3
- package/dist/types/onchain/market/adapters/abi/targetContractAbi.d.ts +29 -30
- package/dist/types/onchain/market/adapters/abi/utils.d.ts +7 -8
- package/dist/types/onchain/market/adapters/contracts/AbstractAdapter.d.ts +4 -5
- package/dist/types/onchain/market/adapters/contracts/AbstractCurveAdapter.d.ts +2 -3
- package/dist/types/onchain/market/adapters/contracts/AccountMigratorAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/BalancerV3RouterAdapterContract.d.ts +4 -4
- package/dist/types/onchain/market/adapters/contracts/BalancerV3WrapperAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/CamelotV3AdapterContract.d.ts +3 -3
- package/dist/types/onchain/market/adapters/contracts/ConvexV1BaseRewardPoolAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/ConvexV1BoosterAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/Curve2AssetsAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/Curve3AssetsAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/Curve4AssetsAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/CurveV1AdapterStETHContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/CurveV1StableNGAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/DaiUsdsAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/ERC4626AdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/ERC4626ReferralAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/FluidDexAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/InfinifiGatewayAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/InfinifiUnwindingGatewayAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/KelpLRTDepositPoolAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/KelpLRTWithdrawalManagerAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/LidoV1AdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/MellowClaimerAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/MellowDVVAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/MellowERC4626VaultAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/MellowWrapperAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/MidasGatewayAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/MidasIssuanceVaultAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/MidasRedemptionVaultAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/PendleRouterAdapterContract.d.ts +5 -5
- package/dist/types/onchain/market/adapters/contracts/SecuritizeOnRampAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/SecuritizeRedemptionGatewayAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/StakingRewardsAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/TraderJoeRouterAdapterContract.d.ts +4 -4
- package/dist/types/onchain/market/adapters/contracts/UniswapV2AdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/UniswapV3AdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/UniswapV4AdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/UpshiftVaultAdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/VelodromeV2AdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/contracts/WstETHV1AdapterContract.d.ts +2 -2
- package/dist/types/onchain/market/adapters/createAdapter.d.ts +3 -4
- package/dist/types/onchain/market/adapters/legacyAdapterOperations.d.ts +27 -28
- package/dist/types/onchain/market/adapters/transferHelpers.d.ts +10 -11
- package/dist/types/onchain/market/adapters/transfers.d.ts +2 -3
- package/dist/types/onchain/market/adapters/types.d.ts +9 -10
- package/dist/types/onchain/market/credit/CreditConfiguratorV310Contract.d.ts +3 -3
- package/dist/types/onchain/market/credit/CreditFacadeV310BaseContract.d.ts +2 -2
- package/dist/types/onchain/market/credit/CreditFacadeV310Contract.d.ts +3 -3
- package/dist/types/onchain/market/credit/CreditManagerV310Contract.d.ts +3 -3
- package/dist/types/onchain/market/credit/CreditSuite.d.ts +3 -14
- package/dist/types/onchain/market/credit/CreditSuiteStrategy.d.ts +2 -3
- package/dist/types/onchain/market/credit/collateralUtils.d.ts +6 -6
- package/dist/types/onchain/market/credit/createCreditConfigurator.d.ts +2 -3
- package/dist/types/onchain/market/credit/createCreditFacade.d.ts +2 -3
- package/dist/types/onchain/market/credit/createCreditManager.d.ts +2 -3
- package/dist/types/onchain/market/credit/expectedBalanceDeltas.d.ts +4 -5
- package/dist/types/onchain/market/credit/index.d.ts +2 -2
- package/dist/types/onchain/market/credit/types.d.ts +10 -46
- package/dist/types/onchain/market/index.d.ts +3 -3
- package/dist/types/onchain/market/loss-policy/AliasLossPolicyV310Contract.d.ts +3 -3
- package/dist/types/onchain/market/loss-policy/LossPolicyContract.d.ts +2 -2
- package/dist/types/onchain/market/loss-policy/constants.d.ts +5 -6
- package/dist/types/onchain/market/loss-policy/createLossPolicy.d.ts +2 -3
- package/dist/types/onchain/market/loss-policy/types.d.ts +2 -3
- package/dist/types/onchain/market/math.d.ts +48 -30
- package/dist/types/onchain/market/oracle/PriceFeedAnswerMap.d.ts +2 -3
- package/dist/types/onchain/market/oracle/PriceOracleBaseContract.d.ts +2 -3
- package/dist/types/onchain/market/oracle/PriceOracleV310Contract.d.ts +2 -2
- package/dist/types/onchain/market/oracle/collateralPriceInUnderlying.d.ts +2 -3
- package/dist/types/onchain/market/oracle/createPriceOracle.d.ts +2 -3
- package/dist/types/onchain/market/oracle/types.d.ts +5 -6
- package/dist/types/onchain/market/pool/GaugeContract.d.ts +3 -3
- package/dist/types/onchain/market/pool/LinearInterestRateModelContract.d.ts +2 -2
- package/dist/types/onchain/market/pool/PoolQuotaKeeperV310Contract.d.ts +2 -2
- package/dist/types/onchain/market/pool/PoolSuite.d.ts +2 -3
- package/dist/types/onchain/market/pool/PoolV310Contract.d.ts +3 -3
- package/dist/types/onchain/market/pool/TumblerContract.d.ts +2 -2
- package/dist/types/onchain/market/pool/createInterestRateModel.d.ts +2 -3
- package/dist/types/onchain/market/pool/createPool.d.ts +2 -3
- package/dist/types/onchain/market/pool/createPoolQuotaKeeper.d.ts +2 -3
- package/dist/types/onchain/market/pool/createRateKeeper.d.ts +2 -3
- package/dist/types/onchain/market/pool/math.d.ts +6 -7
- package/dist/types/onchain/market/pool/types.d.ts +7 -8
- package/dist/types/onchain/market/pricefeeds/AbstractLPPriceFeed.d.ts +3 -4
- package/dist/types/onchain/market/pricefeeds/AbstractPriceFeed.d.ts +5 -6
- package/dist/types/onchain/market/pricefeeds/PriceFeedRef.d.ts +2 -3
- package/dist/types/onchain/market/pricefeeds/PriceFeedRegistry.d.ts +2 -3
- package/dist/types/onchain/market/pricefeeds/feeds/BalancerStablePriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/BalancerWeightedPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/BoundedPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/CompositePriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/ConstantPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/CurveCryptoPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/CurveStablePriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/CurveUSDPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/Erc4626PriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/ExternalPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/MellowLRTPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/PendleTWAPPTPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/PythPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/RedstonePriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/WstETHPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/YearnPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/feeds/ZeroPriceFeed.d.ts +2 -2
- package/dist/types/onchain/market/pricefeeds/types.d.ts +5 -6
- package/dist/types/onchain/market/pricefeeds/updates/PriceUpdateTx.d.ts +2 -3
- package/dist/types/onchain/market/pricefeeds/updates/PriceUpdatesCache.d.ts +3 -4
- package/dist/types/onchain/market/pricefeeds/updates/UpdatablePriceFeedRegistry.d.ts +2 -3
- package/dist/types/onchain/market/pricefeeds/updates/getRawPriceUpdates.d.ts +2 -3
- package/dist/types/onchain/market/pricefeeds/updates/isUpdatablePriceFeed.d.ts +2 -3
- package/dist/types/onchain/market/pricefeeds/updates/types.d.ts +8 -9
- package/dist/types/onchain/market/pricefeeds/updates/updatableDependencies.d.ts +2 -3
- package/dist/types/onchain/market/rwa/RWARegistry.d.ts +3 -4
- package/dist/types/onchain/market/rwa/createDegenNFT.d.ts +2 -3
- package/dist/types/onchain/market/rwa/midas/MidasDegenNFT.d.ts +2 -2
- package/dist/types/onchain/market/rwa/midas/MidasLiquidatorContract.d.ts +2 -2
- package/dist/types/onchain/market/rwa/midas/constants.d.ts +4 -5
- package/dist/types/onchain/market/rwa/securitize/SecuritizeDegenNFT.d.ts +2 -2
- package/dist/types/onchain/market/rwa/securitize/SecuritizeLiquidatorContract.d.ts +2 -2
- package/dist/types/onchain/market/rwa/securitize/SecuritizeRWAFactory.d.ts +2 -2
- package/dist/types/onchain/market/rwa/securitize/constants.d.ts +4 -5
- package/dist/types/onchain/market/rwa/securitize/types.d.ts +5 -6
- package/dist/types/onchain/market/rwa/types.d.ts +16 -16
- package/dist/types/onchain/market/strategyName.d.ts +2 -3
- package/dist/types/onchain/market/types.d.ts +3 -4
- package/dist/types/onchain/market/zapper/IERC20ZapperContract.d.ts +2 -2
- package/dist/types/onchain/market/zapper/IETHZapperContract.d.ts +2 -2
- package/dist/types/onchain/market/zapper/ZapperContract.d.ts +2 -3
- package/dist/types/onchain/market/zapper/createZapper.d.ts +2 -3
- package/dist/types/onchain/market/zapper/types.d.ts +5 -6
- package/dist/types/onchain/opportunities/MultichainOpportunitiesService.d.ts +2 -3
- package/dist/types/onchain/opportunities/OpportunitiesService.d.ts +2 -3
- package/dist/types/onchain/opportunities/types.d.ts +2 -3
- package/dist/types/onchain/options.d.ts +4 -5
- package/dist/types/onchain/plugins/BasePlugin.d.ts +2 -3
- package/dist/types/onchain/plugins/errors.d.ts +2 -3
- package/dist/types/onchain/plugins/types.d.ts +9 -10
- package/dist/types/onchain/pools/PoolService.d.ts +2 -3
- package/dist/types/onchain/pools/types.d.ts +12 -13
- package/dist/types/onchain/positions/MultichainPositionsService.d.ts +2 -3
- package/dist/types/onchain/positions/PositionsService.d.ts +3 -4
- package/dist/types/onchain/positions/calcBorrowRate.d.ts +3 -4
- package/dist/types/onchain/positions/calcHealthFactor.d.ts +3 -4
- package/dist/types/onchain/positions/calcLiquidationPrice.d.ts +3 -4
- package/dist/types/onchain/positions/calcLiquidationPriceForTarget.d.ts +4 -5
- package/dist/types/onchain/positions/calcTimeToLiquidationMs.d.ts +2 -3
- package/dist/types/onchain/positions/types.d.ts +9 -10
- package/dist/types/onchain/preview/parse/classifyInnerOperations.d.ts +3 -4
- package/dist/types/onchain/preview/parse/parseFacadeOperationCalldata.d.ts +2 -3
- package/dist/types/onchain/preview/parse/parseOperationCalldata.d.ts +2 -3
- package/dist/types/onchain/preview/parse/parsePoolOperationCalldata.d.ts +2 -3
- package/dist/types/onchain/preview/parse/parseRWAFactoryOperationCalldata.d.ts +2 -3
- package/dist/types/onchain/preview/parse/types-adapters.d.ts +4 -5
- package/dist/types/onchain/preview/parse/types-facades.d.ts +20 -21
- package/dist/types/onchain/preview/parse/types-pools.d.ts +6 -7
- package/dist/types/onchain/preview/parse/types-rwa.d.ts +5 -6
- package/dist/types/onchain/preview/parse/types.d.ts +4 -4
- package/dist/types/onchain/preview/preview/CreditAccountState.d.ts +5 -5
- package/dist/types/onchain/preview/preview/buildDelayedStrategyPositionOperationPreview.d.ts +2 -3
- package/dist/types/onchain/preview/preview/detectCloseOrRepay.d.ts +3 -4
- package/dist/types/onchain/preview/preview/detectDelayedClaim.d.ts +4 -5
- package/dist/types/onchain/preview/preview/detectDelayedOperation.d.ts +3 -4
- package/dist/types/onchain/preview/preview/estimateClaimableAt.d.ts +2 -3
- package/dist/types/onchain/preview/preview/midasGreenlistsAccount.d.ts +2 -3
- package/dist/types/onchain/preview/preview/previewAdjustStrategyPosition.d.ts +2 -3
- package/dist/types/onchain/preview/preview/previewExitOrRepayStrategyPosition.d.ts +3 -4
- package/dist/types/onchain/preview/preview/previewOpenStrategyPosition.d.ts +2 -2
- package/dist/types/onchain/preview/preview/previewOperation.d.ts +3 -4
- package/dist/types/onchain/preview/preview/previewPoolPositionOperation.d.ts +2 -3
- package/dist/types/onchain/preview/preview/replayInnerOperations.d.ts +4 -5
- package/dist/types/onchain/preview/preview/replayMulticall.d.ts +4 -5
- package/dist/types/onchain/preview/preview/unwrapNativeCollateral.d.ts +2 -3
- package/dist/types/onchain/router/AbstractRouterContract.d.ts +4 -5
- package/dist/types/onchain/router/RouterV310Contract.d.ts +2 -2
- package/dist/types/onchain/router/createRouter.d.ts +2 -3
- package/dist/types/onchain/router/helpers.d.ts +3 -4
- package/dist/types/onchain/router/types.d.ts +15 -16
- package/dist/types/onchain/types/logger.d.ts +3 -4
- package/dist/types/onchain/types/multichain.d.ts +6 -7
- package/dist/types/onchain/types/state-human.d.ts +36 -37
- package/dist/types/onchain/types/state.d.ts +3 -4
- package/dist/types/onchain/types/transactions.d.ts +5 -6
- package/dist/types/onchain/utils/AddressMap.d.ts +2 -3
- package/dist/types/onchain/utils/AddressSet.d.ts +2 -3
- package/dist/types/onchain/utils/AssetsMap.d.ts +2 -3
- package/dist/types/onchain/utils/abi-decode.d.ts +4 -5
- package/dist/types/onchain/utils/bigint-math.d.ts +2 -3
- package/dist/types/onchain/utils/bytes32ToString.d.ts +2 -3
- package/dist/types/onchain/utils/childLogger.d.ts +2 -3
- package/dist/types/onchain/utils/createRawTx.d.ts +2 -3
- package/dist/types/onchain/utils/etherscan.d.ts +4 -5
- package/dist/types/onchain/utils/filterDust.d.ts +4 -5
- package/dist/types/onchain/utils/formatter.d.ts +17 -17
- package/dist/types/onchain/utils/hex.d.ts +2 -3
- package/dist/types/onchain/utils/internal/Hooks.d.ts +3 -4
- package/dist/types/onchain/utils/isDust.d.ts +3 -4
- package/dist/types/onchain/utils/json.d.ts +3 -4
- package/dist/types/onchain/utils/mappers.d.ts +5 -6
- package/dist/types/onchain/utils/retry.d.ts +3 -4
- package/dist/types/onchain/utils/toAddress.d.ts +2 -3
- package/dist/types/onchain/utils/trace.d.ts +8 -9
- package/dist/types/onchain/utils/type-utils.d.ts +2 -3
- package/dist/types/onchain/utils/viem/cast.d.ts +3 -4
- package/dist/types/onchain/utils/viem/executeDelegatedMulticalls.d.ts +3 -4
- package/dist/types/onchain/utils/viem/executeMulticallBatches.d.ts +4 -5
- package/dist/types/onchain/utils/viem/sendRawTx.d.ts +5 -6
- package/dist/types/onchain/utils/viem/simulateCall.d.ts +7 -8
- package/dist/types/onchain/utils/viem/simulateMulticall.d.ts +4 -5
- package/dist/types/onchain/utils/viem/simulateWithPriceUpdates.d.ts +8 -9
- package/dist/types/onchain/utils/viem/watchBlocksAsync.d.ts +4 -4
- package/dist/types/onchain/utils/zod.d.ts +4 -5
- package/dist/types/onchain/validation/bundles/checkAccountQuotas.d.ts +2 -3
- package/dist/types/onchain/validation/bundles/checkCollateralFunding.d.ts +4 -5
- package/dist/types/onchain/validation/bundles/checkCreditOperation.d.ts +6 -7
- package/dist/types/onchain/validation/bundles/checkHealthFactors.d.ts +4 -5
- package/dist/types/onchain/validation/bundles/checkIncreaseDebt.d.ts +2 -3
- package/dist/types/onchain/validation/bundles/checkIncreaseQuota.d.ts +2 -3
- package/dist/types/onchain/validation/bundles/checkLiquidationEligibility.d.ts +7 -7
- package/dist/types/onchain/validation/bundles/checkLiquidationFunding.d.ts +5 -5
- package/dist/types/onchain/validation/bundles/checkMarket.d.ts +3 -4
- package/dist/types/onchain/validation/bundles/checkMidasAccountGreenlist.d.ts +3 -4
- package/dist/types/onchain/validation/bundles/checkObtained.d.ts +2 -3
- package/dist/types/onchain/validation/bundles/checkPoolFunding.d.ts +3 -4
- package/dist/types/onchain/validation/bundles/checkPoolOperation.d.ts +4 -5
- package/dist/types/onchain/validation/bundles/checkQuotaUpdates.d.ts +15 -0
- package/dist/types/onchain/validation/bundles/checkRWAOpenRequirements.d.ts +3 -4
- package/dist/types/onchain/validation/bundles/checkRWAOpening.d.ts +4 -5
- package/dist/types/onchain/validation/bundles/checkWallet.d.ts +4 -5
- package/dist/types/onchain/validation/bundles/checkWalletAllowance.d.ts +3 -4
- package/dist/types/onchain/validation/bundles/checkWalletBalance.d.ts +3 -4
- package/dist/types/onchain/validation/bundles/index.d.ts +2 -1
- package/dist/types/onchain/validation/checkLiquidation.d.ts +7 -7
- package/dist/types/onchain/validation/checkOperation.d.ts +5 -6
- package/dist/types/onchain/validation/checkSimulation.d.ts +5 -6
- package/dist/types/onchain/validation/checks/checkBorrowLimit.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkCollateralised.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkCreditAccountFrozen.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkCreditManagerPaused.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkDebtLimits.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkEmergencyLiquidator.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkForbiddenToken.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkLeverage.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkLiquidatorEligible.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkMarketExpired.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkMaxQuota.d.ts +15 -0
- package/dist/types/onchain/validation/checks/checkPartiallyLiquidatable.d.ts +16 -0
- package/dist/types/onchain/validation/checks/checkPoolLiquidity.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkPoolPaused.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkPoolSunset.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkQuotaActive.d.ts +12 -0
- package/dist/types/onchain/validation/checks/checkQuotaChange.d.ts +16 -0
- package/dist/types/onchain/validation/checks/checkQuotaCount.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkQuotaLimit.d.ts +3 -4
- package/dist/types/onchain/validation/checks/checkReservePriceLimited.d.ts +3 -4
- package/dist/types/onchain/validation/checks/index.d.ts +5 -1
- package/dist/types/onchain/validation/helpers/amount.d.ts +2 -3
- package/dist/types/onchain/validation/helpers/health-factor-limits.d.ts +5 -6
- package/dist/types/onchain/validation/helpers/token.d.ts +3 -4
- package/dist/types/onchain/validation/index.d.ts +6 -1
- package/dist/types/onchain/validation/raise.d.ts +5 -6
- package/dist/types/permissionless/api/GearboxPermissionless.d.ts +2 -3
- package/dist/types/permissionless/api/chains/ChainsNamespace.d.ts +2 -3
- package/dist/types/permissionless/api/chains/schemas.d.ts +5 -6
- package/dist/types/permissionless/api/chains/types.d.ts +6 -7
- package/dist/types/permissionless/api/deploy/PermissionlessDeploy.d.ts +4 -5
- package/dist/types/permissionless/api/deploy/effective-staleness.d.ts +2 -3
- package/dist/types/permissionless/api/deploy/types.d.ts +6 -7
- package/dist/types/permissionless/api/errors.d.ts +6 -7
- package/dist/types/permissionless/api/oracles/PermissionlessOracles.d.ts +4 -5
- package/dist/types/permissionless/api/oracles/schemas.d.ts +5 -6
- package/dist/types/permissionless/api/oracles/types.d.ts +5 -6
- package/dist/types/permissionless/api/schemas.d.ts +4 -5
- package/dist/types/permissionless/api/transactions/InstanceOwnerTransactions.d.ts +2 -3
- package/dist/types/permissionless/api/transactions/lp-price-feeds.d.ts +3 -4
- package/dist/types/permissionless/api/transactions/types.d.ts +7 -8
- package/dist/types/permissionless/api/types.d.ts +2 -3
- package/dist/types/permissionless/bindings/address-provider.d.ts +2 -3
- package/dist/types/permissionless/bindings/bytecode-repository.d.ts +2 -2
- package/dist/types/permissionless/bindings/compressors/token-compressor.d.ts +2 -2
- package/dist/types/permissionless/bindings/compressors/withdrawal-compressor.d.ts +2 -2
- package/dist/types/permissionless/bindings/cross-chain-multisig.d.ts +4 -4
- package/dist/types/permissionless/bindings/factory/abstract-factory.d.ts +2 -3
- package/dist/types/permissionless/bindings/factory/credit-factory.d.ts +2 -2
- package/dist/types/permissionless/bindings/factory/loss-policy-factory.d.ts +2 -2
- package/dist/types/permissionless/bindings/factory/pool-factory.d.ts +2 -2
- package/dist/types/permissionless/bindings/factory/price-oracle-factory.d.ts +2 -2
- package/dist/types/permissionless/bindings/factory/rate-keeper-factory.d.ts +2 -2
- package/dist/types/permissionless/bindings/governance/batches-chain.d.ts +2 -2
- package/dist/types/permissionless/bindings/governance/governor.d.ts +2 -2
- package/dist/types/permissionless/bindings/governance/timelock.d.ts +2 -3
- package/dist/types/permissionless/bindings/governance/types.d.ts +7 -8
- package/dist/types/permissionless/bindings/instance-manager.d.ts +2 -2
- package/dist/types/permissionless/bindings/market-configurator-factory.d.ts +2 -2
- package/dist/types/permissionless/bindings/market-configurator.d.ts +2 -2
- package/dist/types/permissionless/bindings/price-feed-store.d.ts +2 -2
- package/dist/types/permissionless/bindings/pricefeeds/balancer-stable.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/balancer-weighted.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/bounded.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/composite.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/constant.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/curve-crypto.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/curve-stable.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/curve-twap.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/curve-usd.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/erc4626.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/external.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/index.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/kodiak.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/mellow-lrt.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/pendle-pt-twap.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/pyth.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/redstone.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/wsteth.d.ts +2 -3
- package/dist/types/permissionless/bindings/pricefeeds/zero.d.ts +2 -3
- package/dist/types/permissionless/bindings/router/routing-manager.d.ts +2 -2
- package/dist/types/permissionless/bindings/treasury-splitter.d.ts +2 -2
- package/dist/types/permissionless/bindings/types.d.ts +17 -18
- package/dist/types/permissionless/chains/archive-transport.d.ts +3 -4
- package/dist/types/permissionless/chains/chunked-log-transport.d.ts +2 -2
- package/dist/types/permissionless/core/auditor.d.ts +2 -3
- package/dist/types/permissionless/core/bytecode.d.ts +5 -6
- package/dist/types/permissionless/core/pricefeed-builder.d.ts +6 -7
- package/dist/types/permissionless/core/pricefeed.d.ts +2 -3
- package/dist/types/permissionless/core/proposal.d.ts +5 -6
- package/dist/types/permissionless/core/raw-tx.d.ts +2 -3
- package/dist/types/permissionless/deployment/addresses.d.ts +2 -3
- package/dist/types/permissionless/deployment/mainnet.d.ts +6 -7
- package/dist/types/permissionless/plugins/irm/constructor-params-abi.d.ts +8 -8
- package/dist/types/permissionless/plugins/loss-policies/constructor-params-abi.d.ts +8 -8
- package/dist/types/permissionless/plugins/rate-keepers/constructor-params-abi.d.ts +9 -9
- package/dist/types/permissionless/utils/abi-encoder.d.ts +4 -5
- package/dist/types/permissionless/utils/block-utils.d.ts +2 -3
- package/dist/types/permissionless/utils/create2.d.ts +9 -10
- package/dist/types/permissionless/utils/format.d.ts +7 -8
- package/dist/types/permissionless/utils/governance/batch.d.ts +5 -6
- package/dist/types/permissionless/utils/governance/timelock-txs.d.ts +2 -3
- package/dist/types/permissionless/utils/governance/types.d.ts +3 -4
- package/dist/types/permissionless/utils/literals.d.ts +8 -9
- package/dist/types/permissionless/utils/price-update/get-price-update-tx.d.ts +2 -3
- package/dist/types/permissionless/utils/price-update/get-prices.d.ts +2 -3
- package/dist/types/permissionless/utils/price-update/get-updatable-feeds.d.ts +3 -4
- package/dist/types/permissionless/utils/signature.d.ts +2 -3
- package/dist/types/plugins/accounts/AccountsPlugin.d.ts +3 -4
- package/dist/types/plugins/accounts-counter/AccountsCounterPlugin.d.ts +3 -4
- package/dist/types/plugins/bots/BotsPlugin.d.ts +2 -3
- package/dist/types/plugins/bots/PartialLiquidationBotV310Contract.d.ts +3 -3
- package/dist/types/plugins/bots/abi/iPartialLiquidationBotV310.d.ts +2 -3
- package/dist/types/plugins/bots/config.d.ts +6 -7
- package/dist/types/plugins/bots/deserializePartialLiquidationBotParams.d.ts +2 -3
- package/dist/types/plugins/bots/types.d.ts +11 -12
- package/dist/types/sdk/AbstractNamespace.d.ts +3 -4
- package/dist/types/sdk/GearboxSDK.d.ts +3 -4
- package/dist/types/sdk/analytics/AnalyticsNamespace.d.ts +2 -3
- package/dist/types/sdk/analytics/types.d.ts +3 -4
- package/dist/types/sdk/errors/AllSourcesFailedError.d.ts +2 -3
- package/dist/types/sdk/errors/MissingSourceError.d.ts +2 -3
- package/dist/types/sdk/errors/NoSourceServedError.d.ts +2 -3
- package/dist/types/sdk/errors/SourceChainMismatchError.d.ts +3 -4
- package/dist/types/sdk/errors/SourceUnavailableError.d.ts +2 -3
- package/dist/types/sdk/errors/assertSameChains.d.ts +2 -3
- package/dist/types/sdk/errors/everyChainFailed.d.ts +2 -3
- package/dist/types/sdk/execute/ExecuteApi.d.ts +2 -3
- package/dist/types/sdk/execute/types.d.ts +9 -10
- package/dist/types/sdk/index.d.ts +2 -2
- package/dist/types/sdk/liquidations/LiquidationsNamespace.d.ts +11 -4
- package/dist/types/sdk/liquidations/types.d.ts +24 -9
- package/dist/types/sdk/opportunities/OpportunitiesNamespace.d.ts +2 -3
- package/dist/types/sdk/opportunities/types.d.ts +9 -10
- package/dist/types/sdk/positions/PositionsNamespace.d.ts +2 -3
- package/dist/types/sdk/positions/mergePositionList.d.ts +2 -3
- package/dist/types/sdk/positions/types.d.ts +9 -10
- package/dist/types/sdk/prepare/PrepareApi.d.ts +14 -7
- package/dist/types/sdk/prepare/index.d.ts +2 -2
- package/dist/types/sdk/prepare/types.d.ts +72 -33
- package/dist/types/sdk/prepare/withdrawable-collaterals.d.ts +2 -3
- package/dist/types/sdk/preview/PreviewNamespace.d.ts +2 -3
- package/dist/types/sdk/preview/types.d.ts +4 -5
- package/dist/types/sdk/rewards/RewardsNamespace.d.ts +2 -3
- package/dist/types/sdk/rewards/errors.d.ts +3 -4
- package/dist/types/sdk/rewards/helpers.d.ts +7 -8
- package/dist/types/sdk/rewards/merkl-api.d.ts +6 -6
- package/dist/types/sdk/rewards/toMerklRewards.d.ts +2 -3
- package/dist/types/sdk/rewards/toTurtleRewards.d.ts +2 -3
- package/dist/types/sdk/rewards/turtle-api.d.ts +7 -8
- package/dist/types/sdk/rewards/types.d.ts +5 -6
- package/dist/types/sdk/types.d.ts +13 -14
- package/dist/types/sdk/utils/filterResponse.d.ts +2 -3
- package/dist/types/sdk/utils/mergeChains.d.ts +4 -5
- package/dist/types/sdk/utils/types.d.ts +5 -5
- package/package.json +15 -15
|
@@ -15,7 +15,7 @@ import "../../types/index.js";
|
|
|
15
15
|
import "../../base/index.js";
|
|
16
16
|
import { Address, Hex } from "viem";
|
|
17
17
|
//#region src/onchain/market/credit/types.d.ts
|
|
18
|
-
interface ICreditConfiguratorContract extends IBaseContract {
|
|
18
|
+
export interface ICreditConfiguratorContract extends IBaseContract {
|
|
19
19
|
isPaused: boolean;
|
|
20
20
|
checkRamps: () => Promise<RampEvent[]>;
|
|
21
21
|
stateHuman: (raw?: boolean) => CreditConfiguratorStateHuman;
|
|
@@ -25,7 +25,7 @@ interface ICreditConfiguratorContract extends IBaseContract {
|
|
|
25
25
|
* {@link CreditSuite.maxBorrowAmount} and
|
|
26
26
|
* {@link CreditSuiteStrategy.maxBorrowAmount} for the bounds each applies.
|
|
27
27
|
**/
|
|
28
|
-
interface MaxBorrowAmount {
|
|
28
|
+
export interface MaxBorrowAmount {
|
|
29
29
|
/** In the pool's underlying. */
|
|
30
30
|
amount: TokenAmount;
|
|
31
31
|
/** The limit {@link value} ran into; see {@link BorrowLimitCause}. */
|
|
@@ -34,7 +34,7 @@ interface MaxBorrowAmount {
|
|
|
34
34
|
/**
|
|
35
35
|
* Fee parameters of a liquidation, with the suite's expiration already resolved.
|
|
36
36
|
**/
|
|
37
|
-
interface LiquidationFees {
|
|
37
|
+
export interface LiquidationFees {
|
|
38
38
|
/** Protocol's cut of the liquidated collateral, in basis points. */
|
|
39
39
|
feeLiquidation: Bps;
|
|
40
40
|
/** Price the liquidator pays for collateral, in basis points. */
|
|
@@ -44,7 +44,7 @@ interface LiquidationFees {
|
|
|
44
44
|
* Expected balance change of one token, as the facade's `storeExpectedBalances`
|
|
45
45
|
* takes it. Negative amounts mark tokens the multicall spends.
|
|
46
46
|
*/
|
|
47
|
-
interface BalanceDelta {
|
|
47
|
+
export interface BalanceDelta {
|
|
48
48
|
token: Address;
|
|
49
49
|
/**
|
|
50
50
|
* Signed balance change, `int256` on-chain.
|
|
@@ -56,7 +56,7 @@ interface BalanceDelta {
|
|
|
56
56
|
* units. Enough to decide whether the quota needs a disabling call.
|
|
57
57
|
*/
|
|
58
58
|
/** A quota keeper's parameters for one token, as a quota calculation reads them. */
|
|
59
|
-
interface QuotaSlice {
|
|
59
|
+
export interface QuotaSlice {
|
|
60
60
|
token: Address;
|
|
61
61
|
rate: bigint;
|
|
62
62
|
quotaIncreaseFee: bigint;
|
|
@@ -64,7 +64,7 @@ interface QuotaSlice {
|
|
|
64
64
|
limit: bigint;
|
|
65
65
|
isActive: boolean;
|
|
66
66
|
}
|
|
67
|
-
interface CreditAccountTokenQuota {
|
|
67
|
+
export interface CreditAccountTokenQuota {
|
|
68
68
|
token: Address;
|
|
69
69
|
quota: bigint;
|
|
70
70
|
}
|
|
@@ -72,7 +72,7 @@ interface CreditAccountTokenQuota {
|
|
|
72
72
|
* Quota `Asset.balance` values are denominated in **pool underlying token
|
|
73
73
|
* units**, not in the quoted token's own units.
|
|
74
74
|
**/
|
|
75
|
-
interface PrepareUpdateQuotasProps {
|
|
75
|
+
export interface PrepareUpdateQuotasProps {
|
|
76
76
|
/**
|
|
77
77
|
* Average quota for desired token, in pool underlying units
|
|
78
78
|
* (see {@link PrepareUpdateQuotasProps})
|
|
@@ -90,7 +90,7 @@ interface PrepareUpdateQuotasProps {
|
|
|
90
90
|
/**
|
|
91
91
|
* Wrapper around the core credit manager contract.
|
|
92
92
|
*/
|
|
93
|
-
interface ICreditManagerContract extends IBaseContract {
|
|
93
|
+
export interface ICreditManagerContract extends IBaseContract {
|
|
94
94
|
/**
|
|
95
95
|
* Account factory contract address.
|
|
96
96
|
*/
|
|
@@ -168,7 +168,7 @@ interface ICreditManagerContract extends IBaseContract {
|
|
|
168
168
|
* Wrapper around the credit facade contract used to build account
|
|
169
169
|
* transactions such as open, close, liquidate, and multicall.
|
|
170
170
|
*/
|
|
171
|
-
interface ICreditFacadeContract extends IBaseContract {
|
|
171
|
+
export interface ICreditFacadeContract extends IBaseContract {
|
|
172
172
|
/**
|
|
173
173
|
* Degen NFT address (`address(0)` when Degen mode is disabled).
|
|
174
174
|
*/
|
|
@@ -295,40 +295,4 @@ interface ICreditFacadeContract extends IBaseContract {
|
|
|
295
295
|
*/
|
|
296
296
|
prepareWithBalanceCheck(deltas: BalanceDelta[], calls: MultiCall[]): MultiCall[];
|
|
297
297
|
}
|
|
298
|
-
|
|
299
|
-
* Partial liquidation parameters a caller wants to pin down instead of letting
|
|
300
|
-
* {@link CreditSuite.partialLiquidationParams} derive them.
|
|
301
|
-
*
|
|
302
|
-
* @remarks
|
|
303
|
-
* The defaults are derived in order - `optimalHF` feeds `repaidAmount`, which
|
|
304
|
-
* feeds `minSeizedAmount` - so overriding one still lets the ones after it
|
|
305
|
-
* follow from the override.
|
|
306
|
-
**/
|
|
307
|
-
interface PartialLiquidationParams {
|
|
308
|
-
/**
|
|
309
|
-
* Collateral token to seize.
|
|
310
|
-
* If omitted, the most valuable enabled non-underlying collateral token
|
|
311
|
-
* (by oracle)
|
|
312
|
-
*/
|
|
313
|
-
tokenOut?: Address;
|
|
314
|
-
/**
|
|
315
|
-
* Amount of underlying token to repay.
|
|
316
|
-
* If omitted, computed internally
|
|
317
|
-
*/
|
|
318
|
-
repaidAmount?: bigint;
|
|
319
|
-
/**
|
|
320
|
-
* Minimum amount of `token` to seize from `creditAccount`.
|
|
321
|
-
* If `token` is a phantom token, it's withdrawn first, and its `depositedToken` is then sent to the liquidator.
|
|
322
|
-
* In this case, `minSeizedAmount` is denominated in `depositedToken`.
|
|
323
|
-
* If omitted, computed internally.
|
|
324
|
-
*/
|
|
325
|
-
minSeizedAmount?: bigint;
|
|
326
|
-
/**
|
|
327
|
-
* Target health factor for partial liquidation (4 digits precision, 10000 = 100%).
|
|
328
|
-
* If omitted, defaults to {@link CreditSuite.optimalHFForPartialLiquidation}.
|
|
329
|
-
* Only used when `repaidAmount` is not explicitly provided.
|
|
330
|
-
*/
|
|
331
|
-
optimalHF?: bigint;
|
|
332
|
-
}
|
|
333
|
-
//#endregion
|
|
334
|
-
export { BalanceDelta, CreditAccountTokenQuota, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, LiquidationFees, MaxBorrowAmount, PartialLiquidationParams, PrepareUpdateQuotasProps, QuotaSlice };
|
|
298
|
+
//#endregion
|
|
@@ -126,7 +126,7 @@ import { PriceUpdatesCache } from "./pricefeeds/updates/PriceUpdatesCache.js";
|
|
|
126
126
|
import { UpdatablePriceFeedRegistry } from "./pricefeeds/updates/UpdatablePriceFeedRegistry.js";
|
|
127
127
|
import { updatableDependencies } from "./pricefeeds/updates/updatableDependencies.js";
|
|
128
128
|
import "./pricefeeds/index.js";
|
|
129
|
-
import { BalanceDelta, CreditAccountTokenQuota, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, LiquidationFees, MaxBorrowAmount,
|
|
129
|
+
import { BalanceDelta, CreditAccountTokenQuota, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, LiquidationFees, MaxBorrowAmount, PrepareUpdateQuotasProps, QuotaSlice } from "./credit/types.js";
|
|
130
130
|
import { CreditConfiguratorV310Contract, RampEvent } from "./credit/CreditConfiguratorV310Contract.js";
|
|
131
131
|
import { CreditFacadeV310Abi as abi, CreditFacadeV310BaseContract } from "./credit/CreditFacadeV310BaseContract.js";
|
|
132
132
|
import { CreditFacadeV310Contract } from "./credit/CreditFacadeV310Contract.js";
|
|
@@ -156,6 +156,6 @@ import { IERC20ZapperContract } from "./zapper/IERC20ZapperContract.js";
|
|
|
156
156
|
import { IETHZapperContract } from "./zapper/IETHZapperContract.js";
|
|
157
157
|
import "./zapper/index.js";
|
|
158
158
|
import { MarketRegister, MarketRegistryState, MarketRegistryStateHuman } from "./MarketRegister.js";
|
|
159
|
-
import { DEFAULT_QUOTA_BUFFER_BPS, MAX_LEVERAGE_BUFFER_BPS,
|
|
159
|
+
import { DEFAULT_QUOTA_BUFFER_BPS, MAX_LEVERAGE_BUFFER_BPS, OptimalPartialLiquidationAmounts, OptimalPartialLiquidationAmountsProps, PARTIAL_LIQUIDATION_BUFFER_BPS, QuotaMode, StrategyRateInputs, bpsToRay, calcBorrowApy, calcEffectiveBorrowApy, calcMaxLeverage, calcNetStrategyApy, calcPositionLeverage, calcQuotaRate, calcUtilization, calcUtilizationRaw, healthFactorBps, minSeizedAmount, optimalHFForPartialLiquidation, optimalPartialLiquidationAmounts, rayToBps, usdToNumber } from "./math.js";
|
|
160
160
|
import { strategyName } from "./strategyName.js";
|
|
161
|
-
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, ConstantPriceFeedContract, ConvertFn, ConvexDeposit, ConvexDepositAndStake, ConvexStake, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, ConvexWithdraw, ConvexWithdrawAndClaim, CreditAccountTokenQuota, CreditConfiguratorV310Contract, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, CreditSuiteStrategy, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveAddLiquidity, CurveClaims, CurveCryptoPriceFeedContract, CurveExchange, CurveRemoveLiquidity, CurveRemoveLiquidityOneCoin, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, CurveWithdrawal, DEFAULT_QUOTA_BUFFER_BPS, DEGEN_NFT_MIDAS, DEGEN_NFT_SECURITIZE, DStokenData, DaiUsdsAdapterContract, DelayedWithdrawalClaim, DelayedWithdrawalRequest, ERC4626AdapterContract, ERC4626ReferralAdapterContract, Erc4626PriceFeedContract, ExpectedBalanceDeltasProps, ExpectedOutput, ExternalPriceFeedContract, FluidDexAdapterContract, GaugeContract, GaugeParams, GetInvestorOptions, GetOpenAccountRequirementsProps, GetReward, IAdapterContract, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IDegenNFT, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, IPoolContract, IPriceFeedContract, IPriceOracleContract, type IPriceUpdateTask, type IPriceUpdater, IRWAFactory, IRateKeeperContract, type IUpdatablePriceFeedContract, IZapperContract, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, InterestRateModelType, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, type LatestUpdate, LegacyAdapterOperation, LidoSubmit, LidoV1AdapterContract, LinearInterestRateModelContract, LiquidationFees, MAX_LEVERAGE_BUFFER_BPS, MakerDeposit, MakerRedeem, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, MarketSuite, MaxBorrowAmount, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, MidasDegenNFT, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract,
|
|
161
|
+
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, ConstantPriceFeedContract, ConvertFn, ConvexDeposit, ConvexDepositAndStake, ConvexStake, ConvexV1BaseRewardPoolAdapterContract, ConvexV1BoosterAdapterContract, ConvexWithdraw, ConvexWithdrawAndClaim, CreditAccountTokenQuota, CreditConfiguratorV310Contract, type abi as CreditFacadeV310Abi, abi as creditFacadeV310Abi, CreditFacadeV310BaseContract, CreditFacadeV310Contract, CreditManagerV310Contract, CreditSuite, CreditSuiteStrategy, Curve2AssetsAdapterContract, Curve3AssetsAdapterContract, Curve4AssetsAdapterContract, CurveAddLiquidity, CurveClaims, CurveCryptoPriceFeedContract, CurveExchange, CurveRemoveLiquidity, CurveRemoveLiquidityOneCoin, CurveStablePriceFeedContract, CurveUSDPriceFeedContract, CurveV1AdapterStETHContract, CurveV1StableNGAdapterContract, CurveWithdrawal, DEFAULT_QUOTA_BUFFER_BPS, DEGEN_NFT_MIDAS, DEGEN_NFT_SECURITIZE, DStokenData, DaiUsdsAdapterContract, DelayedWithdrawalClaim, DelayedWithdrawalRequest, ERC4626AdapterContract, ERC4626ReferralAdapterContract, Erc4626PriceFeedContract, ExpectedBalanceDeltasProps, ExpectedOutput, ExternalPriceFeedContract, FluidDexAdapterContract, GaugeContract, GaugeParams, GetInvestorOptions, GetOpenAccountRequirementsProps, GetReward, IAdapterContract, ICreditConfiguratorContract, ICreditFacadeContract, ICreditManagerContract, IDegenNFT, IERC20ZapperContract, IETHZapperContract, IInterestRateModelContract, IPoolContract, IPriceFeedContract, IPriceOracleContract, type IPriceUpdateTask, type IPriceUpdater, IRWAFactory, IRateKeeperContract, type IUpdatablePriceFeedContract, IZapperContract, InfinifiGatewayAdapterContract, InfinifiUnwindingGatewayAdapterContract, InterestRateModelType, KelpLRTDepositPoolAdapterContract, KelpLRTWithdrawalManagerAdapterContract, type LatestUpdate, LegacyAdapterOperation, LidoSubmit, LidoV1AdapterContract, LinearInterestRateModelContract, LiquidationFees, MAX_LEVERAGE_BUFFER_BPS, MakerDeposit, MakerRedeem, MarketRegister, MarketRegistryState, MarketRegistryStateHuman, MarketSuite, MaxBorrowAmount, MellowClaimerAdapterContract, MellowDVVAdapterContract, MellowERC4626VaultAdapterContract, MellowLRTPriceFeedContract, MellowWrapperAdapterContract, MidasDegenNFT, MidasGatewayAdapterContract, MidasIssuanceVaultAdapterContract, MidasLiquidatorContract, MidasRedemptionVaultAdapterContract, OptimalPartialLiquidationAmounts, OptimalPartialLiquidationAmountsProps, PARTIAL_LIQUIDATION_BUFFER_BPS, PHANTOM_TOKEN_MIDAS_REDEMPTION, PHANTOM_TOKEN_SECURITIZE_REDEMPTION, ParsedZapperDeposit, ParsedZapperOperation, ParsedZapperRedeem, PartialPriceFeedInitError, PartialPriceFeedTreeNode, PendlePair, PendlePairStatus, PendleRouterAdapterContract, PendleTWAPPTPriceFeed, PendleTokenType, PoolQuotaKeeperContract, PoolSuite, PoolV310Contract, PrepareUpdateQuotasProps, PriceFeedConstructorArgs, PriceFeedContractType, PriceFeedRef, PriceFeedRegistry, PriceFeedUsageType, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions, PriceOracleV310Contract, PriceUpdate, PriceUpdatesCache, PythPriceFeed, QuotaMode, QuotaSlice, RWACompressorCall, RWACompressorInvestorData, RWACompressorResponse, RWAFactoryData, RWAFactoryProtocol, RWAFactoryStateHuman, RWAInvestorData, RWARegistry, RWAState, RWAStateHuman, RWAUnderlyingData, RWA_COMPRESSOR_ADDRESS, RWA_LIQUIDATOR_MIDAS, RWA_LIQUIDATOR_SECURITIZE, RampEvent, RateKeeperType, RedstonePriceFeedContract, SecuritizeCreditAccountData, SecuritizeDegenNFT, SecuritizeInvestorData, SecuritizeLiquidatorContract, SecuritizeOnRampAdapterContract, SecuritizeRWAFactory, SecuritizeRWAFactoryStateHuman, SecuritizeRedemptionGatewayAdapterContract, StakingRewardsAdapterContract, StrategyCollateralProps, StrategyRateInputs, Swap, type TimestampedCalldata, TokenAmount, TokenTransfer, TraderJoePool, TraderJoePoolVersion, TraderJoeRouterAdapterContract, Transfers, UniswapSwap, UniswapV2AdapterContract, UniswapV3AdapterContract, UniswapV4AdapterContract, UpdatablePriceFeedRegistry, type UpdatablePriceFeedRegistryHooks, type UpdatePriceFeedsResult, UpshiftVaultAdapterContract, VaultDeposit, VelodromeV2RouterAdapterContract, VersionedAbi, WithdrawCollateral, WstETHPriceFeedContract, WstETHUnwrap, WstETHV1AdapterContract, WstETHWrap, YearnPriceFeedContract, ZapperContract, ZapperData, ZeroPriceFeedContract, adapterActionAbi, adapterActionSelectors, adapterActionSignatures, adapterConstructorAbi, allTransfersAsTokenAmounts, bpsToRay, calcBorrowApy, calcEffectiveBorrowApy, calcMaxLeverage, calcNetStrategyApy, calcPositionLeverage, calcQuotaRate, calcUtilization, calcUtilizationRaw, classifyCurveOperation, collateralPriceInUnderlying, createAdapter, createPriceOracle, createZapper, curveAddLiquidityFromTransfers, curveRemoveLiquidityFromTransfers, dominantCollateral, erc4626ReferralAdapterAbi, expectedBalanceDeltas, 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, optimalPartialLiquidationAmounts, parseAdapterAction, parseAdapterDeployParams, parsePosNegAmount, pickStrategyTargetCollateral, rayToBps, rewardsFromTransfers, strategyName, swapFromTransfers, toNetTransfers, updatableDependencies, usdToNumber };
|
|
@@ -277,13 +277,13 @@ declare const abi: readonly [{
|
|
|
277
277
|
readonly anonymous: false;
|
|
278
278
|
}];
|
|
279
279
|
type abi = typeof abi;
|
|
280
|
-
interface AliasedPriceFeedParams {
|
|
280
|
+
export interface AliasedPriceFeedParams {
|
|
281
281
|
priceFeed: Address;
|
|
282
282
|
stalenessPeriod: number;
|
|
283
283
|
skipCheck: boolean;
|
|
284
284
|
tokenDecimals: number;
|
|
285
285
|
}
|
|
286
|
-
declare class AliasLossPolicyV310Contract extends BaseContract<abi> implements ILossPolicyContract {
|
|
286
|
+
export declare class AliasLossPolicyV310Contract extends BaseContract<abi> implements ILossPolicyContract {
|
|
287
287
|
readonly accessMode: number;
|
|
288
288
|
readonly checksEnabled: boolean;
|
|
289
289
|
readonly tokens: readonly Address[];
|
|
@@ -294,4 +294,4 @@ declare class AliasLossPolicyV310Contract extends BaseContract<abi> implements I
|
|
|
294
294
|
stateHuman(raw?: boolean): AliasLossPolicyStateHuman;
|
|
295
295
|
}
|
|
296
296
|
//#endregion
|
|
297
|
-
export {
|
|
297
|
+
export {};
|
|
@@ -132,9 +132,9 @@ declare const abi: readonly [{
|
|
|
132
132
|
readonly anonymous: false;
|
|
133
133
|
}];
|
|
134
134
|
type abi = typeof abi;
|
|
135
|
-
declare class LossPolicyContract extends BaseContract<abi> implements ILossPolicyContract {
|
|
135
|
+
export declare class LossPolicyContract extends BaseContract<abi> implements ILossPolicyContract {
|
|
136
136
|
constructor(options: ConstructOptions, params: BaseParams);
|
|
137
137
|
getLiquidationData(_creditAccount: Address, _blockNumber?: bigint): Promise<Hex | undefined>;
|
|
138
138
|
}
|
|
139
139
|
//#endregion
|
|
140
|
-
export {
|
|
140
|
+
export {};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
//#region src/onchain/market/loss-policy/constants.d.ts
|
|
2
|
-
declare const LOSS_POLICY_ALIASED: "LOSS_POLICY::ALIASED";
|
|
3
|
-
declare const LOSS_POLICY_DEFAULT: "LOSS_POLICY::DEFAULT";
|
|
4
|
-
declare const LOSS_POLICY_ACCESS_MODES: readonly ["Permissionless", "Permissioned", "Forbidden"];
|
|
5
|
-
type LossPolicyAccessMode = (typeof LOSS_POLICY_ACCESS_MODES)[number];
|
|
6
|
-
//#endregion
|
|
7
|
-
export { LOSS_POLICY_ACCESS_MODES, LOSS_POLICY_ALIASED, LOSS_POLICY_DEFAULT, LossPolicyAccessMode };
|
|
2
|
+
export declare const LOSS_POLICY_ALIASED: "LOSS_POLICY::ALIASED";
|
|
3
|
+
export declare const LOSS_POLICY_DEFAULT: "LOSS_POLICY::DEFAULT";
|
|
4
|
+
export declare const LOSS_POLICY_ACCESS_MODES: readonly ["Permissionless", "Permissioned", "Forbidden"];
|
|
5
|
+
export type LossPolicyAccessMode = (typeof LOSS_POLICY_ACCESS_MODES)[number];
|
|
6
|
+
//#endregion
|
|
@@ -3,6 +3,5 @@ import { ILossPolicyContract } from "./types.js";
|
|
|
3
3
|
import { OnchainSDK } from "../../OnchainSDK.js";
|
|
4
4
|
import "../../base/index.js";
|
|
5
5
|
//#region src/onchain/market/loss-policy/createLossPolicy.d.ts
|
|
6
|
-
declare function createLossPolicy(sdk: OnchainSDK, { baseParams }: BaseState): ILossPolicyContract;
|
|
7
|
-
//#endregion
|
|
8
|
-
export { createLossPolicy };
|
|
6
|
+
export declare function createLossPolicy(sdk: OnchainSDK, { baseParams }: BaseState): ILossPolicyContract;
|
|
7
|
+
//#endregion
|
|
@@ -4,7 +4,7 @@ import "../../types/index.js";
|
|
|
4
4
|
import "../../base/index.js";
|
|
5
5
|
import { Address, Hex } from "viem";
|
|
6
6
|
//#region src/onchain/market/loss-policy/types.d.ts
|
|
7
|
-
interface ILossPolicyContract extends IBaseContract {
|
|
7
|
+
export interface ILossPolicyContract extends IBaseContract {
|
|
8
8
|
stateHuman(raw?: boolean): BaseContractStateHuman;
|
|
9
9
|
/**
|
|
10
10
|
* Returns lossPolicyData that is passed to CreditFacade.liquidateCreditAccount
|
|
@@ -14,5 +14,4 @@ interface ILossPolicyContract extends IBaseContract {
|
|
|
14
14
|
*/
|
|
15
15
|
getLiquidationData(creditAccount: Address, blockNumber?: bigint): Promise<Hex | undefined>;
|
|
16
16
|
}
|
|
17
|
-
//#endregion
|
|
18
|
-
export { ILossPolicyContract };
|
|
17
|
+
//#endregion
|
|
@@ -12,7 +12,7 @@ import "../../model/index.js";
|
|
|
12
12
|
* rayToBps(50_000_000_000_000_000_000_000_000n) // 500 bps = 5%
|
|
13
13
|
* ```
|
|
14
14
|
**/
|
|
15
|
-
declare function rayToBps(ray: bigint): Bps;
|
|
15
|
+
export declare function rayToBps(ray: bigint): Bps;
|
|
16
16
|
/**
|
|
17
17
|
* Inverse of {@link rayToBps}, exact: a rate in basis points is a whole number
|
|
18
18
|
* of the `10 ** 23` steps a ray is made of.
|
|
@@ -22,7 +22,7 @@ declare function rayToBps(ray: bigint): Bps;
|
|
|
22
22
|
* bpsToRay(500) // 5% = 0.05 × 10²⁷
|
|
23
23
|
* ```
|
|
24
24
|
**/
|
|
25
|
-
declare function bpsToRay(bps: Bps): bigint;
|
|
25
|
+
export declare function bpsToRay(bps: Bps): bigint;
|
|
26
26
|
/**
|
|
27
27
|
* Converts a USD value in the oracle's 8-decimal fixed point to a float.
|
|
28
28
|
*
|
|
@@ -38,7 +38,7 @@ declare function bpsToRay(bps: Bps): bigint;
|
|
|
38
38
|
* usdToNumber(-150_050_000_000n) // -1500.5
|
|
39
39
|
* ```
|
|
40
40
|
**/
|
|
41
|
-
declare function usdToNumber(usd: bigint): number;
|
|
41
|
+
export declare function usdToNumber(usd: bigint): number;
|
|
42
42
|
/**
|
|
43
43
|
* Share of capital currently borrowed, in basis points. Returns `0` when there
|
|
44
44
|
* is nothing to borrow from, and never exceeds 100%.
|
|
@@ -49,12 +49,12 @@ declare function usdToNumber(usd: bigint): number;
|
|
|
49
49
|
* calcUtilizationRaw(750n, 1000n) // 750 / 1000 = 7500 bps = 75%
|
|
50
50
|
* ```
|
|
51
51
|
**/
|
|
52
|
-
declare function calcUtilizationRaw(borrowed: bigint, total: bigint): Bps;
|
|
52
|
+
export declare function calcUtilizationRaw(borrowed: bigint, total: bigint): Bps;
|
|
53
53
|
/**
|
|
54
54
|
* Pool utilization: {@link PoolOpportunity.totalBorrowedWithInterest} as a
|
|
55
55
|
* share of {@link PoolOpportunity.totalSupply}, in basis points.
|
|
56
56
|
**/
|
|
57
|
-
declare function calcUtilization(poolOpportunity: PoolOpportunity): Bps;
|
|
57
|
+
export declare function calcUtilization(poolOpportunity: PoolOpportunity): Bps;
|
|
58
58
|
/**
|
|
59
59
|
* Annual cost of debt for a credit manager, in basis points:
|
|
60
60
|
* `baseInterestRate × (1 + feeInterest)` — the pool's base rate plus the
|
|
@@ -69,7 +69,7 @@ declare function calcUtilization(poolOpportunity: PoolOpportunity): Bps;
|
|
|
69
69
|
* calcBorrowApy(50_000_000_000_000_000_000_000_000n, 5000) // 5% × 1.5 = 750 bps = 7.5%
|
|
70
70
|
* ```
|
|
71
71
|
**/
|
|
72
|
-
declare function calcBorrowApy(baseInterestRate: bigint, feeInterest: number): Bps;
|
|
72
|
+
export declare function calcBorrowApy(baseInterestRate: bigint, feeInterest: number): Bps;
|
|
73
73
|
/**
|
|
74
74
|
* Annual quota cost of a collateral, in basis points:
|
|
75
75
|
* `quotaRate × (1 + feeInterest)` — the quoted rate plus the protocol's cut of
|
|
@@ -84,12 +84,12 @@ declare function calcBorrowApy(baseInterestRate: bigint, feeInterest: number): B
|
|
|
84
84
|
* calcQuotaRate(200, 2500) // 2% × 1.25 = 250 bps = 2.5%
|
|
85
85
|
* ```
|
|
86
86
|
**/
|
|
87
|
-
declare function calcQuotaRate(quotaRate: Bps, feeInterest: Bps): Bps;
|
|
87
|
+
export declare function calcQuotaRate(quotaRate: Bps, feeInterest: Bps): Bps;
|
|
88
88
|
/**
|
|
89
89
|
* Extra quota, as a fraction of equity, that an aggressive position quotes
|
|
90
90
|
* above the debt it actually owes. Matches {@link MAX_LEVERAGE_BUFFER_BPS}.
|
|
91
91
|
**/
|
|
92
|
-
declare const DEFAULT_QUOTA_BUFFER_BPS = 500;
|
|
92
|
+
export declare const DEFAULT_QUOTA_BUFFER_BPS = 500;
|
|
93
93
|
/**
|
|
94
94
|
* How much quota a leveraged position quotes, relative to the debt it needs.
|
|
95
95
|
*
|
|
@@ -98,12 +98,12 @@ declare const DEFAULT_QUOTA_BUFFER_BPS = 500;
|
|
|
98
98
|
* so a price drop to the liquidation threshold still leaves enough quota.
|
|
99
99
|
* - `"aggressive"` — quota covers the debt plus {@link DEFAULT_QUOTA_BUFFER_BPS}.
|
|
100
100
|
**/
|
|
101
|
-
type QuotaMode = "min" | "safe" | "aggressive";
|
|
101
|
+
export type QuotaMode = "min" | "safe" | "aggressive";
|
|
102
102
|
/**
|
|
103
103
|
* Rates {@link calcEffectiveBorrowApy} and {@link calcNetStrategyApy} need
|
|
104
104
|
* from a {@link StrategyOpportunity}.
|
|
105
105
|
**/
|
|
106
|
-
type StrategyRateInputs = Pick<StrategyOpportunity, "borrowApy" | "quotaRate" | "liquidationThreshold">;
|
|
106
|
+
export type StrategyRateInputs = Pick<StrategyOpportunity, "borrowApy" | "quotaRate" | "liquidationThreshold">;
|
|
107
107
|
/**
|
|
108
108
|
* Annual cost of credit on the user's equity, in basis points, at a given
|
|
109
109
|
* leverage and quota mode: base interest on the borrowed part plus quota
|
|
@@ -114,7 +114,7 @@ type StrategyRateInputs = Pick<StrategyOpportunity, "borrowApy" | "quotaRate" |
|
|
|
114
114
|
* @param leverage - Total-value leverage, same scale as {@link Leverage}.
|
|
115
115
|
* @param mode - How much quota the position quotes, see {@link QuotaMode}.
|
|
116
116
|
**/
|
|
117
|
-
declare function calcEffectiveBorrowApy(opportunity: StrategyRateInputs, leverage: Leverage, mode?: QuotaMode): Bps;
|
|
117
|
+
export declare function calcEffectiveBorrowApy(opportunity: StrategyRateInputs, leverage: Leverage, mode?: QuotaMode): Bps;
|
|
118
118
|
/**
|
|
119
119
|
* Net yield of a strategy on the user's equity, in basis points, at a given
|
|
120
120
|
* leverage and quota mode:
|
|
@@ -129,12 +129,12 @@ declare function calcEffectiveBorrowApy(opportunity: StrategyRateInputs, leverag
|
|
|
129
129
|
* @param leverage - Total-value leverage, same scale as {@link Leverage}.
|
|
130
130
|
* @param mode - How much quota the position quotes, see {@link QuotaMode}.
|
|
131
131
|
**/
|
|
132
|
-
declare function calcNetStrategyApy(opportunity: StrategyRateInputs, totalCollateralApy: Bps, leverage: Leverage, mode?: QuotaMode): Bps;
|
|
132
|
+
export declare function calcNetStrategyApy(opportunity: StrategyRateInputs, totalCollateralApy: Bps, leverage: Leverage, mode?: QuotaMode): Bps;
|
|
133
133
|
/**
|
|
134
134
|
* 5% safety margin subtracted from 100% in {@link calcMaxLeverage}, so a
|
|
135
135
|
* maxed position opens with HF slightly above 1.
|
|
136
136
|
**/
|
|
137
|
-
declare const MAX_LEVERAGE_BUFFER_BPS = 500;
|
|
137
|
+
export declare const MAX_LEVERAGE_BUFFER_BPS = 500;
|
|
138
138
|
/**
|
|
139
139
|
* Highest total-value leverage a liquidation threshold allows, floored.
|
|
140
140
|
*
|
|
@@ -161,7 +161,7 @@ declare const MAX_LEVERAGE_BUFFER_BPS = 500;
|
|
|
161
161
|
* @throws If `liquidationThreshold` is 100% or more, or reaches a named
|
|
162
162
|
* `targetHF` — either way no leverage clears the bar.
|
|
163
163
|
**/
|
|
164
|
-
declare function calcMaxLeverage(liquidationThreshold: Bps, targetHF?: Bps): Leverage;
|
|
164
|
+
export declare function calcMaxLeverage(liquidationThreshold: Bps, targetHF?: Bps): Leverage;
|
|
165
165
|
/**
|
|
166
166
|
* Converts a credit account's health factor from the 18-decimal fixed point the
|
|
167
167
|
* contracts store to basis points.
|
|
@@ -175,7 +175,7 @@ declare function calcMaxLeverage(liquidationThreshold: Bps, targetHF?: Bps): Lev
|
|
|
175
175
|
* healthFactorBps(1_250_000_000_000_000_000n) // 12500 bps = 1.25
|
|
176
176
|
* ```
|
|
177
177
|
**/
|
|
178
|
-
declare function healthFactorBps(healthFactor: bigint): Bps;
|
|
178
|
+
export declare function healthFactorBps(healthFactor: bigint): Bps;
|
|
179
179
|
/**
|
|
180
180
|
* Total-value leverage of an open position:
|
|
181
181
|
* `totalValue / (totalValue − totalDebt)`. `1` when unleveraged, `0` when
|
|
@@ -190,7 +190,7 @@ declare function healthFactorBps(healthFactor: bigint): Bps;
|
|
|
190
190
|
* calcPositionLeverage(100_000n, 80_000n) // 100k / 20k = 5x
|
|
191
191
|
* ```
|
|
192
192
|
**/
|
|
193
|
-
declare function calcPositionLeverage(totalValue: bigint, totalDebt: bigint): Leverage;
|
|
193
|
+
export declare function calcPositionLeverage(totalValue: bigint, totalDebt: bigint): Leverage;
|
|
194
194
|
/**
|
|
195
195
|
* {@link PERCENTAGE_FACTOR} less a 0.1% safety buffer.
|
|
196
196
|
*
|
|
@@ -198,7 +198,7 @@ declare function calcPositionLeverage(totalValue: bigint, totalDebt: bigint): Le
|
|
|
198
198
|
* quoting and execution, so both the seized and the repaid amount are pulled
|
|
199
199
|
* this far away from the boundary the contracts would revert on.
|
|
200
200
|
**/
|
|
201
|
-
declare const PARTIAL_LIQUIDATION_BUFFER_BPS = 9990n;
|
|
201
|
+
export declare const PARTIAL_LIQUIDATION_BUFFER_BPS = 9990n;
|
|
202
202
|
/**
|
|
203
203
|
* Minimum collateral a partial liquidation must seize for a given repayment,
|
|
204
204
|
* derived from the liquidation discount and buffered by
|
|
@@ -209,12 +209,12 @@ declare const PARTIAL_LIQUIDATION_BUFFER_BPS = 9990n;
|
|
|
209
209
|
* @param liquidationDiscount - Discount in effect for this account, in basis
|
|
210
210
|
* points (the expired variant once the credit manager has expired).
|
|
211
211
|
**/
|
|
212
|
-
declare function minSeizedAmount(tokenAmount: bigint, liquidationDiscount: Bps): bigint;
|
|
212
|
+
export declare function minSeizedAmount(tokenAmount: bigint, liquidationDiscount: Bps): bigint;
|
|
213
213
|
/**
|
|
214
|
-
* Inputs of {@link
|
|
215
|
-
* market and credit manager by the caller.
|
|
214
|
+
* Inputs of {@link optimalPartialLiquidationAmounts}, all resolved against the
|
|
215
|
+
* account's market and credit manager by the caller.
|
|
216
216
|
**/
|
|
217
|
-
interface
|
|
217
|
+
export interface OptimalPartialLiquidationAmountsProps {
|
|
218
218
|
/** Debt principal plus accrued interest and fees, in underlying. */
|
|
219
219
|
totalDebt: bigint;
|
|
220
220
|
/** Threshold-weighted value of the account, converted to underlying. */
|
|
@@ -223,25 +223,44 @@ interface OptimalRepaidAmountProps {
|
|
|
223
223
|
minDebt: bigint;
|
|
224
224
|
/** Health factor to aim for, in basis points. */
|
|
225
225
|
optimalHF: bigint;
|
|
226
|
+
/** Liquidation discount in effect for this account, in basis points. */
|
|
227
|
+
liquidationDiscount: bigint;
|
|
226
228
|
/** `liquidationDiscount - feeLiquidation`, in basis points. */
|
|
227
229
|
discount: bigint;
|
|
228
230
|
/** Liquidation threshold of the seized token, in basis points. */
|
|
229
231
|
ltTokenOut: bigint;
|
|
230
232
|
}
|
|
231
233
|
/**
|
|
232
|
-
*
|
|
233
|
-
* to `optimalHF`,
|
|
234
|
+
* Amounts of a partial liquidation that brings the account's health factor
|
|
235
|
+
* close to `optimalHF`, all in underlying.
|
|
236
|
+
**/
|
|
237
|
+
export interface OptimalPartialLiquidationAmounts {
|
|
238
|
+
/** Underlying the liquidator pays for the seized collateral. */
|
|
239
|
+
optimalAmount: bigint;
|
|
240
|
+
/** Underlying that repays the account's debt. */
|
|
241
|
+
repaidAmount: bigint;
|
|
242
|
+
/** {@link optimalAmount} plus a 0.1% buffer, to borrow by flash loan. */
|
|
243
|
+
flashLoanAmount: bigint;
|
|
244
|
+
/**
|
|
245
|
+
* Whether the amounts reach `optimalHF`; `false` when the minimum debt
|
|
246
|
+
* capped them.
|
|
247
|
+
**/
|
|
248
|
+
isOptimalRepayable: boolean;
|
|
249
|
+
}
|
|
250
|
+
/**
|
|
251
|
+
* Amounts of a partial liquidation that brings the account's health factor
|
|
252
|
+
* close to `optimalHF`, capped so the account keeps at least `minDebt` of debt.
|
|
234
253
|
*
|
|
235
254
|
* Ported from solidity:
|
|
236
|
-
* https://github.com/Gearbox-protocol/router-v3/blob/56e2d515ec6d9bb1e324e71c3708e59710779b24/contracts/liquidation/AbstractLiquidator.sol#
|
|
255
|
+
* https://github.com/Gearbox-protocol/router-v3/blob/56e2d515ec6d9bb1e324e71c3708e59710779b24/contracts/liquidation/AbstractLiquidator.sol#L252
|
|
237
256
|
*
|
|
238
|
-
* @returns
|
|
239
|
-
*
|
|
257
|
+
* @returns Zero amounts when the account is already healthy enough or
|
|
258
|
+
* carries less than the minimum debt.
|
|
240
259
|
* @throws If the discounted target health factor does not exceed the seized
|
|
241
260
|
* token's liquidation threshold, in which case no repayment improves the
|
|
242
261
|
* account.
|
|
243
262
|
**/
|
|
244
|
-
declare function
|
|
263
|
+
export declare function optimalPartialLiquidationAmounts({ totalDebt, twvUnderlying, minDebt, optimalHF, liquidationDiscount, discount, ltTokenOut }: OptimalPartialLiquidationAmountsProps): OptimalPartialLiquidationAmounts;
|
|
245
264
|
/**
|
|
246
265
|
* Health factor a partial liquidation should target, in basis points: just
|
|
247
266
|
* above 1, by enough to cover up to 1% of borrow cost so the account does not
|
|
@@ -249,6 +268,5 @@ declare function optimalRepaidAmount({ totalDebt, twvUnderlying, minDebt, optima
|
|
|
249
268
|
*
|
|
250
269
|
* @param borrowRate - Blended borrow rate of the account, in basis points.
|
|
251
270
|
**/
|
|
252
|
-
declare function optimalHFForPartialLiquidation(borrowRate: bigint): bigint;
|
|
253
|
-
//#endregion
|
|
254
|
-
export { DEFAULT_QUOTA_BUFFER_BPS, MAX_LEVERAGE_BUFFER_BPS, OptimalRepaidAmountProps, PARTIAL_LIQUIDATION_BUFFER_BPS, QuotaMode, StrategyRateInputs, bpsToRay, calcBorrowApy, calcEffectiveBorrowApy, calcMaxLeverage, calcNetStrategyApy, calcPositionLeverage, calcQuotaRate, calcUtilization, calcUtilizationRaw, healthFactorBps, minSeizedAmount, optimalHFForPartialLiquidation, optimalRepaidAmount, rayToBps, usdToNumber };
|
|
271
|
+
export declare function optimalHFForPartialLiquidation(borrowRate: bigint): bigint;
|
|
272
|
+
//#endregion
|
|
@@ -4,8 +4,7 @@ import "../../utils/index.js";
|
|
|
4
4
|
import "../../base/index.js";
|
|
5
5
|
import { Address } from "viem";
|
|
6
6
|
//#region src/onchain/market/oracle/PriceFeedAnswerMap.d.ts
|
|
7
|
-
|
|
7
|
+
export default class PriceFeedAnswerMap extends AddressMap<PriceFeedAnswer> {
|
|
8
8
|
price(token: Address): bigint;
|
|
9
9
|
}
|
|
10
|
-
//#endregion
|
|
11
|
-
export { PriceFeedAnswerMap as default };
|
|
10
|
+
//#endregion
|
|
@@ -30,7 +30,7 @@ import { Abi, Address } from "viem";
|
|
|
30
30
|
*
|
|
31
31
|
* @typeParam abi - The concrete oracle contract's ABI type.
|
|
32
32
|
**/
|
|
33
|
-
declare abstract class PriceOracleBaseContract<abi extends Abi | readonly unknown[]> extends BaseContract<abi> implements IPriceOracleContract {
|
|
33
|
+
export declare abstract class PriceOracleBaseContract<abi extends Abi | readonly unknown[]> extends BaseContract<abi> implements IPriceOracleContract {
|
|
34
34
|
#private;
|
|
35
35
|
readonly sdk: OnchainSDK;
|
|
36
36
|
/**
|
|
@@ -145,5 +145,4 @@ declare abstract class PriceOracleBaseContract<abi extends Abi | readonly unknow
|
|
|
145
145
|
**/
|
|
146
146
|
stateHuman(raw?: boolean): PriceOracleStateHuman;
|
|
147
147
|
}
|
|
148
|
-
//#endregion
|
|
149
|
-
export { PriceOracleBaseContract };
|
|
148
|
+
//#endregion
|
|
@@ -340,7 +340,7 @@ declare const abi: readonly [{
|
|
|
340
340
|
readonly name: "SetReservePriceFeed";
|
|
341
341
|
}];
|
|
342
342
|
type abi = typeof abi;
|
|
343
|
-
declare class PriceOracleV310Contract extends PriceOracleBaseContract<abi> {
|
|
343
|
+
export declare class PriceOracleV310Contract extends PriceOracleBaseContract<abi> {
|
|
344
344
|
constructor(sdk: OnchainSDK, data: PriceOracleData);
|
|
345
345
|
/**
|
|
346
346
|
* {@inheritDoc IPriceOracleContract.updateAndConvert}
|
|
@@ -349,4 +349,4 @@ declare class PriceOracleV310Contract extends PriceOracleBaseContract<abi> {
|
|
|
349
349
|
processLog(log: Log<bigint, number, false, undefined, undefined, abi, ContractEventName<abi>>): void;
|
|
350
350
|
}
|
|
351
351
|
//#endregion
|
|
352
|
-
export {
|
|
352
|
+
export {};
|
|
@@ -14,6 +14,5 @@ import { Address } from "viem";
|
|
|
14
14
|
* underlying at zero — a screen shows a gap rather than a number derived from
|
|
15
15
|
* a missing feed.
|
|
16
16
|
**/
|
|
17
|
-
declare function collateralPriceInUnderlying(oracle: IPriceOracleContract, collateral: Address, underlying: Address): bigint | null;
|
|
18
|
-
//#endregion
|
|
19
|
-
export { collateralPriceInUnderlying };
|
|
17
|
+
export declare function collateralPriceInUnderlying(oracle: IPriceOracleContract, collateral: Address, underlying: Address): bigint | null;
|
|
18
|
+
//#endregion
|
|
@@ -3,6 +3,5 @@ import { IPriceOracleContract } from "./types.js";
|
|
|
3
3
|
import { OnchainSDK } from "../../OnchainSDK.js";
|
|
4
4
|
import "../../base/index.js";
|
|
5
5
|
//#region src/onchain/market/oracle/createPriceOracle.d.ts
|
|
6
|
-
declare function createPriceOracle(sdk: OnchainSDK, data: PriceOracleData): IPriceOracleContract;
|
|
7
|
-
//#endregion
|
|
8
|
-
export { createPriceOracle };
|
|
6
|
+
export declare function createPriceOracle(sdk: OnchainSDK, data: PriceOracleData): IPriceOracleContract;
|
|
7
|
+
//#endregion
|
|
@@ -22,7 +22,7 @@ import { Address } from "viem";
|
|
|
22
22
|
* Filter controlling which feed types to include when querying
|
|
23
23
|
* price feeds for a set of tokens. Both default to `true`.
|
|
24
24
|
**/
|
|
25
|
-
interface PriceFeedsForTokensOptions {
|
|
25
|
+
export interface PriceFeedsForTokensOptions {
|
|
26
26
|
/**
|
|
27
27
|
* Include main (primary) price feeds.
|
|
28
28
|
* @default true
|
|
@@ -38,7 +38,7 @@ interface PriceFeedsForTokensOptions {
|
|
|
38
38
|
* Filter and extra inputs controlling which feeds to update for a credit
|
|
39
39
|
* account.
|
|
40
40
|
**/
|
|
41
|
-
interface PriceFeedsForAccountOptions extends PriceFeedsForTokensOptions {
|
|
41
|
+
export interface PriceFeedsForAccountOptions extends PriceFeedsForTokensOptions {
|
|
42
42
|
/**
|
|
43
43
|
* Extra tokens to price alongside the account's underlying and its enabled
|
|
44
44
|
* non-dust balances.
|
|
@@ -48,14 +48,14 @@ interface PriceFeedsForAccountOptions extends PriceFeedsForTokensOptions {
|
|
|
48
48
|
/**
|
|
49
49
|
* Token-to-token conversion at latest known prices, result in `to`-token decimals.
|
|
50
50
|
*/
|
|
51
|
-
type ConvertFn = (from: Address, to: Address, amount: bigint) => bigint;
|
|
51
|
+
export type ConvertFn = (from: Address, to: Address, amount: bigint) => bigint;
|
|
52
52
|
/**
|
|
53
53
|
* Public interface for a Gearbox price oracle contract.
|
|
54
54
|
*
|
|
55
55
|
* Each Gearbox market has one price oracle that aggregates USD-denominated
|
|
56
56
|
* price feeds for every collateral token.
|
|
57
57
|
**/
|
|
58
|
-
interface IPriceOracleContract extends IBaseContract {
|
|
58
|
+
export interface IPriceOracleContract extends IBaseContract {
|
|
59
59
|
/**
|
|
60
60
|
* All price feed contract instances known to this oracle
|
|
61
61
|
**/
|
|
@@ -256,5 +256,4 @@ interface IPriceOracleContract extends IBaseContract {
|
|
|
256
256
|
**/
|
|
257
257
|
stateHuman: (raw?: boolean) => PriceOracleStateHuman;
|
|
258
258
|
}
|
|
259
|
-
//#endregion
|
|
260
|
-
export { ConvertFn, IPriceOracleContract, PriceFeedsForAccountOptions, PriceFeedsForTokensOptions };
|
|
259
|
+
//#endregion
|
|
@@ -385,14 +385,14 @@ declare const abi: readonly [{
|
|
|
385
385
|
readonly name: "Vote";
|
|
386
386
|
}];
|
|
387
387
|
type abi = typeof abi;
|
|
388
|
-
interface GaugeParams {
|
|
388
|
+
export interface GaugeParams {
|
|
389
389
|
minRate: number;
|
|
390
390
|
maxRate: number;
|
|
391
391
|
totalVotesLpSide: bigint;
|
|
392
392
|
totalVotesCaSide: bigint;
|
|
393
393
|
rate: number;
|
|
394
394
|
}
|
|
395
|
-
declare class GaugeContract extends BaseContract<abi> implements IRateKeeperContract {
|
|
395
|
+
export declare class GaugeContract extends BaseContract<abi> implements IRateKeeperContract {
|
|
396
396
|
readonly quotaParams: AddressMap<GaugeParams>;
|
|
397
397
|
readonly epochFrozen: boolean;
|
|
398
398
|
readonly epochLastUpdate: number;
|
|
@@ -402,4 +402,4 @@ declare class GaugeContract extends BaseContract<abi> implements IRateKeeperCont
|
|
|
402
402
|
stateHuman(raw?: boolean): GaugeStateHuman;
|
|
403
403
|
}
|
|
404
404
|
//#endregion
|
|
405
|
-
export {
|
|
405
|
+
export {};
|
|
@@ -121,7 +121,7 @@ declare const abi: readonly [{
|
|
|
121
121
|
readonly stateMutability: "view";
|
|
122
122
|
}];
|
|
123
123
|
type abi = typeof abi;
|
|
124
|
-
declare class LinearInterestRateModelContract extends BaseContract<abi> implements IInterestRateModelContract {
|
|
124
|
+
export declare class LinearInterestRateModelContract extends BaseContract<abi> implements IInterestRateModelContract {
|
|
125
125
|
readonly U1: number;
|
|
126
126
|
readonly U2: number;
|
|
127
127
|
readonly Rbase: number;
|
|
@@ -142,4 +142,4 @@ declare class LinearInterestRateModelContract extends BaseContract<abi> implemen
|
|
|
142
142
|
stateHuman(raw?: boolean): LinearInterestRateModelStateHuman;
|
|
143
143
|
}
|
|
144
144
|
//#endregion
|
|
145
|
-
export {
|
|
145
|
+
export {};
|
|
@@ -475,7 +475,7 @@ declare const abi: readonly [{
|
|
|
475
475
|
readonly name: "UpdateTokenQuotaRate";
|
|
476
476
|
}];
|
|
477
477
|
type abi = typeof abi;
|
|
478
|
-
declare class PoolQuotaKeeperV310Contract extends BaseContract<abi> implements IBaseContract {
|
|
478
|
+
export declare class PoolQuotaKeeperV310Contract extends BaseContract<abi> implements IBaseContract {
|
|
479
479
|
readonly decimals: number;
|
|
480
480
|
readonly quotas: AddressMap<QuotaState>;
|
|
481
481
|
constructor(options: ConstructOptions, pool: PoolState, pqk: QuotaKeeperState);
|
|
@@ -509,4 +509,4 @@ declare class PoolQuotaKeeperV310Contract extends BaseContract<abi> implements I
|
|
|
509
509
|
processLog(log: Log<bigint, number, false, undefined, undefined, abi, ContractEventName<abi>>): void;
|
|
510
510
|
}
|
|
511
511
|
//#endregion
|
|
512
|
-
export {
|
|
512
|
+
export {};
|
|
@@ -25,7 +25,7 @@ import { Address } from "viem";
|
|
|
25
25
|
* this class when they need the complete pool control plane instead of a single
|
|
26
26
|
* contract wrapper.
|
|
27
27
|
*/
|
|
28
|
-
declare class PoolSuite extends SDKConstruct {
|
|
28
|
+
export declare class PoolSuite extends SDKConstruct {
|
|
29
29
|
#private;
|
|
30
30
|
/**
|
|
31
31
|
* ERC-4626 liquidity pool wrapper for deposits, withdrawals, borrowing
|
|
@@ -122,5 +122,4 @@ declare class PoolSuite extends SDKConstruct {
|
|
|
122
122
|
*/
|
|
123
123
|
stateHuman(raw?: boolean): PoolSuiteStateHuman;
|
|
124
124
|
}
|
|
125
|
-
//#endregion
|
|
126
|
-
export { PoolSuite };
|
|
125
|
+
//#endregion
|