@pendle/core-v2 1.2.0-mainnet → 1.4.0-mainnet

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (365) hide show
  1. package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiveEndpointUpg.sol/PendleMsgReceiveEndpointUpg.dbg.json +1 -1
  2. package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiveEndpointUpg.sol/PendleMsgReceiveEndpointUpg.json +2 -2
  3. package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgReceiverAppUpg.sol/PendleMsgReceiverAppUpg.dbg.json +1 -1
  4. package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSendEndpointUpg.sol/PendleMsgSendEndpointUpg.dbg.json +1 -1
  5. package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSendEndpointUpg.sol/PendleMsgSendEndpointUpg.json +2 -2
  6. package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/PendleMsgSenderAppUpg.sol/PendleMsgSenderAppUpg.dbg.json +1 -1
  7. package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/libraries/LayerZeroHelper.sol/LayerZeroHelper.dbg.json +1 -1
  8. package/build/artifacts/contracts/LiquidityMining/CrossChainMsg/libraries/LayerZeroHelper.sol/LayerZeroHelper.json +2 -2
  9. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol/PendleGaugeControllerBaseUpg.dbg.json +1 -1
  10. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.dbg.json +1 -1
  11. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.json +2 -2
  12. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.dbg.json +1 -1
  13. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.json +2 -2
  14. package/build/artifacts/contracts/LiquidityMining/VeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.dbg.json +1 -1
  15. package/build/artifacts/contracts/LiquidityMining/VeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.json +34 -2
  16. package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.dbg.json +1 -1
  17. package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.json +2 -2
  18. package/build/artifacts/contracts/LiquidityMining/VotingController/VotingControllerStorageUpg.sol/VotingControllerStorageUpg.dbg.json +1 -1
  19. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.dbg.json +1 -1
  20. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.json +2 -2
  21. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.dbg.json +1 -1
  22. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.json +2 -2
  23. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol/VotingEscrowTokenBase.dbg.json +1 -1
  24. package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.dbg.json +1 -1
  25. package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.json +2 -2
  26. package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.dbg.json +1 -1
  27. package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.json +2 -2
  28. package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.dbg.json +1 -1
  29. package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.json +2 -2
  30. package/build/artifacts/contracts/core/BulkSeller/BulkSeller.sol/BulkSeller.dbg.json +1 -1
  31. package/build/artifacts/contracts/core/BulkSeller/BulkSeller.sol/BulkSeller.json +2 -2
  32. package/build/artifacts/contracts/core/BulkSeller/BulkSellerFactory.sol/BulkSellerFactory.dbg.json +1 -1
  33. package/build/artifacts/contracts/core/BulkSeller/BulkSellerFactory.sol/BulkSellerFactory.json +2 -2
  34. package/build/artifacts/contracts/core/BulkSeller/BulkSellerMathCore.sol/BulkSellerMathCore.dbg.json +1 -1
  35. package/build/artifacts/contracts/core/BulkSeller/BulkSellerMathCore.sol/BulkSellerMathCore.json +2 -2
  36. package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.dbg.json +1 -1
  37. package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.json +2 -2
  38. package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.dbg.json +1 -1
  39. package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.json +2 -2
  40. package/build/artifacts/contracts/core/Market/PendleGauge.sol/PendleGauge.dbg.json +1 -1
  41. package/build/artifacts/contracts/core/Market/PendleMarket.sol/PendleMarket.dbg.json +1 -1
  42. package/build/artifacts/contracts/core/Market/PendleMarket.sol/PendleMarket.json +2 -2
  43. package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.dbg.json +1 -1
  44. package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.json +2 -2
  45. package/build/artifacts/contracts/core/RewardManager/RewardManager.sol/RewardManager.dbg.json +1 -1
  46. package/build/artifacts/contracts/core/RewardManager/RewardManagerAbstract.sol/RewardManagerAbstract.dbg.json +1 -1
  47. package/build/artifacts/contracts/core/StandardizedYield/SYBase.sol/SYBase.dbg.json +1 -1
  48. package/build/artifacts/contracts/core/StandardizedYield/SYBase.sol/SYBase.json +141 -0
  49. package/build/artifacts/contracts/core/StandardizedYield/SYBaseWithRewards.sol/SYBaseWithRewards.dbg.json +1 -1
  50. package/build/artifacts/contracts/core/StandardizedYield/SYBaseWithRewards.sol/SYBaseWithRewards.json +141 -0
  51. package/build/artifacts/contracts/core/StandardizedYield/StEthHelper.sol/StEthHelper.dbg.json +4 -0
  52. package/build/artifacts/contracts/core/StandardizedYield/StEthHelper.sol/StEthHelper.json +10 -0
  53. package/build/artifacts/contracts/core/StandardizedYield/implementations/Ape/sAPE.sol/sAPE.dbg.json +1 -1
  54. package/build/artifacts/contracts/core/StandardizedYield/implementations/Ape/sAPE.sol/sAPE.json +143 -2
  55. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAura3EthSY.sol/PendleAura3EthSY.dbg.json +4 -0
  56. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAura3EthSY.sol/PendleAura3EthSY.json +1257 -0
  57. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraCbethWstethSY.sol/PendleAuraCbethWstethSY.dbg.json +4 -0
  58. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraCbethWstethSY.sol/PendleAuraCbethWstethSY.json +1244 -0
  59. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethRethSY.sol/PendleAuraWethRethSY.dbg.json +4 -0
  60. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethRethSY.sol/PendleAuraWethRethSY.json +1218 -0
  61. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethWstethSY.sol/PendleAuraWethWstethSY.dbg.json +4 -0
  62. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethWstethSY.sol/PendleAuraWethWstethSY.json +1192 -0
  63. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStableMath.sol/ComposableStableMath.dbg.json +4 -0
  64. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStableMath.sol/ComposableStableMath.json +10 -0
  65. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStablePreview.sol/ComposableStablePreview.dbg.json +4 -0
  66. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStablePreview.sol/ComposableStablePreview.json +133 -0
  67. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/FixedPoint.sol/FixedPoint.dbg.json +4 -0
  68. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/FixedPoint.sol/FixedPoint.json +10 -0
  69. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStableMath.sol/MetaStableMath.dbg.json +4 -0
  70. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStableMath.sol/MetaStableMath.json +40 -0
  71. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStablePreview.sol/MetaStablePreview.dbg.json +4 -0
  72. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStablePreview.sol/MetaStablePreview.json +322 -0
  73. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/PendleAuraBalancerStableLPSY.sol/PendleAuraBalancerStableLPSY.dbg.json +4 -0
  74. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/PendleAuraBalancerStableLPSY.sol/PendleAuraBalancerStableLPSY.json +1171 -0
  75. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePoolUserData.sol/StablePoolUserData.dbg.json +4 -0
  76. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePoolUserData.sol/StablePoolUserData.json +10 -0
  77. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePreviewBase.sol/StablePreviewBase.dbg.json +4 -0
  78. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePreviewBase.sol/StablePreviewBase.json +133 -0
  79. package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.dbg.json +1 -1
  80. package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.json +2 -2
  81. package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenSY.sol/PendleQiTokenSY.dbg.json +1 -1
  82. package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenSY.sol/PendleQiTokenSY.json +143 -2
  83. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveFraxUsdcSY.sol/PendleCurveFraxUsdcSY.dbg.json +1 -1
  84. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveFraxUsdcSY.sol/PendleCurveFraxUsdcSY.json +143 -2
  85. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveUsdd3CrvSY.sol/PendleCurveUsdd3CrvSY.dbg.json +1 -1
  86. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveUsdd3CrvSY.sol/PendleCurveUsdd3CrvSY.json +143 -2
  87. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/PendleConvexLPSY.sol/PendleConvexLPSY.dbg.json +1 -1
  88. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/PendleConvexLPSY.sol/PendleConvexLPSY.json +141 -0
  89. package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleLooksStakingSY.sol/PendleLooksStakingSY.dbg.json +1 -1
  90. package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleLooksStakingSY.sol/PendleLooksStakingSY.json +143 -2
  91. package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleWstEthSY.sol/PendleWstEthSY.dbg.json +1 -1
  92. package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleWstEthSY.sol/PendleWstEthSY.json +143 -2
  93. package/build/artifacts/contracts/core/YieldContracts/PendlePrincipalToken.sol/PendlePrincipalToken.dbg.json +1 -1
  94. package/build/artifacts/contracts/core/YieldContracts/PendlePrincipalToken.sol/PendlePrincipalToken.json +2 -2
  95. package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactory.sol/PendleYieldContractFactory.dbg.json +1 -1
  96. package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactory.sol/PendleYieldContractFactory.json +2 -2
  97. package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.dbg.json +1 -1
  98. package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.json +2 -2
  99. package/build/artifacts/contracts/core/libraries/ArrayLib.sol/ArrayLib.dbg.json +1 -1
  100. package/build/artifacts/contracts/core/libraries/ArrayLib.sol/ArrayLib.json +2 -2
  101. package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.dbg.json +1 -1
  102. package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.json +39 -2
  103. package/build/artifacts/contracts/interfaces/Balancer/IAsset.sol/IAsset.dbg.json +4 -0
  104. package/build/artifacts/contracts/interfaces/Balancer/IAsset.sol/IAsset.json +10 -0
  105. package/build/artifacts/contracts/interfaces/Balancer/IBalancerFees.sol/IBalancerFees.dbg.json +4 -0
  106. package/build/artifacts/contracts/interfaces/Balancer/IBalancerFees.sol/IBalancerFees.json +24 -0
  107. package/build/artifacts/contracts/interfaces/Balancer/IBalancerStablePreview.sol/IBalancerStablePreview.dbg.json +4 -0
  108. package/build/artifacts/contracts/interfaces/Balancer/IBalancerStablePreview.sol/IBalancerStablePreview.json +133 -0
  109. package/build/artifacts/contracts/interfaces/Balancer/IBasePool.sol/IBasePool.dbg.json +4 -0
  110. package/build/artifacts/contracts/interfaces/Balancer/IBasePool.sol/IBasePool.json +328 -0
  111. package/build/artifacts/contracts/interfaces/Balancer/IComposableStable.sol/IComposableStable.dbg.json +4 -0
  112. package/build/artifacts/contracts/interfaces/Balancer/IComposableStable.sol/IComposableStable.json +467 -0
  113. package/build/artifacts/contracts/interfaces/Balancer/IGauge.sol/IGauge.dbg.json +4 -0
  114. package/build/artifacts/contracts/interfaces/Balancer/IGauge.sol/IGauge.json +61 -0
  115. package/build/artifacts/contracts/interfaces/Balancer/ILiquidityGaugeFactory.sol/ILiquidityGaugeFactory.dbg.json +4 -0
  116. package/build/artifacts/contracts/interfaces/Balancer/ILiquidityGaugeFactory.sol/ILiquidityGaugeFactory.json +30 -0
  117. package/build/artifacts/contracts/interfaces/Balancer/IMetaStablePool.sol/IMetaStablePool.dbg.json +4 -0
  118. package/build/artifacts/contracts/interfaces/Balancer/IMetaStablePool.sol/IMetaStablePool.json +398 -0
  119. package/build/artifacts/contracts/interfaces/Balancer/IRateProvider.sol/IRateProvider.dbg.json +4 -0
  120. package/build/artifacts/contracts/interfaces/Balancer/IRateProvider.sol/IRateProvider.json +24 -0
  121. package/build/artifacts/contracts/interfaces/Balancer/IVault.sol/IVault.dbg.json +4 -0
  122. package/build/artifacts/contracts/interfaces/Balancer/IVault.sol/IVault.json +278 -0
  123. package/build/artifacts/contracts/interfaces/ConvexCurve/IRewards.sol/IRewards.dbg.json +1 -1
  124. package/build/artifacts/contracts/interfaces/ConvexCurve/IRewards.sol/IRewards.json +18 -0
  125. package/build/artifacts/contracts/interfaces/IApeStaking.sol/IApeStaking.dbg.json +1 -1
  126. package/build/artifacts/contracts/interfaces/IPActionAddRemoveLiq.sol/IPActionAddRemoveLiq.dbg.json +1 -1
  127. package/build/artifacts/contracts/interfaces/IPActionMintRedeem.sol/IPActionMintRedeem.dbg.json +1 -1
  128. package/build/artifacts/contracts/interfaces/IPActionSwapPT.sol/IPActionSwapPT.dbg.json +1 -1
  129. package/build/artifacts/contracts/interfaces/IPActionSwapPTYT.sol/IPActionSwapPTYT.dbg.json +1 -1
  130. package/build/artifacts/contracts/interfaces/IPActionSwapYT.sol/IPActionSwapYT.dbg.json +1 -1
  131. package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.dbg.json +1 -1
  132. package/build/artifacts/contracts/interfaces/IPBulkSeller.sol/IPBulkSeller.dbg.json +1 -1
  133. package/build/artifacts/contracts/interfaces/IPFeeDistributor.sol/IPFeeDistributor.dbg.json +1 -1
  134. package/build/artifacts/contracts/interfaces/IPFeeDistributor.sol/IPFeeDistributor.json +19 -0
  135. package/build/artifacts/contracts/interfaces/IPMarket.sol/IPMarket.dbg.json +1 -1
  136. package/build/artifacts/contracts/interfaces/IPVotingController.sol/IPVotingController.dbg.json +1 -1
  137. package/build/artifacts/contracts/interfaces/IPVotingEscrowMainchain.sol/IPVotingEscrowMainchain.dbg.json +1 -1
  138. package/build/artifacts/contracts/offchain-helpers/BulkSellerOffchain.sol/BulkSellerOffchain.dbg.json +1 -1
  139. package/build/artifacts/contracts/offchain-helpers/BulkSellerOffchain.sol/BulkSellerOffchain.json +2 -2
  140. package/build/artifacts/contracts/offchain-helpers/MarketMathStatic.sol/MarketMathStatic.dbg.json +1 -1
  141. package/build/artifacts/contracts/offchain-helpers/MarketMathStatic.sol/MarketMathStatic.json +2 -2
  142. package/build/artifacts/contracts/offchain-helpers/Multicall2.sol/Multicall2.dbg.json +4 -0
  143. package/build/artifacts/contracts/offchain-helpers/Multicall2.sol/Multicall2.json +322 -0
  144. package/build/artifacts/contracts/offchain-helpers/PendleMulticall.sol/PendleMulticall.dbg.json +4 -0
  145. package/build/artifacts/contracts/offchain-helpers/PendleMulticall.sol/PendleMulticall.json +47 -0
  146. package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.dbg.json +1 -1
  147. package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.json +2 -2
  148. package/build/artifacts/contracts/router/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.dbg.json +1 -1
  149. package/build/artifacts/contracts/router/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.json +2 -2
  150. package/build/artifacts/contracts/router/ActionCallback.sol/ActionCallback.dbg.json +1 -1
  151. package/build/artifacts/contracts/router/ActionCallback.sol/ActionCallback.json +2 -2
  152. package/build/artifacts/contracts/router/ActionMintRedeem.sol/ActionMintRedeem.dbg.json +1 -1
  153. package/build/artifacts/contracts/router/ActionMintRedeem.sol/ActionMintRedeem.json +2 -2
  154. package/build/artifacts/contracts/router/ActionMisc.sol/ActionMisc.dbg.json +1 -1
  155. package/build/artifacts/contracts/router/ActionMisc.sol/ActionMisc.json +2 -2
  156. package/build/artifacts/contracts/router/ActionSwapPT.sol/ActionSwapPT.dbg.json +1 -1
  157. package/build/artifacts/contracts/router/ActionSwapPT.sol/ActionSwapPT.json +2 -2
  158. package/build/artifacts/contracts/router/ActionSwapPTYT.sol/ActionSwapPTYT.dbg.json +1 -1
  159. package/build/artifacts/contracts/router/ActionSwapPTYT.sol/ActionSwapPTYT.json +2 -2
  160. package/build/artifacts/contracts/router/ActionSwapYT.sol/ActionSwapYT.dbg.json +1 -1
  161. package/build/artifacts/contracts/router/ActionSwapYT.sol/ActionSwapYT.json +2 -2
  162. package/build/artifacts/contracts/router/PendleRouter.sol/PendleRouter.dbg.json +1 -1
  163. package/build/artifacts/contracts/router/PendleRouter.sol/PendleRouter.json +2 -2
  164. package/build/artifacts/contracts/router/base/ActionBaseMintRedeem.sol/ActionBaseMintRedeem.dbg.json +1 -1
  165. package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtInLib.dbg.json +1 -1
  166. package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtInLib.json +2 -2
  167. package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtOutLib.dbg.json +1 -1
  168. package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtOutLib.json +2 -2
  169. package/build/artifacts/contracts/router/kyberswap/AggregationRouterHelper.sol/AggregationRouterHelper.dbg.json +1 -1
  170. package/build/artifacts/contracts/router/kyberswap/AggregationRouterHelper.sol/AggregationRouterHelper.json +2 -2
  171. package/build/artifacts/contracts/router/kyberswap/IAggregatorRouterHelper.sol/IAggregationRouterHelper.dbg.json +1 -1
  172. package/build/artifacts/contracts/router/kyberswap/KyberSwapHelper.sol/KyberSwapHelper.dbg.json +1 -1
  173. package/build/artifacts/contracts/router/kyberswap/ScaleDataHelperEthereum1.sol/ScaleDataHelperEthereum1.dbg.json +4 -0
  174. package/build/artifacts/contracts/router/kyberswap/ScaleDataHelperEthereum1.sol/ScaleDataHelperEthereum1.json +10 -0
  175. package/build/artifacts/contracts/router/kyberswap/interfaces/IAggregationExecutor.sol/IAggregationExecutor.dbg.json +4 -0
  176. package/build/artifacts/contracts/router/kyberswap/interfaces/IAggregationExecutor.sol/IAggregationExecutor.json +65 -0
  177. package/build/artifacts/contracts/router/kyberswap/interfaces/IExecutorHelperEthereum1.sol/IExecutorHelperEthereum1.dbg.json +4 -0
  178. package/build/artifacts/contracts/router/kyberswap/interfaces/IExecutorHelperEthereum1.sol/IExecutorHelperEthereum1.json +359 -0
  179. package/build/artifacts/contracts/router/kyberswap/interfaces/IHashflow.sol/IHashflow.dbg.json +4 -0
  180. package/build/artifacts/contracts/router/kyberswap/interfaces/IHashflow.sol/IHashflow.json +101 -0
  181. package/build/artifacts/contracts/router/kyberswap/interfaces/IMetaAggregationRouter.sol/IMetaAggregationRouter.dbg.json +4 -0
  182. package/build/artifacts/contracts/router/kyberswap/interfaces/IMetaAggregationRouter.sol/IMetaAggregationRouter.json +183 -0
  183. package/build/artifacts/contracts/router/kyberswap/interfaces/IMetaAggregationRouterV2.sol/IMetaAggregationRouterV2.dbg.json +4 -0
  184. package/build/artifacts/contracts/router/kyberswap/interfaces/IMetaAggregationRouterV2.sol/IMetaAggregationRouterV2.json +215 -0
  185. package/contracts/LiquidityMining/CrossChainMsg/libraries/LayerZeroHelper.sol +7 -9
  186. package/contracts/core/StandardizedYield/SYBase.sol +23 -5
  187. package/contracts/core/StandardizedYield/StEthHelper.sol +71 -0
  188. package/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAura3EthSY.sol +170 -0
  189. package/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraCbethWstethSY.sol +162 -0
  190. package/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethRethSY.sol +134 -0
  191. package/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethWstethSY.sol +154 -0
  192. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStableMath.sol +289 -0
  193. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStablePreview.sol +618 -0
  194. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/FixedPoint.sol +68 -0
  195. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStableMath.sol +322 -0
  196. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStablePreview.sol +390 -0
  197. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/PendleAuraBalancerStableLPSY.sol +329 -0
  198. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePoolUserData.sol +30 -0
  199. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePreviewBase.sol +189 -0
  200. package/contracts/core/libraries/ArrayLib.sol +6 -3
  201. package/contracts/core/libraries/Errors.sol +3 -0
  202. package/contracts/interfaces/Balancer/IAsset.sol +4 -0
  203. package/contracts/interfaces/Balancer/IBalancerFees.sol +6 -0
  204. package/contracts/interfaces/Balancer/IBalancerStablePreview.sol +22 -0
  205. package/contracts/interfaces/Balancer/IBasePool.sol +30 -0
  206. package/contracts/interfaces/Balancer/IComposableStable.sol +39 -0
  207. package/contracts/interfaces/Balancer/IGauge.sol +10 -0
  208. package/contracts/interfaces/Balancer/ILiquidityGaugeFactory.sol +6 -0
  209. package/contracts/interfaces/Balancer/IMetaStablePool.sol +31 -0
  210. package/contracts/interfaces/Balancer/IRateProvider.sol +6 -0
  211. package/contracts/interfaces/Balancer/IVault.sol +78 -0
  212. package/contracts/interfaces/ConvexCurve/IRewards.sol +5 -0
  213. package/contracts/offchain-helpers/PendleMulticall.sol +26 -0
  214. package/contracts/router/kyberswap/AggregationRouterHelper.sol +191 -205
  215. package/contracts/router/kyberswap/ScaleDataHelperEthereum1.sol +134 -0
  216. package/contracts/router/kyberswap/interfaces/IAggregationExecutor.sol +17 -0
  217. package/contracts/router/kyberswap/interfaces/IExecutorHelperEthereum1.sol +185 -0
  218. package/contracts/router/kyberswap/interfaces/IHashflow.sol +30 -0
  219. package/contracts/router/kyberswap/interfaces/IMetaAggregationRouter.sol +33 -0
  220. package/contracts/router/kyberswap/interfaces/IMetaAggregationRouterV2.sol +42 -0
  221. package/deployments/1-core.json +1 -1
  222. package/deployments/1-markets/BALANCER-LP-AURA-RETH-WETH-28DEC.json +11 -0
  223. package/deployments/1-markets/BALANCER-LP-AURA-WSTETH-WETH-JUN272024.json +10 -0
  224. package/deployments/1-offchain-helper.json +4 -0
  225. package/package.json +6 -6
  226. package/typechain-types/ComposableStablePreview.ts +217 -0
  227. package/typechain-types/GMXPreviewHelper.ts +81 -0
  228. package/typechain-types/I1inchAggregationRouterV5.ts +257 -0
  229. package/typechain-types/IAggregationExecutor.ts +182 -0
  230. package/typechain-types/IBalancerFees.ts +89 -0
  231. package/typechain-types/IBalancerStablePreview.ts +217 -0
  232. package/typechain-types/IBasePool.ts +482 -0
  233. package/typechain-types/IComposableStable.ts +730 -0
  234. package/typechain-types/IExecutorHelperEthereum1.ts +599 -0
  235. package/typechain-types/IGMXVault.ts +494 -0
  236. package/typechain-types/IGauge.ts +160 -0
  237. package/typechain-types/IGlpManager.ts +115 -0
  238. package/typechain-types/IHashflow.ts +159 -0
  239. package/typechain-types/IKyberSwapAggregationRouterHelper.ts +109 -0
  240. package/typechain-types/ILiquidityGaugeFactory.ts +99 -0
  241. package/typechain-types/IMetaAggregationRouter.ts +213 -0
  242. package/typechain-types/IMetaAggregationRouterV2.ts +221 -0
  243. package/typechain-types/IMetaStablePool.ts +619 -0
  244. package/typechain-types/IPFeeDistributor.ts +18 -0
  245. package/typechain-types/IPYieldTokenV2.ts +915 -0
  246. package/typechain-types/IRateProvider.ts +81 -0
  247. package/typechain-types/IRewardRouterV2.ts +303 -0
  248. package/typechain-types/IRewards.ts +35 -5
  249. package/typechain-types/ISwapAggregator.ts +124 -0
  250. package/typechain-types/IVault.ts +410 -0
  251. package/typechain-types/IVaultPriceFeed.ts +114 -0
  252. package/typechain-types/InterestManagerYTV2.ts +124 -0
  253. package/typechain-types/MetaStableMath.ts +113 -0
  254. package/typechain-types/MetaStablePreview.ts +501 -0
  255. package/typechain-types/Multicall2.ts +437 -0
  256. package/typechain-types/PendleAura3EthSY.ts +1600 -0
  257. package/typechain-types/PendleAuraBalancerStableLPSY.ts +1523 -0
  258. package/typechain-types/PendleAuraCbethWstethSY.ts +1587 -0
  259. package/typechain-types/PendleAuraWethRethSY.ts +1549 -0
  260. package/typechain-types/PendleAuraWethWstethSY.ts +1523 -0
  261. package/typechain-types/PendleConvexLPSY.ts +204 -0
  262. package/typechain-types/PendleCurveFraxUsdcSY.ts +204 -0
  263. package/typechain-types/PendleCurveUsdd3CrvSY.ts +204 -0
  264. package/typechain-types/PendleFeeDistributor.ts +37 -0
  265. package/typechain-types/PendleGlpSY.ts +1396 -0
  266. package/typechain-types/PendleLooksStakingSY.ts +204 -0
  267. package/typechain-types/PendleMulticall.ts +110 -0
  268. package/typechain-types/PendlePrincipalTokenV2.ts +614 -0
  269. package/typechain-types/PendleQiTokenSY.ts +204 -0
  270. package/typechain-types/PendleWstEthSY.ts +204 -0
  271. package/typechain-types/PendleYieldContractFactoryV2.ts +801 -0
  272. package/typechain-types/PendleYieldTokenV2.ts +1304 -0
  273. package/typechain-types/SAPE.ts +204 -0
  274. package/typechain-types/SYBase.ts +204 -0
  275. package/typechain-types/SYBaseWithRewards.ts +204 -0
  276. package/typechain-types/StEthHelper.ts +107 -0
  277. package/typechain-types/StablePreviewBase.ts +217 -0
  278. package/typechain-types/SwapAggregator.ts +406 -0
  279. package/typechain-types/factories/ActionAddRemoveLiq__factory.ts +1 -1
  280. package/typechain-types/factories/ActionCallback__factory.ts +1 -1
  281. package/typechain-types/factories/ActionMintRedeem__factory.ts +1 -1
  282. package/typechain-types/factories/ActionMisc__factory.ts +1 -1
  283. package/typechain-types/factories/ActionSwapPTYT__factory.ts +1 -1
  284. package/typechain-types/factories/ActionSwapPT__factory.ts +1 -1
  285. package/typechain-types/factories/ActionSwapYT__factory.ts +1 -1
  286. package/typechain-types/factories/AggregationRouterHelper__factory.ts +1 -1
  287. package/typechain-types/factories/BulkSellerFactory__factory.ts +1 -1
  288. package/typechain-types/factories/BulkSellerOffchain__factory.ts +1 -1
  289. package/typechain-types/factories/BulkSeller__factory.ts +1 -1
  290. package/typechain-types/factories/ComposableStablePreview__factory.ts +190 -0
  291. package/typechain-types/factories/Errors__factory.ts +38 -1
  292. package/typechain-types/factories/GMXPreviewHelper__factory.ts +39 -0
  293. package/typechain-types/factories/I1inchAggregationRouterV5__factory.ts +179 -0
  294. package/typechain-types/factories/IAggregationExecutor__factory.ts +84 -0
  295. package/typechain-types/factories/IBalancerFees__factory.ts +36 -0
  296. package/typechain-types/factories/IBalancerStablePreview__factory.ts +152 -0
  297. package/typechain-types/factories/IBasePool__factory.ts +340 -0
  298. package/typechain-types/factories/IComposableStable__factory.ts +482 -0
  299. package/typechain-types/factories/IExecutorHelperEthereum1__factory.ts +378 -0
  300. package/typechain-types/factories/IGMXVault__factory.ts +320 -0
  301. package/typechain-types/factories/IGauge__factory.ts +70 -0
  302. package/typechain-types/factories/IGlpManager__factory.ts +55 -0
  303. package/typechain-types/factories/IHashflow__factory.ts +113 -0
  304. package/typechain-types/factories/IKyberSwapAggregationRouterHelper__factory.ts +56 -0
  305. package/typechain-types/factories/ILiquidityGaugeFactory__factory.ts +49 -0
  306. package/typechain-types/factories/IMetaAggregationRouterV2__factory.ts +234 -0
  307. package/typechain-types/factories/IMetaAggregationRouter__factory.ts +202 -0
  308. package/typechain-types/factories/IMetaStablePool__factory.ts +413 -0
  309. package/typechain-types/factories/IPFeeDistributor__factory.ts +19 -0
  310. package/typechain-types/factories/IPYieldTokenV2__factory.ts +702 -0
  311. package/typechain-types/factories/IRateProvider__factory.ts +36 -0
  312. package/typechain-types/factories/IRewardRouterV2__factory.ts +180 -0
  313. package/typechain-types/factories/IRewards__factory.ts +18 -0
  314. package/typechain-types/factories/ISwapAggregator__factory.ts +66 -0
  315. package/typechain-types/factories/IVaultPriceFeed__factory.ts +60 -0
  316. package/typechain-types/factories/IVault__factory.ts +287 -0
  317. package/typechain-types/factories/InterestManagerYTV2__factory.ts +63 -0
  318. package/typechain-types/factories/MarketMathStatic__factory.ts +1 -1
  319. package/typechain-types/factories/MetaStableMath__factory.ts +93 -0
  320. package/typechain-types/factories/MetaStablePreview__factory.ts +375 -0
  321. package/typechain-types/factories/Multicall2__factory.ts +372 -0
  322. package/typechain-types/factories/OracleLib__factory.ts +1 -1
  323. package/typechain-types/factories/PendleAura3EthSY__factory.ts +1326 -0
  324. package/typechain-types/factories/PendleAuraBalancerStableLPSY__factory.ts +1190 -0
  325. package/typechain-types/factories/PendleAuraCbethWstethSY__factory.ts +1317 -0
  326. package/typechain-types/factories/PendleAuraWethRethSY__factory.ts +1291 -0
  327. package/typechain-types/factories/PendleAuraWethWstethSY__factory.ts +1265 -0
  328. package/typechain-types/factories/PendleConvexLPSY__factory.ts +141 -0
  329. package/typechain-types/factories/PendleCurveFraxUsdcSY__factory.ts +142 -1
  330. package/typechain-types/factories/PendleCurveUsdd3CrvSY__factory.ts +142 -1
  331. package/typechain-types/factories/PendleFeeDistributor__factory.ts +33 -1
  332. package/typechain-types/factories/PendleGaugeControllerMainchainUpg__factory.ts +1 -1
  333. package/typechain-types/factories/PendleGaugeControllerSidechainUpg__factory.ts +1 -1
  334. package/typechain-types/factories/PendleGlpSY__factory.ts +1216 -0
  335. package/typechain-types/factories/PendleLooksStakingSY__factory.ts +142 -1
  336. package/typechain-types/factories/PendleMarketFactory__factory.ts +1 -1
  337. package/typechain-types/factories/PendleMarket__factory.ts +1 -1
  338. package/typechain-types/factories/PendleMsgReceiveEndpointUpg__factory.ts +1 -1
  339. package/typechain-types/factories/PendleMsgSendEndpointUpg__factory.ts +1 -1
  340. package/typechain-types/factories/PendleMulticall__factory.ts +100 -0
  341. package/typechain-types/factories/PendlePrincipalTokenV2__factory.ts +564 -0
  342. package/typechain-types/factories/PendlePrincipalToken__factory.ts +1 -1
  343. package/typechain-types/factories/PendleQiTokenHelper__factory.ts +1 -1
  344. package/typechain-types/factories/PendleQiTokenSY__factory.ts +142 -1
  345. package/typechain-types/factories/PendleRouter__factory.ts +1 -1
  346. package/typechain-types/factories/PendleVotingControllerUpg__factory.ts +1 -1
  347. package/typechain-types/factories/PendleWstEthSY__factory.ts +142 -1
  348. package/typechain-types/factories/PendleYieldContractFactoryV2__factory.ts +674 -0
  349. package/typechain-types/factories/PendleYieldContractFactory__factory.ts +1 -1
  350. package/typechain-types/factories/PendleYieldTokenV2__factory.ts +1122 -0
  351. package/typechain-types/factories/PendleYieldToken__factory.ts +1 -1
  352. package/typechain-types/factories/RouterStatic__factory.ts +1 -1
  353. package/typechain-types/factories/SAPE__factory.ts +142 -1
  354. package/typechain-types/factories/SYBaseWithRewards__factory.ts +141 -0
  355. package/typechain-types/factories/SYBase__factory.ts +141 -0
  356. package/typechain-types/factories/StEthHelper__factory.ts +62 -0
  357. package/typechain-types/factories/StablePreviewBase__factory.ts +148 -0
  358. package/typechain-types/factories/SwapAggregator__factory.ts +309 -0
  359. package/typechain-types/factories/VotingEscrowPendleMainchain__factory.ts +1 -1
  360. package/typechain-types/factories/VotingEscrowPendleSidechain__factory.ts +1 -1
  361. package/typechain-types/hardhat.d.ts +269 -8
  362. package/typechain-types/index.ts +62 -4
  363. package/build/artifacts/contracts/router/kyberswap/IMultihopRouterEthereum.sol/IMultihopRouterEthereum.dbg.json +0 -4
  364. package/build/artifacts/contracts/router/kyberswap/IMultihopRouterEthereum.sol/IMultihopRouterEthereum.json +0 -136
  365. package/contracts/router/kyberswap/IMultihopRouterEthereum.sol +0 -141
@@ -0,0 +1,185 @@
1
+ // SPDX-License-Identifier: MIT
2
+ pragma solidity 0.8.17;
3
+
4
+ import "./IHashflow.sol";
5
+
6
+ interface IExecutorHelperEthereum1 {
7
+ struct UniSwap {
8
+ address pool;
9
+ address tokenIn;
10
+ address tokenOut;
11
+ address recipient;
12
+ uint256 collectAmount; // amount that should be transferred to the pool
13
+ uint256 limitReturnAmount;
14
+ uint32 swapFee;
15
+ uint32 feePrecision;
16
+ uint32 tokenWeightInput;
17
+ }
18
+
19
+ struct StableSwap {
20
+ address pool;
21
+ address tokenFrom;
22
+ address tokenTo;
23
+ uint8 tokenIndexFrom;
24
+ uint8 tokenIndexTo;
25
+ uint256 dx;
26
+ uint256 minDy;
27
+ uint256 poolLength;
28
+ address poolLp;
29
+ bool isSaddle; // true: saddle, false: stable
30
+ }
31
+
32
+ struct CurveSwap {
33
+ address pool;
34
+ address tokenFrom;
35
+ address tokenTo;
36
+ int128 tokenIndexFrom;
37
+ int128 tokenIndexTo;
38
+ uint256 dx;
39
+ uint256 minDy;
40
+ bool usePoolUnderlying;
41
+ bool useTriCrypto;
42
+ }
43
+
44
+ struct UniSwapV3ProMM {
45
+ address recipient;
46
+ address pool;
47
+ address tokenIn;
48
+ address tokenOut;
49
+ uint256 swapAmount;
50
+ uint256 limitReturnAmount;
51
+ uint160 sqrtPriceLimitX96;
52
+ bool isUniV3; // true = UniV3, false = ProMM
53
+ }
54
+
55
+ struct BalancerV2 {
56
+ address vault;
57
+ bytes32 poolId;
58
+ address assetIn;
59
+ address assetOut;
60
+ uint256 amount;
61
+ uint256 limit;
62
+ }
63
+
64
+ struct KyberRFQ {
65
+ address rfq;
66
+ bytes order;
67
+ bytes signature;
68
+ uint256 amount;
69
+ address payable target;
70
+ }
71
+
72
+ struct DODO {
73
+ address recipient;
74
+ address pool;
75
+ address tokenFrom;
76
+ address tokenTo;
77
+ uint256 amount;
78
+ uint256 minReceiveQuote;
79
+ address sellHelper;
80
+ bool isSellBase;
81
+ bool isVersion2;
82
+ }
83
+
84
+ struct Synthetix {
85
+ address synthetixProxy;
86
+ address tokenIn;
87
+ address tokenOut;
88
+ bytes32 sourceCurrencyKey;
89
+ uint256 sourceAmount;
90
+ bytes32 destinationCurrencyKey;
91
+ uint256 minAmount;
92
+ bool useAtomicExchange;
93
+ }
94
+
95
+ struct PSM {
96
+ address router;
97
+ address tokenIn;
98
+ address tokenOut;
99
+ uint256 amountIn;
100
+ address recipient;
101
+ }
102
+
103
+ struct Hashflow {
104
+ address router;
105
+ IHashflow.Quote quote;
106
+ }
107
+
108
+ struct WSTETH {
109
+ address pool;
110
+ uint256 amount;
111
+ bool isWrapping;
112
+ }
113
+
114
+ function executeUniSwap(
115
+ uint256 index,
116
+ bytes memory data,
117
+ uint256 previousAmountOut
118
+ ) external payable returns (uint256);
119
+
120
+ function executeStableSwap(
121
+ uint256 index,
122
+ bytes memory data,
123
+ uint256 previousAmountOut
124
+ ) external payable returns (uint256);
125
+
126
+ function executeCurveSwap(
127
+ uint256 index,
128
+ bytes memory data,
129
+ uint256 previousAmountOut
130
+ ) external payable returns (uint256);
131
+
132
+ function executeKyberDMMSwap(
133
+ uint256 index,
134
+ bytes memory data,
135
+ uint256 previousAmountOut
136
+ ) external payable returns (uint256);
137
+
138
+ function executeUniV3ProMMSwap(
139
+ uint256 index,
140
+ bytes memory data,
141
+ uint256 previousAmountOut
142
+ ) external payable returns (uint256);
143
+
144
+ function executeRfqSwap(
145
+ uint256 index,
146
+ bytes memory data,
147
+ uint256 previousAmountOut
148
+ ) external payable returns (uint256);
149
+
150
+ function executeBalV2Swap(
151
+ uint256 index,
152
+ bytes memory data,
153
+ uint256 previousAmountOut
154
+ ) external payable returns (uint256);
155
+
156
+ function executeDODOSwap(
157
+ uint256 index,
158
+ bytes memory data,
159
+ uint256 previousAmountOut
160
+ ) external payable returns (uint256);
161
+
162
+ function executeWrappedstETHSwap(
163
+ uint256 index,
164
+ bytes memory data,
165
+ uint256 previousAmountOut
166
+ ) external payable returns (uint256);
167
+
168
+ function executeSynthetixSwap(
169
+ uint256 index,
170
+ bytes memory data,
171
+ uint256 previousAmountOut
172
+ ) external payable returns (uint256);
173
+
174
+ function executePSMSwap(
175
+ uint256 index,
176
+ bytes memory data,
177
+ uint256 previousAmountOut
178
+ ) external payable returns (uint256);
179
+
180
+ function executeHashflowSwap(
181
+ uint256 index,
182
+ bytes memory data,
183
+ uint256 previousAmountOut
184
+ ) external payable returns (uint256);
185
+ }
@@ -0,0 +1,30 @@
1
+ // SPDX-License-Identifier: MIT
2
+
3
+ pragma solidity 0.8.17;
4
+
5
+ interface IHashflow {
6
+ enum RFQType {
7
+ TAKER,
8
+ MAKER
9
+ }
10
+
11
+ struct Quote {
12
+ RFQType rfqType;
13
+ address pool;
14
+ address eoa;
15
+ address trader;
16
+ address effectiveTrader;
17
+ address baseToken;
18
+ address quoteToken;
19
+ uint256 effectiveBaseTokenAmount;
20
+ uint256 maxBaseTokenAmount;
21
+ uint256 maxQuoteTokenAmount;
22
+ uint256 fees;
23
+ uint256 quoteExpiry;
24
+ uint256 nonce;
25
+ bytes32 txid;
26
+ bytes signedQuote;
27
+ }
28
+
29
+ function tradeSingleHop(Quote memory quote) external payable;
30
+ }
@@ -0,0 +1,33 @@
1
+ // SPDX-License-Identifier: MIT
2
+ pragma solidity 0.8.17;
3
+
4
+ import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
5
+ import "./IAggregationExecutor.sol";
6
+
7
+ interface IMetaAggregationRouter {
8
+ struct SwapDescription {
9
+ IERC20 srcToken;
10
+ IERC20 dstToken;
11
+ address[] srcReceivers;
12
+ uint256[] srcAmounts;
13
+ address dstReceiver;
14
+ uint256 amount;
15
+ uint256 minReturnAmount;
16
+ uint256 flags;
17
+ bytes permit;
18
+ }
19
+
20
+ function swap(
21
+ IAggregationExecutor caller,
22
+ SwapDescription calldata desc,
23
+ bytes calldata executorData,
24
+ bytes calldata clientData
25
+ ) external payable returns (uint256, uint256);
26
+
27
+ function swapSimpleMode(
28
+ IAggregationExecutor caller,
29
+ SwapDescription calldata desc,
30
+ bytes calldata executorData,
31
+ bytes calldata clientData
32
+ ) external returns (uint256, uint256);
33
+ }
@@ -0,0 +1,42 @@
1
+ // SPDX-License-Identifier: MIT
2
+ pragma solidity 0.8.17;
3
+
4
+ import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
5
+ import "./IAggregationExecutor.sol";
6
+
7
+ interface IMetaAggregationRouterV2 {
8
+ struct SwapDescriptionV2 {
9
+ IERC20 srcToken;
10
+ IERC20 dstToken;
11
+ address[] srcReceivers; // transfer src token to these addresses, default
12
+ uint256[] srcAmounts;
13
+ address[] feeReceivers;
14
+ uint256[] feeAmounts;
15
+ address dstReceiver;
16
+ uint256 amount;
17
+ uint256 minReturnAmount;
18
+ uint256 flags;
19
+ bytes permit;
20
+ }
21
+
22
+ /// @dev use for swapGeneric and swap to avoid stack too deep
23
+ struct SwapExecutionParams {
24
+ address callTarget; // call this address
25
+ address approveTarget; // approve this address if _APPROVE_FUND set
26
+ bytes targetData;
27
+ SwapDescriptionV2 desc;
28
+ bytes clientData;
29
+ }
30
+
31
+ function swap(SwapExecutionParams calldata execution)
32
+ external
33
+ payable
34
+ returns (uint256, uint256);
35
+
36
+ function swapSimpleMode(
37
+ IAggregationExecutor caller,
38
+ SwapDescriptionV2 memory desc,
39
+ bytes calldata executorData,
40
+ bytes calldata clientData
41
+ ) external returns (uint256, uint256);
42
+ }
@@ -26,5 +26,5 @@
26
26
  "senderEndpoint": "0x07b1014c88f14C9E910092526db57A20052E989F",
27
27
  "votingController": "0x44087E105137a5095c008AaB6a6530182821F2F0",
28
28
  "gaugeController": "0x47D74516B33eD5D70ddE7119A40839f6Fcc24e57",
29
- "feedistributor": "0xd7b34a6fDCb2A7ceD2115FF7f5fdD72aa6aA4dE2"
29
+ "feeDistributor": "0xd7b34a6fDCb2A7ceD2115FF7f5fdD72aa6aA4dE2"
30
30
  }
@@ -0,0 +1,11 @@
1
+ {
2
+ "name": "SY rETH-WETH_BalancerLP Aura",
3
+ "SY": "0xdf7083f2A0F8a191ab5eEAFebE92ED21cD3Dd915",
4
+ "YT": "0x0F28A763198035825dFAdF3455cB5b8473a7c140",
5
+ "PT": "0xfbd85BF7A1E1bec0da6D12964B8c05471aE8f048",
6
+ "market": "0x5546d0f27BEd4075eA03a22c58F7016E24c94EA7",
7
+ "expiry": 1703721600,
8
+ "bulkSeller": "0xB2075aeEd11C2D261c3D80c957F495D18cF874ed",
9
+ "scalarRoot": "27500000000000000000",
10
+ "initAnchor": "1067325733000000000"
11
+ }
@@ -0,0 +1,10 @@
1
+ {
2
+ "name": "SY wstETH-WETH_BalancerLP Aura",
3
+ "SY": "0x8267fdabd1b8C8645138f2dE5B0fe24988DC9820",
4
+ "YT": "0x37fEc7b2f36f3bbAe956262F46ddF21830fa68ef",
5
+ "PT": "0xf6A865c4B9b087fFDd1e0DF8b5Dbb89Ee3546f49",
6
+ "market": "0xFcbAe4635CA89866F83Add208eCcEec742678746",
7
+ "expiry": 1719446400,
8
+ "scalarRoot": "28880000000000000000",
9
+ "initAnchor": "1105675000000000000"
10
+ }
@@ -0,0 +1,4 @@
1
+ {
2
+ "multicall": "0x0E7cacc6C2A22Aa2D97a42a8C82edaF9F9eac259",
3
+ "implicitSwapfeeContract": "0x43D03031FAb845065e9CEfE89Dd122d63F72011F"
4
+ }
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@pendle/core-v2",
3
3
  "description": "Core smart contracts of Pendle Protocol.",
4
4
  "license": "BUSL-1.1",
5
- "version": "1.2.0-mainnet",
5
+ "version": "1.4.0-mainnet",
6
6
  "homepage": "https://pendle.finance",
7
7
  "keywords": [
8
8
  "pendle",
@@ -25,16 +25,16 @@
25
25
  "devDependencies": {
26
26
  "@typechain/ethers-v5": "^9.0.0",
27
27
  "@typechain/hardhat": "^4.0.0",
28
- "hardhat": "^2.12.2",
28
+ "hardhat": "^2.12.5",
29
29
  "hardhat-contract-sizer": "^2.6.1",
30
30
  "hardhat-storage-layout-diff": "^0.0.4",
31
- "prettier": "^2.7.1",
32
- "prettier-plugin-solidity": "^1.0.0-rc.1",
31
+ "prettier": "^2.8.2",
32
+ "prettier-plugin-solidity": "^1.1.1",
33
33
  "solc": "^0.8.17",
34
34
  "solhint": "^3.3.7",
35
35
  "ts-node": "^10.9.1",
36
36
  "typechain": "^8.1.1",
37
- "typescript": "^4.9.3"
37
+ "typescript": "^4.9.4"
38
38
  },
39
39
  "scripts": {
40
40
  "compile": "yarn hardhat compile",
@@ -42,7 +42,7 @@
42
42
  "clean": "yarn hardhat clean",
43
43
  "fcompile": "yarn clean && yarn compile"
44
44
  },
45
- "packageManager": "yarn@3.2.2",
45
+ "packageManager": "yarn@3.3.1",
46
46
  "dependencies": {
47
47
  "@openzeppelin/contracts": "4.7.3",
48
48
  "@openzeppelin/contracts-upgradeable": "4.7.3"
@@ -0,0 +1,217 @@
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ import {
5
+ BaseContract,
6
+ BigNumber,
7
+ BigNumberish,
8
+ BytesLike,
9
+ CallOverrides,
10
+ PopulatedTransaction,
11
+ Signer,
12
+ utils,
13
+ } from "ethers";
14
+ import { FunctionFragment, Result } from "@ethersproject/abi";
15
+ import { Listener, Provider } from "@ethersproject/providers";
16
+ import type {
17
+ TypedEventFilter,
18
+ TypedEvent,
19
+ TypedListener,
20
+ OnEvent,
21
+ } from "./common";
22
+
23
+ export declare namespace IVault {
24
+ export type ExitPoolRequestStruct = {
25
+ assets: string[];
26
+ minAmountsOut: BigNumberish[];
27
+ userData: BytesLike;
28
+ toInternalBalance: boolean;
29
+ };
30
+
31
+ export type ExitPoolRequestStructOutput = [
32
+ string[],
33
+ BigNumber[],
34
+ string,
35
+ boolean
36
+ ] & {
37
+ assets: string[];
38
+ minAmountsOut: BigNumber[];
39
+ userData: string;
40
+ toInternalBalance: boolean;
41
+ };
42
+
43
+ export type JoinPoolRequestStruct = {
44
+ assets: string[];
45
+ maxAmountsIn: BigNumberish[];
46
+ userData: BytesLike;
47
+ fromInternalBalance: boolean;
48
+ };
49
+
50
+ export type JoinPoolRequestStructOutput = [
51
+ string[],
52
+ BigNumber[],
53
+ string,
54
+ boolean
55
+ ] & {
56
+ assets: string[];
57
+ maxAmountsIn: BigNumber[];
58
+ userData: string;
59
+ fromInternalBalance: boolean;
60
+ };
61
+ }
62
+
63
+ export interface ComposableStablePreviewInterface extends utils.Interface {
64
+ contractName: "ComposableStablePreview";
65
+ functions: {
66
+ "exitPoolPreview(bytes32,address,address,(address[],uint256[],bytes,bool),bytes)": FunctionFragment;
67
+ "joinPoolPreview(bytes32,address,address,(address[],uint256[],bytes,bool),bytes)": FunctionFragment;
68
+ };
69
+
70
+ encodeFunctionData(
71
+ functionFragment: "exitPoolPreview",
72
+ values: [BytesLike, string, string, IVault.ExitPoolRequestStruct, BytesLike]
73
+ ): string;
74
+ encodeFunctionData(
75
+ functionFragment: "joinPoolPreview",
76
+ values: [BytesLike, string, string, IVault.JoinPoolRequestStruct, BytesLike]
77
+ ): string;
78
+
79
+ decodeFunctionResult(
80
+ functionFragment: "exitPoolPreview",
81
+ data: BytesLike
82
+ ): Result;
83
+ decodeFunctionResult(
84
+ functionFragment: "joinPoolPreview",
85
+ data: BytesLike
86
+ ): Result;
87
+
88
+ events: {};
89
+ }
90
+
91
+ export interface ComposableStablePreview extends BaseContract {
92
+ contractName: "ComposableStablePreview";
93
+ connect(signerOrProvider: Signer | Provider | string): this;
94
+ attach(addressOrName: string): this;
95
+ deployed(): Promise<this>;
96
+
97
+ interface: ComposableStablePreviewInterface;
98
+
99
+ queryFilter<TEvent extends TypedEvent>(
100
+ event: TypedEventFilter<TEvent>,
101
+ fromBlockOrBlockhash?: string | number | undefined,
102
+ toBlock?: string | number | undefined
103
+ ): Promise<Array<TEvent>>;
104
+
105
+ listeners<TEvent extends TypedEvent>(
106
+ eventFilter?: TypedEventFilter<TEvent>
107
+ ): Array<TypedListener<TEvent>>;
108
+ listeners(eventName?: string): Array<Listener>;
109
+ removeAllListeners<TEvent extends TypedEvent>(
110
+ eventFilter: TypedEventFilter<TEvent>
111
+ ): this;
112
+ removeAllListeners(eventName?: string): this;
113
+ off: OnEvent<this>;
114
+ on: OnEvent<this>;
115
+ once: OnEvent<this>;
116
+ removeListener: OnEvent<this>;
117
+
118
+ functions: {
119
+ exitPoolPreview(
120
+ poolId: BytesLike,
121
+ sender: string,
122
+ recipient: string,
123
+ request: IVault.ExitPoolRequestStruct,
124
+ data: BytesLike,
125
+ overrides?: CallOverrides
126
+ ): Promise<[BigNumber] & { amountTokenOut: BigNumber }>;
127
+
128
+ joinPoolPreview(
129
+ poolId: BytesLike,
130
+ sender: string,
131
+ recipient: string,
132
+ request: IVault.JoinPoolRequestStruct,
133
+ data: BytesLike,
134
+ overrides?: CallOverrides
135
+ ): Promise<[BigNumber] & { amountBptOut: BigNumber }>;
136
+ };
137
+
138
+ exitPoolPreview(
139
+ poolId: BytesLike,
140
+ sender: string,
141
+ recipient: string,
142
+ request: IVault.ExitPoolRequestStruct,
143
+ data: BytesLike,
144
+ overrides?: CallOverrides
145
+ ): Promise<BigNumber>;
146
+
147
+ joinPoolPreview(
148
+ poolId: BytesLike,
149
+ sender: string,
150
+ recipient: string,
151
+ request: IVault.JoinPoolRequestStruct,
152
+ data: BytesLike,
153
+ overrides?: CallOverrides
154
+ ): Promise<BigNumber>;
155
+
156
+ callStatic: {
157
+ exitPoolPreview(
158
+ poolId: BytesLike,
159
+ sender: string,
160
+ recipient: string,
161
+ request: IVault.ExitPoolRequestStruct,
162
+ data: BytesLike,
163
+ overrides?: CallOverrides
164
+ ): Promise<BigNumber>;
165
+
166
+ joinPoolPreview(
167
+ poolId: BytesLike,
168
+ sender: string,
169
+ recipient: string,
170
+ request: IVault.JoinPoolRequestStruct,
171
+ data: BytesLike,
172
+ overrides?: CallOverrides
173
+ ): Promise<BigNumber>;
174
+ };
175
+
176
+ filters: {};
177
+
178
+ estimateGas: {
179
+ exitPoolPreview(
180
+ poolId: BytesLike,
181
+ sender: string,
182
+ recipient: string,
183
+ request: IVault.ExitPoolRequestStruct,
184
+ data: BytesLike,
185
+ overrides?: CallOverrides
186
+ ): Promise<BigNumber>;
187
+
188
+ joinPoolPreview(
189
+ poolId: BytesLike,
190
+ sender: string,
191
+ recipient: string,
192
+ request: IVault.JoinPoolRequestStruct,
193
+ data: BytesLike,
194
+ overrides?: CallOverrides
195
+ ): Promise<BigNumber>;
196
+ };
197
+
198
+ populateTransaction: {
199
+ exitPoolPreview(
200
+ poolId: BytesLike,
201
+ sender: string,
202
+ recipient: string,
203
+ request: IVault.ExitPoolRequestStruct,
204
+ data: BytesLike,
205
+ overrides?: CallOverrides
206
+ ): Promise<PopulatedTransaction>;
207
+
208
+ joinPoolPreview(
209
+ poolId: BytesLike,
210
+ sender: string,
211
+ recipient: string,
212
+ request: IVault.JoinPoolRequestStruct,
213
+ data: BytesLike,
214
+ overrides?: CallOverrides
215
+ ): Promise<PopulatedTransaction>;
216
+ };
217
+ }
@@ -0,0 +1,81 @@
1
+ /* Autogenerated file. Do not edit manually. */
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ import {
5
+ BaseContract,
6
+ BigNumber,
7
+ BytesLike,
8
+ CallOverrides,
9
+ PopulatedTransaction,
10
+ Signer,
11
+ utils,
12
+ } from "ethers";
13
+ import { FunctionFragment, Result } from "@ethersproject/abi";
14
+ import { Listener, Provider } from "@ethersproject/providers";
15
+ import type {
16
+ TypedEventFilter,
17
+ TypedEvent,
18
+ TypedListener,
19
+ OnEvent,
20
+ } from "./common";
21
+
22
+ export interface GMXPreviewHelperInterface extends utils.Interface {
23
+ contractName: "GMXPreviewHelper";
24
+ functions: {
25
+ "vault()": FunctionFragment;
26
+ };
27
+
28
+ encodeFunctionData(functionFragment: "vault", values?: undefined): string;
29
+
30
+ decodeFunctionResult(functionFragment: "vault", data: BytesLike): Result;
31
+
32
+ events: {};
33
+ }
34
+
35
+ export interface GMXPreviewHelper extends BaseContract {
36
+ contractName: "GMXPreviewHelper";
37
+ connect(signerOrProvider: Signer | Provider | string): this;
38
+ attach(addressOrName: string): this;
39
+ deployed(): Promise<this>;
40
+
41
+ interface: GMXPreviewHelperInterface;
42
+
43
+ queryFilter<TEvent extends TypedEvent>(
44
+ event: TypedEventFilter<TEvent>,
45
+ fromBlockOrBlockhash?: string | number | undefined,
46
+ toBlock?: string | number | undefined
47
+ ): Promise<Array<TEvent>>;
48
+
49
+ listeners<TEvent extends TypedEvent>(
50
+ eventFilter?: TypedEventFilter<TEvent>
51
+ ): Array<TypedListener<TEvent>>;
52
+ listeners(eventName?: string): Array<Listener>;
53
+ removeAllListeners<TEvent extends TypedEvent>(
54
+ eventFilter: TypedEventFilter<TEvent>
55
+ ): this;
56
+ removeAllListeners(eventName?: string): this;
57
+ off: OnEvent<this>;
58
+ on: OnEvent<this>;
59
+ once: OnEvent<this>;
60
+ removeListener: OnEvent<this>;
61
+
62
+ functions: {
63
+ vault(overrides?: CallOverrides): Promise<[string]>;
64
+ };
65
+
66
+ vault(overrides?: CallOverrides): Promise<string>;
67
+
68
+ callStatic: {
69
+ vault(overrides?: CallOverrides): Promise<string>;
70
+ };
71
+
72
+ filters: {};
73
+
74
+ estimateGas: {
75
+ vault(overrides?: CallOverrides): Promise<BigNumber>;
76
+ };
77
+
78
+ populateTransaction: {
79
+ vault(overrides?: CallOverrides): Promise<PopulatedTransaction>;
80
+ };
81
+ }