@pendle/core-v2 2.17.7-tradingbot → 2.18.0-tradingbot
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/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiveEndpointUpg.sol/PendleMsgReceiveEndpointUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiverAppUpg.sol/PendleMsgReceiverAppUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSendEndpointUpg.sol/PendleMsgSendEndpointUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSenderAppUpg.sol/PendleMsgSenderAppUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/libraries/LayerZeroHelper.sol/LayerZeroHelper.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol/PendleGaugeControllerBaseUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VeDistributor/PendleFeeDistributorV2.sol/PendleFeeDistributorV2.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingController/VotingControllerStorageUpg.sol/VotingControllerStorageUpg.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol/VotingEscrowTokenBase.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.dbg.json +1 -1
- package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.dbg.json +1 -1
- package/build/artifacts/contracts/core/BulkSeller/BulkSeller.sol/BulkSeller.dbg.json +1 -1
- package/build/artifacts/contracts/core/BulkSeller/BulkSellerFactory.sol/BulkSellerFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/BulkSeller/BulkSellerMathCore.sol/BulkSellerMathCore.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleGauge.sol/PendleGauge.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarket.sol/PendleMarket.dbg.json +1 -1
- package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/RewardManager/RewardManager.sol/RewardManager.dbg.json +1 -1
- package/build/artifacts/contracts/core/RewardManager/RewardManagerAbstract.sol/RewardManagerAbstract.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/PYIndex.sol/PYIndexLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/SYBase.sol/SYBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/SYBaseWithRewards.sol/SYBaseWithRewards.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Ape/sAPE.sol/sAPE.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraBbAWethSwethSY.sol/PendleAuraBbAWethSwethSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethAnkrethSYV2.sol/PendleAuraWethAnkrethSYV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethRocketEthSYV2.sol/PendleAuraWethRocketEthSYV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethStafiEthSY.sol/PendleAuraWethStafiEthSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethWstethSYV2.sol/PendleAuraWethWstethSYV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStableMath.sol/ComposableStableMath.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStablePreview.sol/ComposableStablePreview.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/Linear/BbAPoolHelper.sol/BbAPoolHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/Linear/BbAPoolHelper.sol/BbAWethHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/Linear/LinearMath.sol/LinearMath.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/Linear/LinearPreview.sol/LinearPreview.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStablePreview.sol/MetaStablePreview.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/PendleAuraBalancerStableLPSYV2.sol/PendleAuraBalancerStableLPSYV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePreviewBase.sol/StablePreviewBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenSY.sol/PendleQiTokenSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/CamelotV1Volatile/CamelotRewardHelper.sol/CamelotRewardHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/CamelotV1Volatile/CamelotV1VolatileCommon.sol/CamelotV1VolatileCommon.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/CamelotV1Volatile/CamelotV1VolatileLpHelper.sol/CamelotV1VolatileLpHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/CamelotV1Volatile/CamelotV1VolatilePreview.sol/CamelotV1VolatilePreview.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/CamelotV1Volatile/PendleCamelotV1VolatileSY.sol/PendleCamelotV1VolatileSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveFraxUsdcSY.sol/PendleCurveFraxUsdcSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveUsdd3CrvSY.sol/PendleCurveUsdd3CrvSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/Curve3CrvPoolHelper.sol/Curve3CrvPoolHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/CurveFraxUsdcPoolHelper.sol/CurveFraxUsdcPoolHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/CurveUsdd3CrvPoolHelper.sol/CurveUsdd3CrvPoolHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/PendleConvexLPSY.sol/PendleConvexLPSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/GLP/PendleGlpSY.sol/PendleGlpSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleGdaiSY.sol/PendleGDaiSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleLooksStakingSY.sol/PendleLooksStakingSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleSfrxEthSY.sol/PendleSfrxEthSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleStargateLPSY.sol/PendleStargateLPSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleWstEthSY.sol/PendleWstEthSY.dbg.json +1 -1
- package/build/artifacts/contracts/core/TradingBot/BotActionCallback.sol/BotActionCallback.dbg.json +1 -1
- package/build/artifacts/contracts/core/TradingBot/BotActionCallback.sol/BotActionCallback.json +32 -17
- package/build/artifacts/contracts/core/TradingBot/BotActionHelper.sol/BotActionHelper.dbg.json +1 -1
- package/build/artifacts/contracts/core/TradingBot/BotActionHelper.sol/BotActionHelper.json +32 -17
- package/build/artifacts/contracts/core/TradingBot/BotSimulationLib.sol/BotSimulationLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/TradingBot/BotSimulationLib.sol/BotSimulationLib.json +2 -2
- package/build/artifacts/contracts/core/TradingBot/LongYieldDecisionHelper.sol/LongYieldDecisionHelper.dbg.json +4 -0
- package/build/artifacts/contracts/core/TradingBot/LongYieldDecisionHelper.sol/LongYieldDecisionHelper.json +1190 -0
- package/build/artifacts/contracts/core/TradingBot/LongYieldTradingBot.sol/LongYieldTradingBot.dbg.json +1 -1
- package/build/artifacts/contracts/core/TradingBot/LongYieldTradingBot.sol/LongYieldTradingBot.json +301 -397
- package/build/artifacts/contracts/core/TradingBot/MarketExtLib.sol/MarketExtLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/TradingBot/SpecSegmentLib.sol/SpecSegmentLib.dbg.json +4 -0
- package/build/artifacts/contracts/core/TradingBot/SpecSegmentLib.sol/SpecSegmentLib.json +10 -0
- package/build/artifacts/contracts/core/TradingBot/TradingBotBase.sol/TradingBotBase.dbg.json +1 -1
- package/build/artifacts/contracts/core/TradingBot/TradingBotBase.sol/TradingBotBase.json +32 -17
- package/build/artifacts/contracts/core/YieldContracts/InterestManagerYT.sol/InterestManagerYT.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendlePrincipalToken.sol/PendlePrincipalToken.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactory.sol/PendleYieldContractFactory.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContractsV2/InterestManagerYTV2.sol/InterestManagerYTV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContractsV2/PendlePrincipalTokenV2.sol/PendlePrincipalTokenV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContractsV2/PendleYieldContractFactoryV2.sol/PendleYieldContractFactoryV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/YieldContractsV2/PendleYieldTokenV2.sol/PendleYieldTokenV2.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/TokenAmountLib.sol/TokenAmountLib.dbg.json +1 -1
- package/build/artifacts/contracts/core/libraries/math/Math.sol/Math.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/Balancer/IBalancerStablePreview.sol/IBalancerStablePreview.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/Balancer/IERC4626LinearPool.sol/IERC4626LinearPool.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/Balancer/IVault.sol/IVault.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/Camelot/ICamelotNFTPool.sol/ICamelotNFTPool.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/Camelot/ICamelotNitroPool.sol/ICamelotNitroPool.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/Camelot/ICamelotPair.sol/ICamelotPair.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionAddRemoveLiq.sol/IPActionAddRemoveLiq.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionInfoStatic.sol/IPActionInfoStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMarketAuxStatic.sol/IPActionMarketAuxStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMarketCoreStatic.sol/IPActionMarketCoreStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMintRedeem.sol/IPActionMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionMintRedeemStatic.sol/IPActionMintRedeemStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionStorageStatic.sol/IPActionStorageStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapPT.sol/IPActionSwapPT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPActionSwapYT.sol/IPActionSwapYT.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPBulkSeller.sol/IPBulkSeller.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPGauge.sol/IPGauge.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPMarket.sol/IPMarket.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPRouterHelper.sol/IPRouterHelper.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPRouterStatic.sol/IPRouterStatic.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingController.sol/IPVotingController.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPVotingEscrowMainchain.sol/IPVotingEscrowMainchain.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IPYieldContractFactory.sol/IPYieldContractFactory.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/IStandardizedYield.sol/IStandardizedYield.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/TradingBot/IBotDecisionHelper.sol/IBotDecisionHelper.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/TradingBot/IBotDecisionHelper.sol/IBotDecisionHelper.json +542 -581
- package/build/artifacts/contracts/interfaces/TradingBot/ILongYieldTradingBot.sol/ILongYieldTradingBot.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/TradingBot/ILongYieldTradingBot.sol/ILongYieldTradingBot.json +256 -325
- package/build/artifacts/contracts/interfaces/TradingBot/ITradingBotBase.sol/ITradingBotBase.dbg.json +1 -1
- package/build/artifacts/contracts/interfaces/TradingBot/ITradingBotBase.sol/ITradingBotBase.json +6 -17
- package/build/artifacts/contracts/offchain-helpers/BoringLpSeller.sol/BoringLpSeller.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BoringPtSeller.sol/BoringPtSeller.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/Broadcaster.sol/Broadcaster.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/BulkSellerOffchain.sol/BulkSellerOffchain.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/MarketExchangeRateLib.sol/MarketExchangeRateLib.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/PendleRouterStatic.sol/PendleRouterStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionInfoStatic.sol/ActionInfoStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMarketAuxStatic.sol/ActionMarketAuxStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMarketCoreStatic.sol/ActionMarketCoreStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionMintRedeemStatic.sol/ActionMintRedeemStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionStorageStatic.sol/ActionStorageStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/ActionVePendleStatic.sol/ActionVePendleStatic.dbg.json +1 -1
- package/build/artifacts/contracts/offchain-helpers/router-static/base/StorageLayout.sol/StorageLayout.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PendleLpOracleLib.sol/PendleLpOracleLib.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PendlePtOracle.sol/PendlePtOracle.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/PendlePtOracleLib.sol/PendlePtOracleLib.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/samples/PendleLpGlpOracle.sol/PendleLpGlpOracle.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/samples/PendlePtGlpOracle.sol/PendlePtGlpOracle.dbg.json +1 -1
- package/build/artifacts/contracts/oracles/samples/PendlePtUsdChainlinkOracle.sol/PendlePtUsdChainlinkOracle.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionMintRedeem.sol/ActionMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionSwapPT.sol/ActionSwapPT.dbg.json +1 -1
- package/build/artifacts/contracts/router/ActionSwapYT.sol/ActionSwapYT.dbg.json +1 -1
- package/build/artifacts/contracts/router/PendleRouter.sol/PendleRouter.dbg.json +1 -1
- package/build/artifacts/contracts/router/PendleRouterHelper.sol/PendleRouterHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/ActionBaseCallback.sol/ActionBaseCallback.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/ActionBaseMintRedeem.sol/ActionBaseMintRedeem.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/CallbackHelper.sol/CallbackHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtInLib.dbg.json +1 -1
- package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtOutLib.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/PendleSwap.sol/PendleSwap.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/kyberswap/IAggregationExecutor.sol/IAggregationExecutor.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/kyberswap/IExecutorHelper.sol/IExecutorHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/kyberswap/IHashflow.sol/IHashflow.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/kyberswap/IMetaAggregationRouterV2.sol/IMetaAggregationRouterV2.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/kyberswap/KyberInputScalingHelper.sol/KyberInputScalingHelper.dbg.json +1 -1
- package/build/artifacts/contracts/router/swap-aggregator/kyberswap/ScalingDataLib.sol/ScalingDataLib.dbg.json +1 -1
- package/contracts/core/TradingBot/BotActionCallback.sol +1 -1
- package/contracts/core/TradingBot/BotActionHelper.sol +1 -3
- package/contracts/core/TradingBot/BotSimulationLib.sol +2 -1
- package/contracts/core/TradingBot/LongYieldDecisionHelper.sol +413 -0
- package/contracts/core/TradingBot/LongYieldTradingBot.sol +63 -91
- package/contracts/core/TradingBot/SpecSegmentLib.sol +62 -0
- package/contracts/core/TradingBot/TradingBotBase.sol +14 -9
- package/contracts/interfaces/TradingBot/IBotDecisionHelper.sol +41 -57
- package/contracts/interfaces/TradingBot/ILongYieldTradingBot.sol +24 -34
- package/contracts/interfaces/TradingBot/ITradingBotBase.sol +1 -3
- package/package.json +1 -1
- package/typechain-types/BotActionCallback.ts +40 -22
- package/typechain-types/BotActionHelper.ts +40 -22
- package/typechain-types/BotDecisionHelper.ts +221 -187
- package/typechain-types/IAnkrBNB.ts +150 -0
- package/typechain-types/IAnkrLiquidStaking.ts +253 -0
- package/typechain-types/IBotDecisionHelper.ts +142 -212
- package/typechain-types/ILongYieldTradingBot.ts +147 -230
- package/typechain-types/ISwETH.ts +123 -0
- package/typechain-types/ITradingBotBase.ts +14 -22
- package/typechain-types/LongYieldDecisionHelper.ts +598 -0
- package/typechain-types/LongYieldTradingBot.ts +191 -248
- package/typechain-types/PendleAnkrBNBSY.ts +1235 -0
- package/typechain-types/PendleAuraWstethAnkreth.ts +1511 -0
- package/typechain-types/PendleSwETH.ts +1216 -0
- package/typechain-types/PendleThenaSY.ts +153 -0
- package/typechain-types/PendleWbEthSY.ts +1229 -0
- package/typechain-types/ThenaLpHelper.ts +19 -0
- package/typechain-types/ThenaMath.ts +87 -0
- package/typechain-types/ThenaPreview.ts +19 -0
- package/typechain-types/TradingBotBase.ts +40 -22
- package/typechain-types/factories/BotActionCallback__factory.ts +31 -16
- package/typechain-types/factories/BotActionHelper__factory.ts +31 -16
- package/typechain-types/factories/BotDecisionHelper__factory.ts +490 -421
- package/typechain-types/factories/IAnkrBNB__factory.ts +74 -0
- package/typechain-types/factories/IAnkrLiquidStaking__factory.ts +123 -0
- package/typechain-types/factories/IBotDecisionHelper__factory.ts +540 -579
- package/typechain-types/factories/ILongYieldTradingBot__factory.ts +255 -324
- package/typechain-types/factories/ISwETH__factory.ts +53 -0
- package/typechain-types/factories/ITradingBotBase__factory.ts +6 -17
- package/typechain-types/factories/LongYieldDecisionHelper__factory.ts +1247 -0
- package/typechain-types/factories/LongYieldTradingBot__factory.ts +301 -393
- package/typechain-types/factories/PendleAnkrBNBSY__factory.ts +1100 -0
- package/typechain-types/factories/PendleAuraWstethAnkreth__factory.ts +1244 -0
- package/typechain-types/factories/PendleSwETH__factory.ts +1022 -0
- package/typechain-types/factories/PendleThenaSY__factory.ts +85 -1
- package/typechain-types/factories/PendleWbEthSY__factory.ts +1049 -0
- package/typechain-types/factories/PtAndLpToAsset__factory.ts +1 -1
- package/typechain-types/factories/ThenaLpHelper__factory.ts +13 -0
- package/typechain-types/factories/ThenaMath__factory.ts +36 -0
- package/typechain-types/factories/ThenaPreview__factory.ts +14 -1
- package/typechain-types/factories/TradingBotBase__factory.ts +31 -16
- package/typechain-types/hardhat.d.ts +4 -40
- package/typechain-types/index.ts +2 -10
- package/build/artifacts/contracts/core/TradingBot/BotDecisionHelper.sol/BotDecisionHelper.dbg.json +0 -4
- package/build/artifacts/contracts/core/TradingBot/BotDecisionHelper.sol/BotDecisionHelper.json +0 -1070
- package/contracts/core/TradingBot/BotDecisionHelper.sol +0 -306
|
@@ -95,12 +95,19 @@ export type BotStateStruct = {
|
|
|
95
95
|
lpBalance: BigNumberish;
|
|
96
96
|
ytBalance: BigNumberish;
|
|
97
97
|
syBalance: BigNumberish;
|
|
98
|
+
buyBins: BigNumberish;
|
|
98
99
|
};
|
|
99
100
|
|
|
100
|
-
export type BotStateStructOutput = [
|
|
101
|
+
export type BotStateStructOutput = [
|
|
102
|
+
BigNumber,
|
|
103
|
+
BigNumber,
|
|
104
|
+
BigNumber,
|
|
105
|
+
BigNumber
|
|
106
|
+
] & {
|
|
101
107
|
lpBalance: BigNumber;
|
|
102
108
|
ytBalance: BigNumber;
|
|
103
109
|
syBalance: BigNumber;
|
|
110
|
+
buyBins: BigNumber;
|
|
104
111
|
};
|
|
105
112
|
|
|
106
113
|
export type MarketStateStruct = {
|
|
@@ -150,12 +157,12 @@ export type MarketExtStateStructOutput = [
|
|
|
150
157
|
] & { state: MarketStateStructOutput; index: BigNumber; blockTime: BigNumber };
|
|
151
158
|
|
|
152
159
|
export type LongTradingSpecsStruct = {
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
160
|
+
buyYtIy: BigNumberish;
|
|
161
|
+
sellYtIy: BigNumberish;
|
|
162
|
+
targetSyRatio: BigNumberish;
|
|
163
|
+
maxSyRatio: BigNumberish;
|
|
164
|
+
minYtPtRatio: BigNumberish;
|
|
165
|
+
numOfBins: BigNumberish;
|
|
159
166
|
};
|
|
160
167
|
|
|
161
168
|
export type LongTradingSpecsStructOutput = [
|
|
@@ -166,14 +173,73 @@ export type LongTradingSpecsStructOutput = [
|
|
|
166
173
|
BigNumber,
|
|
167
174
|
BigNumber
|
|
168
175
|
] & {
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
176
|
+
buyYtIy: BigNumber;
|
|
177
|
+
sellYtIy: BigNumber;
|
|
178
|
+
targetSyRatio: BigNumber;
|
|
179
|
+
maxSyRatio: BigNumber;
|
|
180
|
+
minYtPtRatio: BigNumber;
|
|
181
|
+
numOfBins: BigNumber;
|
|
182
|
+
};
|
|
183
|
+
|
|
184
|
+
export type StrategyDataStruct = {
|
|
185
|
+
botState: BotStateStruct;
|
|
186
|
+
marketExt: MarketExtStateStruct;
|
|
187
|
+
specs: LongTradingSpecsStruct;
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
export type StrategyDataStructOutput = [
|
|
191
|
+
BotStateStructOutput,
|
|
192
|
+
MarketExtStateStructOutput,
|
|
193
|
+
LongTradingSpecsStructOutput
|
|
194
|
+
] & {
|
|
195
|
+
botState: BotStateStructOutput;
|
|
196
|
+
marketExt: MarketExtStateStructOutput;
|
|
197
|
+
specs: LongTradingSpecsStructOutput;
|
|
175
198
|
};
|
|
176
199
|
|
|
200
|
+
export declare namespace ILongYieldTradingBot {
|
|
201
|
+
export type AddLiqFromYtInputStruct = {
|
|
202
|
+
botParams: ApproxParamsStruct;
|
|
203
|
+
minLpOut: BigNumberish;
|
|
204
|
+
targetIy: BigNumberish;
|
|
205
|
+
currentBin: BigNumberish;
|
|
206
|
+
};
|
|
207
|
+
|
|
208
|
+
export type AddLiqFromYtInputStructOutput = [
|
|
209
|
+
ApproxParamsStructOutput,
|
|
210
|
+
BigNumber,
|
|
211
|
+
BigNumber,
|
|
212
|
+
BigNumber
|
|
213
|
+
] & {
|
|
214
|
+
botParams: ApproxParamsStructOutput;
|
|
215
|
+
minLpOut: BigNumber;
|
|
216
|
+
targetIy: BigNumber;
|
|
217
|
+
currentBin: BigNumber;
|
|
218
|
+
};
|
|
219
|
+
|
|
220
|
+
export type RemoveLiqToYtInputStruct = {
|
|
221
|
+
botParams: ApproxParamsStruct;
|
|
222
|
+
guessTotalPtToSwap: ApproxParamsStruct;
|
|
223
|
+
minYtOut: BigNumberish;
|
|
224
|
+
targetIy: BigNumberish;
|
|
225
|
+
currentBin: BigNumberish;
|
|
226
|
+
};
|
|
227
|
+
|
|
228
|
+
export type RemoveLiqToYtInputStructOutput = [
|
|
229
|
+
ApproxParamsStructOutput,
|
|
230
|
+
ApproxParamsStructOutput,
|
|
231
|
+
BigNumber,
|
|
232
|
+
BigNumber,
|
|
233
|
+
BigNumber
|
|
234
|
+
] & {
|
|
235
|
+
botParams: ApproxParamsStructOutput;
|
|
236
|
+
guessTotalPtToSwap: ApproxParamsStructOutput;
|
|
237
|
+
minYtOut: BigNumber;
|
|
238
|
+
targetIy: BigNumber;
|
|
239
|
+
currentBin: BigNumber;
|
|
240
|
+
};
|
|
241
|
+
}
|
|
242
|
+
|
|
177
243
|
export declare namespace ITradingBotBase {
|
|
178
244
|
export type MultiApprovalStruct = { tokens: string[]; spender: string };
|
|
179
245
|
|
|
@@ -186,39 +252,28 @@ export declare namespace ITradingBotBase {
|
|
|
186
252
|
export interface ILongYieldTradingBotInterface extends utils.Interface {
|
|
187
253
|
contractName: "ILongYieldTradingBot";
|
|
188
254
|
functions: {
|
|
189
|
-
"
|
|
190
|
-
"
|
|
191
|
-
"addLiqKeepYt(address,(uint256,uint256,uint256,uint256,uint256),uint256,uint256,uint256)": FunctionFragment;
|
|
255
|
+
"addLiqFromYt(((uint256,uint256,uint256,uint256,uint256),uint256,uint256,int256))": FunctionFragment;
|
|
256
|
+
"addLiqKeepYt(uint256,uint256,uint256)": FunctionFragment;
|
|
192
257
|
"approveInf((address[],address)[])": FunctionFragment;
|
|
193
|
-
"claimAndCompound(
|
|
258
|
+
"claimAndCompound((address,uint256,address,address,address,(uint8,address,bytes,bool))[],uint256)": FunctionFragment;
|
|
194
259
|
"claimWithoutCompound()": FunctionFragment;
|
|
195
260
|
"depositSy(uint256)": FunctionFragment;
|
|
196
|
-
"depositToken(
|
|
261
|
+
"depositToken((address,uint256,address,address,address,(uint8,address,bytes,bool)),uint256)": FunctionFragment;
|
|
197
262
|
"readBotState()": FunctionFragment;
|
|
198
|
-
"readMarketExtState(
|
|
199
|
-
"
|
|
263
|
+
"readMarketExtState()": FunctionFragment;
|
|
264
|
+
"readStrategyData()": FunctionFragment;
|
|
265
|
+
"removeLiqToYt(((uint256,uint256,uint256,uint256,uint256),(uint256,uint256,uint256,uint256,uint256),uint256,uint256,int256))": FunctionFragment;
|
|
200
266
|
"setSpecs((uint256,uint256,uint256,uint256,uint256,uint256))": FunctionFragment;
|
|
201
|
-
"swapSyToYt(address,(uint256,uint256,uint256,uint256,uint256),uint256,uint256)": FunctionFragment;
|
|
202
267
|
"withdrawFunds(address,uint256)": FunctionFragment;
|
|
203
268
|
};
|
|
204
269
|
|
|
205
|
-
encodeFunctionData(
|
|
206
|
-
functionFragment: "addLiqFromSy",
|
|
207
|
-
values: [ApproxParamsStruct, BigNumberish, BigNumberish]
|
|
208
|
-
): string;
|
|
209
270
|
encodeFunctionData(
|
|
210
271
|
functionFragment: "addLiqFromYt",
|
|
211
|
-
values: [
|
|
272
|
+
values: [ILongYieldTradingBot.AddLiqFromYtInputStruct]
|
|
212
273
|
): string;
|
|
213
274
|
encodeFunctionData(
|
|
214
275
|
functionFragment: "addLiqKeepYt",
|
|
215
|
-
values: [
|
|
216
|
-
string,
|
|
217
|
-
ApproxParamsStruct,
|
|
218
|
-
BigNumberish,
|
|
219
|
-
BigNumberish,
|
|
220
|
-
BigNumberish
|
|
221
|
-
]
|
|
276
|
+
values: [BigNumberish, BigNumberish, BigNumberish]
|
|
222
277
|
): string;
|
|
223
278
|
encodeFunctionData(
|
|
224
279
|
functionFragment: "approveInf",
|
|
@@ -226,7 +281,7 @@ export interface ILongYieldTradingBotInterface extends utils.Interface {
|
|
|
226
281
|
): string;
|
|
227
282
|
encodeFunctionData(
|
|
228
283
|
functionFragment: "claimAndCompound",
|
|
229
|
-
values: [
|
|
284
|
+
values: [TokenInputStruct[], BigNumberish]
|
|
230
285
|
): string;
|
|
231
286
|
encodeFunctionData(
|
|
232
287
|
functionFragment: "claimWithoutCompound",
|
|
@@ -238,7 +293,7 @@ export interface ILongYieldTradingBotInterface extends utils.Interface {
|
|
|
238
293
|
): string;
|
|
239
294
|
encodeFunctionData(
|
|
240
295
|
functionFragment: "depositToken",
|
|
241
|
-
values: [
|
|
296
|
+
values: [TokenInputStruct, BigNumberish]
|
|
242
297
|
): string;
|
|
243
298
|
encodeFunctionData(
|
|
244
299
|
functionFragment: "readBotState",
|
|
@@ -246,29 +301,25 @@ export interface ILongYieldTradingBotInterface extends utils.Interface {
|
|
|
246
301
|
): string;
|
|
247
302
|
encodeFunctionData(
|
|
248
303
|
functionFragment: "readMarketExtState",
|
|
249
|
-
values
|
|
304
|
+
values?: undefined
|
|
305
|
+
): string;
|
|
306
|
+
encodeFunctionData(
|
|
307
|
+
functionFragment: "readStrategyData",
|
|
308
|
+
values?: undefined
|
|
250
309
|
): string;
|
|
251
310
|
encodeFunctionData(
|
|
252
311
|
functionFragment: "removeLiqToYt",
|
|
253
|
-
values: [
|
|
312
|
+
values: [ILongYieldTradingBot.RemoveLiqToYtInputStruct]
|
|
254
313
|
): string;
|
|
255
314
|
encodeFunctionData(
|
|
256
315
|
functionFragment: "setSpecs",
|
|
257
316
|
values: [LongTradingSpecsStruct]
|
|
258
317
|
): string;
|
|
259
|
-
encodeFunctionData(
|
|
260
|
-
functionFragment: "swapSyToYt",
|
|
261
|
-
values: [string, ApproxParamsStruct, BigNumberish, BigNumberish]
|
|
262
|
-
): string;
|
|
263
318
|
encodeFunctionData(
|
|
264
319
|
functionFragment: "withdrawFunds",
|
|
265
320
|
values: [string, BigNumberish]
|
|
266
321
|
): string;
|
|
267
322
|
|
|
268
|
-
decodeFunctionResult(
|
|
269
|
-
functionFragment: "addLiqFromSy",
|
|
270
|
-
data: BytesLike
|
|
271
|
-
): Result;
|
|
272
323
|
decodeFunctionResult(
|
|
273
324
|
functionFragment: "addLiqFromYt",
|
|
274
325
|
data: BytesLike
|
|
@@ -299,12 +350,15 @@ export interface ILongYieldTradingBotInterface extends utils.Interface {
|
|
|
299
350
|
functionFragment: "readMarketExtState",
|
|
300
351
|
data: BytesLike
|
|
301
352
|
): Result;
|
|
353
|
+
decodeFunctionResult(
|
|
354
|
+
functionFragment: "readStrategyData",
|
|
355
|
+
data: BytesLike
|
|
356
|
+
): Result;
|
|
302
357
|
decodeFunctionResult(
|
|
303
358
|
functionFragment: "removeLiqToYt",
|
|
304
359
|
data: BytesLike
|
|
305
360
|
): Result;
|
|
306
361
|
decodeFunctionResult(functionFragment: "setSpecs", data: BytesLike): Result;
|
|
307
|
-
decodeFunctionResult(functionFragment: "swapSyToYt", data: BytesLike): Result;
|
|
308
362
|
decodeFunctionResult(
|
|
309
363
|
functionFragment: "withdrawFunds",
|
|
310
364
|
data: BytesLike
|
|
@@ -312,12 +366,12 @@ export interface ILongYieldTradingBotInterface extends utils.Interface {
|
|
|
312
366
|
|
|
313
367
|
events: {
|
|
314
368
|
"AddLiqFromSy(tuple,uint256,uint256,uint256)": EventFragment;
|
|
315
|
-
"AddLiqFromYt(tuple,uint256,uint256
|
|
316
|
-
"AddLiqKeepYt(
|
|
369
|
+
"AddLiqFromYt(tuple,uint256,uint256)": EventFragment;
|
|
370
|
+
"AddLiqKeepYt(uint256,uint256,uint256)": EventFragment;
|
|
317
371
|
"ClaimAndCompound(uint256,uint256)": EventFragment;
|
|
318
372
|
"DepositSy(uint256)": EventFragment;
|
|
319
373
|
"DepositToken(address,uint256)": EventFragment;
|
|
320
|
-
"RemoveLiqToYt(tuple,uint256,uint256
|
|
374
|
+
"RemoveLiqToYt(tuple,uint256,uint256)": EventFragment;
|
|
321
375
|
"SwapSyToYt(tuple,uint256,uint256,uint256)": EventFragment;
|
|
322
376
|
"WithdrawFunds(address,uint256)": EventFragment;
|
|
323
377
|
};
|
|
@@ -346,10 +400,9 @@ export type AddLiqFromSyEvent = TypedEvent<
|
|
|
346
400
|
export type AddLiqFromSyEventFilter = TypedEventFilter<AddLiqFromSyEvent>;
|
|
347
401
|
|
|
348
402
|
export type AddLiqFromYtEvent = TypedEvent<
|
|
349
|
-
[ApproxParamsStructOutput, BigNumber, BigNumber
|
|
403
|
+
[ApproxParamsStructOutput, BigNumber, BigNumber],
|
|
350
404
|
{
|
|
351
405
|
botParams: ApproxParamsStructOutput;
|
|
352
|
-
maxYtIn: BigNumber;
|
|
353
406
|
netYtIn: BigNumber;
|
|
354
407
|
netLpOut: BigNumber;
|
|
355
408
|
}
|
|
@@ -358,14 +411,8 @@ export type AddLiqFromYtEvent = TypedEvent<
|
|
|
358
411
|
export type AddLiqFromYtEventFilter = TypedEventFilter<AddLiqFromYtEvent>;
|
|
359
412
|
|
|
360
413
|
export type AddLiqKeepYtEvent = TypedEvent<
|
|
361
|
-
[
|
|
362
|
-
{
|
|
363
|
-
botParams: ApproxParamsStructOutput;
|
|
364
|
-
maxSyIn: BigNumber;
|
|
365
|
-
netSyIn: BigNumber;
|
|
366
|
-
netLpOut: BigNumber;
|
|
367
|
-
netYtOut: BigNumber;
|
|
368
|
-
}
|
|
414
|
+
[BigNumber, BigNumber, BigNumber],
|
|
415
|
+
{ netSyIn: BigNumber; netLpOut: BigNumber; netYtOut: BigNumber }
|
|
369
416
|
>;
|
|
370
417
|
|
|
371
418
|
export type AddLiqKeepYtEventFilter = TypedEventFilter<AddLiqKeepYtEvent>;
|
|
@@ -390,10 +437,9 @@ export type DepositTokenEvent = TypedEvent<
|
|
|
390
437
|
export type DepositTokenEventFilter = TypedEventFilter<DepositTokenEvent>;
|
|
391
438
|
|
|
392
439
|
export type RemoveLiqToYtEvent = TypedEvent<
|
|
393
|
-
[ApproxParamsStructOutput, BigNumber, BigNumber
|
|
440
|
+
[ApproxParamsStructOutput, BigNumber, BigNumber],
|
|
394
441
|
{
|
|
395
442
|
botParams: ApproxParamsStructOutput;
|
|
396
|
-
maxLpRemoved: BigNumber;
|
|
397
443
|
netLpIn: BigNumber;
|
|
398
444
|
netYtOut: BigNumber;
|
|
399
445
|
}
|
|
@@ -448,24 +494,13 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
448
494
|
removeListener: OnEvent<this>;
|
|
449
495
|
|
|
450
496
|
functions: {
|
|
451
|
-
addLiqFromSy(
|
|
452
|
-
botParams: ApproxParamsStruct,
|
|
453
|
-
minLpOut: BigNumberish,
|
|
454
|
-
maxSyIn: BigNumberish,
|
|
455
|
-
overrides?: Overrides & { from?: string | Promise<string> }
|
|
456
|
-
): Promise<ContractTransaction>;
|
|
457
|
-
|
|
458
497
|
addLiqFromYt(
|
|
459
|
-
|
|
460
|
-
minLpOut: BigNumberish,
|
|
461
|
-
maxYtIn: BigNumberish,
|
|
498
|
+
inputParams: ILongYieldTradingBot.AddLiqFromYtInputStruct,
|
|
462
499
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
463
500
|
): Promise<ContractTransaction>;
|
|
464
501
|
|
|
465
502
|
addLiqKeepYt(
|
|
466
|
-
|
|
467
|
-
botParams: ApproxParamsStruct,
|
|
468
|
-
maxSyIn: BigNumberish,
|
|
503
|
+
netSyIn: BigNumberish,
|
|
469
504
|
minLpOut: BigNumberish,
|
|
470
505
|
minYtOut: BigNumberish,
|
|
471
506
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
@@ -477,7 +512,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
477
512
|
): Promise<ContractTransaction>;
|
|
478
513
|
|
|
479
514
|
claimAndCompound(
|
|
480
|
-
router: string,
|
|
481
515
|
inps: TokenInputStruct[],
|
|
482
516
|
minSyOut: BigNumberish,
|
|
483
517
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
@@ -493,7 +527,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
493
527
|
): Promise<ContractTransaction>;
|
|
494
528
|
|
|
495
529
|
depositToken(
|
|
496
|
-
router: string,
|
|
497
530
|
inp: TokenInputStruct,
|
|
498
531
|
minSyOut: BigNumberish,
|
|
499
532
|
overrides?: PayableOverrides & { from?: string | Promise<string> }
|
|
@@ -504,28 +537,20 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
504
537
|
): Promise<[BotStateStructOutput] & { botState: BotStateStructOutput }>;
|
|
505
538
|
|
|
506
539
|
readMarketExtState(
|
|
507
|
-
router: string,
|
|
508
540
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
509
541
|
): Promise<ContractTransaction>;
|
|
510
542
|
|
|
511
|
-
|
|
512
|
-
botParams: ApproxParamsStruct,
|
|
513
|
-
guessTotalPtToSwap: ApproxParamsStruct,
|
|
514
|
-
maxLpRemoved: BigNumberish,
|
|
515
|
-
minYtOut: BigNumberish,
|
|
543
|
+
readStrategyData(
|
|
516
544
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
517
545
|
): Promise<ContractTransaction>;
|
|
518
546
|
|
|
519
|
-
|
|
520
|
-
|
|
547
|
+
removeLiqToYt(
|
|
548
|
+
inputParams: ILongYieldTradingBot.RemoveLiqToYtInputStruct,
|
|
521
549
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
522
550
|
): Promise<ContractTransaction>;
|
|
523
551
|
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
botParams: ApproxParamsStruct,
|
|
527
|
-
minYtOut: BigNumberish,
|
|
528
|
-
maxSyIn: BigNumberish,
|
|
552
|
+
setSpecs(
|
|
553
|
+
_specs: LongTradingSpecsStruct,
|
|
529
554
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
530
555
|
): Promise<ContractTransaction>;
|
|
531
556
|
|
|
@@ -536,24 +561,13 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
536
561
|
): Promise<ContractTransaction>;
|
|
537
562
|
};
|
|
538
563
|
|
|
539
|
-
addLiqFromSy(
|
|
540
|
-
botParams: ApproxParamsStruct,
|
|
541
|
-
minLpOut: BigNumberish,
|
|
542
|
-
maxSyIn: BigNumberish,
|
|
543
|
-
overrides?: Overrides & { from?: string | Promise<string> }
|
|
544
|
-
): Promise<ContractTransaction>;
|
|
545
|
-
|
|
546
564
|
addLiqFromYt(
|
|
547
|
-
|
|
548
|
-
minLpOut: BigNumberish,
|
|
549
|
-
maxYtIn: BigNumberish,
|
|
565
|
+
inputParams: ILongYieldTradingBot.AddLiqFromYtInputStruct,
|
|
550
566
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
551
567
|
): Promise<ContractTransaction>;
|
|
552
568
|
|
|
553
569
|
addLiqKeepYt(
|
|
554
|
-
|
|
555
|
-
botParams: ApproxParamsStruct,
|
|
556
|
-
maxSyIn: BigNumberish,
|
|
570
|
+
netSyIn: BigNumberish,
|
|
557
571
|
minLpOut: BigNumberish,
|
|
558
572
|
minYtOut: BigNumberish,
|
|
559
573
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
@@ -565,7 +579,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
565
579
|
): Promise<ContractTransaction>;
|
|
566
580
|
|
|
567
581
|
claimAndCompound(
|
|
568
|
-
router: string,
|
|
569
582
|
inps: TokenInputStruct[],
|
|
570
583
|
minSyOut: BigNumberish,
|
|
571
584
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
@@ -581,7 +594,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
581
594
|
): Promise<ContractTransaction>;
|
|
582
595
|
|
|
583
596
|
depositToken(
|
|
584
|
-
router: string,
|
|
585
597
|
inp: TokenInputStruct,
|
|
586
598
|
minSyOut: BigNumberish,
|
|
587
599
|
overrides?: PayableOverrides & { from?: string | Promise<string> }
|
|
@@ -590,28 +602,20 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
590
602
|
readBotState(overrides?: CallOverrides): Promise<BotStateStructOutput>;
|
|
591
603
|
|
|
592
604
|
readMarketExtState(
|
|
593
|
-
router: string,
|
|
594
605
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
595
606
|
): Promise<ContractTransaction>;
|
|
596
607
|
|
|
597
|
-
|
|
598
|
-
botParams: ApproxParamsStruct,
|
|
599
|
-
guessTotalPtToSwap: ApproxParamsStruct,
|
|
600
|
-
maxLpRemoved: BigNumberish,
|
|
601
|
-
minYtOut: BigNumberish,
|
|
608
|
+
readStrategyData(
|
|
602
609
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
603
610
|
): Promise<ContractTransaction>;
|
|
604
611
|
|
|
605
|
-
|
|
606
|
-
|
|
612
|
+
removeLiqToYt(
|
|
613
|
+
inputParams: ILongYieldTradingBot.RemoveLiqToYtInputStruct,
|
|
607
614
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
608
615
|
): Promise<ContractTransaction>;
|
|
609
616
|
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
botParams: ApproxParamsStruct,
|
|
613
|
-
minYtOut: BigNumberish,
|
|
614
|
-
maxSyIn: BigNumberish,
|
|
617
|
+
setSpecs(
|
|
618
|
+
_specs: LongTradingSpecsStruct,
|
|
615
619
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
616
620
|
): Promise<ContractTransaction>;
|
|
617
621
|
|
|
@@ -622,23 +626,8 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
622
626
|
): Promise<ContractTransaction>;
|
|
623
627
|
|
|
624
628
|
callStatic: {
|
|
625
|
-
addLiqFromSy(
|
|
626
|
-
botParams: ApproxParamsStruct,
|
|
627
|
-
minLpOut: BigNumberish,
|
|
628
|
-
maxSyIn: BigNumberish,
|
|
629
|
-
overrides?: CallOverrides
|
|
630
|
-
): Promise<
|
|
631
|
-
[BigNumber, BigNumber, BigNumber] & {
|
|
632
|
-
netPtFromSwap: BigNumber;
|
|
633
|
-
netLpOut: BigNumber;
|
|
634
|
-
netSyIn: BigNumber;
|
|
635
|
-
}
|
|
636
|
-
>;
|
|
637
|
-
|
|
638
629
|
addLiqFromYt(
|
|
639
|
-
|
|
640
|
-
minLpOut: BigNumberish,
|
|
641
|
-
maxYtIn: BigNumberish,
|
|
630
|
+
inputParams: ILongYieldTradingBot.AddLiqFromYtInputStruct,
|
|
642
631
|
overrides?: CallOverrides
|
|
643
632
|
): Promise<
|
|
644
633
|
[BigNumber, BigNumber, BigNumber] & {
|
|
@@ -649,18 +638,12 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
649
638
|
>;
|
|
650
639
|
|
|
651
640
|
addLiqKeepYt(
|
|
652
|
-
|
|
653
|
-
botParams: ApproxParamsStruct,
|
|
654
|
-
maxSyIn: BigNumberish,
|
|
641
|
+
netSyIn: BigNumberish,
|
|
655
642
|
minLpOut: BigNumberish,
|
|
656
643
|
minYtOut: BigNumberish,
|
|
657
644
|
overrides?: CallOverrides
|
|
658
645
|
): Promise<
|
|
659
|
-
[BigNumber, BigNumber
|
|
660
|
-
netSyIn: BigNumber;
|
|
661
|
-
netLpOut: BigNumber;
|
|
662
|
-
netYtOut: BigNumber;
|
|
663
|
-
}
|
|
646
|
+
[BigNumber, BigNumber] & { netLpOut: BigNumber; netYtOut: BigNumber }
|
|
664
647
|
>;
|
|
665
648
|
|
|
666
649
|
approveInf(
|
|
@@ -669,7 +652,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
669
652
|
): Promise<void>;
|
|
670
653
|
|
|
671
654
|
claimAndCompound(
|
|
672
|
-
router: string,
|
|
673
655
|
inps: TokenInputStruct[],
|
|
674
656
|
minSyOut: BigNumberish,
|
|
675
657
|
overrides?: CallOverrides
|
|
@@ -684,7 +666,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
684
666
|
depositSy(netSyIn: BigNumberish, overrides?: CallOverrides): Promise<void>;
|
|
685
667
|
|
|
686
668
|
depositToken(
|
|
687
|
-
router: string,
|
|
688
669
|
inp: TokenInputStruct,
|
|
689
670
|
minSyOut: BigNumberish,
|
|
690
671
|
overrides?: CallOverrides
|
|
@@ -693,22 +674,18 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
693
674
|
readBotState(overrides?: CallOverrides): Promise<BotStateStructOutput>;
|
|
694
675
|
|
|
695
676
|
readMarketExtState(
|
|
696
|
-
router: string,
|
|
697
677
|
overrides?: CallOverrides
|
|
698
678
|
): Promise<MarketExtStateStructOutput>;
|
|
699
679
|
|
|
680
|
+
readStrategyData(
|
|
681
|
+
overrides?: CallOverrides
|
|
682
|
+
): Promise<StrategyDataStructOutput>;
|
|
683
|
+
|
|
700
684
|
removeLiqToYt(
|
|
701
|
-
|
|
702
|
-
guessTotalPtToSwap: ApproxParamsStruct,
|
|
703
|
-
maxLpRemoved: BigNumberish,
|
|
704
|
-
minYtOut: BigNumberish,
|
|
685
|
+
inputParams: ILongYieldTradingBot.RemoveLiqToYtInputStruct,
|
|
705
686
|
overrides?: CallOverrides
|
|
706
687
|
): Promise<
|
|
707
|
-
[BigNumber, BigNumber
|
|
708
|
-
netLpRemoved: BigNumber;
|
|
709
|
-
netYtOut: BigNumber;
|
|
710
|
-
totalPtToSwap: BigNumber;
|
|
711
|
-
}
|
|
688
|
+
[BigNumber, BigNumber] & { netLpRemoved: BigNumber; netYtOut: BigNumber }
|
|
712
689
|
>;
|
|
713
690
|
|
|
714
691
|
setSpecs(
|
|
@@ -716,16 +693,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
716
693
|
overrides?: CallOverrides
|
|
717
694
|
): Promise<void>;
|
|
718
695
|
|
|
719
|
-
swapSyToYt(
|
|
720
|
-
router: string,
|
|
721
|
-
botParams: ApproxParamsStruct,
|
|
722
|
-
minYtOut: BigNumberish,
|
|
723
|
-
maxSyIn: BigNumberish,
|
|
724
|
-
overrides?: CallOverrides
|
|
725
|
-
): Promise<
|
|
726
|
-
[BigNumber, BigNumber] & { exactYtOut: BigNumber; netSyIn: BigNumber }
|
|
727
|
-
>;
|
|
728
|
-
|
|
729
696
|
withdrawFunds(
|
|
730
697
|
token: string,
|
|
731
698
|
amount: BigNumberish,
|
|
@@ -747,29 +714,23 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
747
714
|
netLpOut?: null
|
|
748
715
|
): AddLiqFromSyEventFilter;
|
|
749
716
|
|
|
750
|
-
"AddLiqFromYt(tuple,uint256,uint256
|
|
717
|
+
"AddLiqFromYt(tuple,uint256,uint256)"(
|
|
751
718
|
botParams?: null,
|
|
752
|
-
maxYtIn?: null,
|
|
753
719
|
netYtIn?: null,
|
|
754
720
|
netLpOut?: null
|
|
755
721
|
): AddLiqFromYtEventFilter;
|
|
756
722
|
AddLiqFromYt(
|
|
757
723
|
botParams?: null,
|
|
758
|
-
maxYtIn?: null,
|
|
759
724
|
netYtIn?: null,
|
|
760
725
|
netLpOut?: null
|
|
761
726
|
): AddLiqFromYtEventFilter;
|
|
762
727
|
|
|
763
|
-
"AddLiqKeepYt(
|
|
764
|
-
botParams?: null,
|
|
765
|
-
maxSyIn?: null,
|
|
728
|
+
"AddLiqKeepYt(uint256,uint256,uint256)"(
|
|
766
729
|
netSyIn?: null,
|
|
767
730
|
netLpOut?: null,
|
|
768
731
|
netYtOut?: null
|
|
769
732
|
): AddLiqKeepYtEventFilter;
|
|
770
733
|
AddLiqKeepYt(
|
|
771
|
-
botParams?: null,
|
|
772
|
-
maxSyIn?: null,
|
|
773
734
|
netSyIn?: null,
|
|
774
735
|
netLpOut?: null,
|
|
775
736
|
netYtOut?: null
|
|
@@ -796,15 +757,13 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
796
757
|
netTokenIn?: null
|
|
797
758
|
): DepositTokenEventFilter;
|
|
798
759
|
|
|
799
|
-
"RemoveLiqToYt(tuple,uint256,uint256
|
|
760
|
+
"RemoveLiqToYt(tuple,uint256,uint256)"(
|
|
800
761
|
botParams?: null,
|
|
801
|
-
maxLpRemoved?: null,
|
|
802
762
|
netLpIn?: null,
|
|
803
763
|
netYtOut?: null
|
|
804
764
|
): RemoveLiqToYtEventFilter;
|
|
805
765
|
RemoveLiqToYt(
|
|
806
766
|
botParams?: null,
|
|
807
|
-
maxLpRemoved?: null,
|
|
808
767
|
netLpIn?: null,
|
|
809
768
|
netYtOut?: null
|
|
810
769
|
): RemoveLiqToYtEventFilter;
|
|
@@ -833,24 +792,13 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
833
792
|
};
|
|
834
793
|
|
|
835
794
|
estimateGas: {
|
|
836
|
-
addLiqFromSy(
|
|
837
|
-
botParams: ApproxParamsStruct,
|
|
838
|
-
minLpOut: BigNumberish,
|
|
839
|
-
maxSyIn: BigNumberish,
|
|
840
|
-
overrides?: Overrides & { from?: string | Promise<string> }
|
|
841
|
-
): Promise<BigNumber>;
|
|
842
|
-
|
|
843
795
|
addLiqFromYt(
|
|
844
|
-
|
|
845
|
-
minLpOut: BigNumberish,
|
|
846
|
-
maxYtIn: BigNumberish,
|
|
796
|
+
inputParams: ILongYieldTradingBot.AddLiqFromYtInputStruct,
|
|
847
797
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
848
798
|
): Promise<BigNumber>;
|
|
849
799
|
|
|
850
800
|
addLiqKeepYt(
|
|
851
|
-
|
|
852
|
-
botParams: ApproxParamsStruct,
|
|
853
|
-
maxSyIn: BigNumberish,
|
|
801
|
+
netSyIn: BigNumberish,
|
|
854
802
|
minLpOut: BigNumberish,
|
|
855
803
|
minYtOut: BigNumberish,
|
|
856
804
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
@@ -862,7 +810,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
862
810
|
): Promise<BigNumber>;
|
|
863
811
|
|
|
864
812
|
claimAndCompound(
|
|
865
|
-
router: string,
|
|
866
813
|
inps: TokenInputStruct[],
|
|
867
814
|
minSyOut: BigNumberish,
|
|
868
815
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
@@ -878,7 +825,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
878
825
|
): Promise<BigNumber>;
|
|
879
826
|
|
|
880
827
|
depositToken(
|
|
881
|
-
router: string,
|
|
882
828
|
inp: TokenInputStruct,
|
|
883
829
|
minSyOut: BigNumberish,
|
|
884
830
|
overrides?: PayableOverrides & { from?: string | Promise<string> }
|
|
@@ -887,28 +833,20 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
887
833
|
readBotState(overrides?: CallOverrides): Promise<BigNumber>;
|
|
888
834
|
|
|
889
835
|
readMarketExtState(
|
|
890
|
-
router: string,
|
|
891
836
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
892
837
|
): Promise<BigNumber>;
|
|
893
838
|
|
|
894
|
-
|
|
895
|
-
botParams: ApproxParamsStruct,
|
|
896
|
-
guessTotalPtToSwap: ApproxParamsStruct,
|
|
897
|
-
maxLpRemoved: BigNumberish,
|
|
898
|
-
minYtOut: BigNumberish,
|
|
839
|
+
readStrategyData(
|
|
899
840
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
900
841
|
): Promise<BigNumber>;
|
|
901
842
|
|
|
902
|
-
|
|
903
|
-
|
|
843
|
+
removeLiqToYt(
|
|
844
|
+
inputParams: ILongYieldTradingBot.RemoveLiqToYtInputStruct,
|
|
904
845
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
905
846
|
): Promise<BigNumber>;
|
|
906
847
|
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
botParams: ApproxParamsStruct,
|
|
910
|
-
minYtOut: BigNumberish,
|
|
911
|
-
maxSyIn: BigNumberish,
|
|
848
|
+
setSpecs(
|
|
849
|
+
_specs: LongTradingSpecsStruct,
|
|
912
850
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
913
851
|
): Promise<BigNumber>;
|
|
914
852
|
|
|
@@ -920,24 +858,13 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
920
858
|
};
|
|
921
859
|
|
|
922
860
|
populateTransaction: {
|
|
923
|
-
addLiqFromSy(
|
|
924
|
-
botParams: ApproxParamsStruct,
|
|
925
|
-
minLpOut: BigNumberish,
|
|
926
|
-
maxSyIn: BigNumberish,
|
|
927
|
-
overrides?: Overrides & { from?: string | Promise<string> }
|
|
928
|
-
): Promise<PopulatedTransaction>;
|
|
929
|
-
|
|
930
861
|
addLiqFromYt(
|
|
931
|
-
|
|
932
|
-
minLpOut: BigNumberish,
|
|
933
|
-
maxYtIn: BigNumberish,
|
|
862
|
+
inputParams: ILongYieldTradingBot.AddLiqFromYtInputStruct,
|
|
934
863
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
935
864
|
): Promise<PopulatedTransaction>;
|
|
936
865
|
|
|
937
866
|
addLiqKeepYt(
|
|
938
|
-
|
|
939
|
-
botParams: ApproxParamsStruct,
|
|
940
|
-
maxSyIn: BigNumberish,
|
|
867
|
+
netSyIn: BigNumberish,
|
|
941
868
|
minLpOut: BigNumberish,
|
|
942
869
|
minYtOut: BigNumberish,
|
|
943
870
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
@@ -949,7 +876,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
949
876
|
): Promise<PopulatedTransaction>;
|
|
950
877
|
|
|
951
878
|
claimAndCompound(
|
|
952
|
-
router: string,
|
|
953
879
|
inps: TokenInputStruct[],
|
|
954
880
|
minSyOut: BigNumberish,
|
|
955
881
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
@@ -965,7 +891,6 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
965
891
|
): Promise<PopulatedTransaction>;
|
|
966
892
|
|
|
967
893
|
depositToken(
|
|
968
|
-
router: string,
|
|
969
894
|
inp: TokenInputStruct,
|
|
970
895
|
minSyOut: BigNumberish,
|
|
971
896
|
overrides?: PayableOverrides & { from?: string | Promise<string> }
|
|
@@ -974,28 +899,20 @@ export interface ILongYieldTradingBot extends BaseContract {
|
|
|
974
899
|
readBotState(overrides?: CallOverrides): Promise<PopulatedTransaction>;
|
|
975
900
|
|
|
976
901
|
readMarketExtState(
|
|
977
|
-
router: string,
|
|
978
902
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
979
903
|
): Promise<PopulatedTransaction>;
|
|
980
904
|
|
|
981
|
-
|
|
982
|
-
botParams: ApproxParamsStruct,
|
|
983
|
-
guessTotalPtToSwap: ApproxParamsStruct,
|
|
984
|
-
maxLpRemoved: BigNumberish,
|
|
985
|
-
minYtOut: BigNumberish,
|
|
905
|
+
readStrategyData(
|
|
986
906
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
987
907
|
): Promise<PopulatedTransaction>;
|
|
988
908
|
|
|
989
|
-
|
|
990
|
-
|
|
909
|
+
removeLiqToYt(
|
|
910
|
+
inputParams: ILongYieldTradingBot.RemoveLiqToYtInputStruct,
|
|
991
911
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
992
912
|
): Promise<PopulatedTransaction>;
|
|
993
913
|
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
botParams: ApproxParamsStruct,
|
|
997
|
-
minYtOut: BigNumberish,
|
|
998
|
-
maxSyIn: BigNumberish,
|
|
914
|
+
setSpecs(
|
|
915
|
+
_specs: LongTradingSpecsStruct,
|
|
999
916
|
overrides?: Overrides & { from?: string | Promise<string> }
|
|
1000
917
|
): Promise<PopulatedTransaction>;
|
|
1001
918
|
|