@pendle/core-v2 0.21.0-testnet → 1.0.1-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 (401) 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/FeeDistributor/EpochResultManager.sol/EpochResultManager.dbg.json +4 -0
  10. package/build/artifacts/contracts/{interfaces/IApeStaking.sol/IApeStaking.json → LiquidityMining/FeeDistributor/EpochResultManager.sol/EpochResultManager.json} +52 -70
  11. package/build/artifacts/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.dbg.json +4 -0
  12. package/build/artifacts/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.json +310 -0
  13. package/build/artifacts/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributorFactory.sol/PendleFeeDistributorFactory.dbg.json +4 -0
  14. package/build/artifacts/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributorFactory.sol/PendleFeeDistributorFactory.json +389 -0
  15. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerBaseUpg.sol/PendleGaugeControllerBaseUpg.dbg.json +1 -1
  16. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.dbg.json +1 -1
  17. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerMainchainUpg.sol/PendleGaugeControllerMainchainUpg.json +2 -2
  18. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.dbg.json +1 -1
  19. package/build/artifacts/contracts/LiquidityMining/GaugeController/PendleGaugeControllerSidechainUpg.sol/PendleGaugeControllerSidechainUpg.json +2 -2
  20. package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.dbg.json +1 -1
  21. package/build/artifacts/contracts/LiquidityMining/VotingController/PendleVotingControllerUpg.sol/PendleVotingControllerUpg.json +2 -2
  22. package/build/artifacts/contracts/LiquidityMining/VotingController/VotingControllerStorageUpg.sol/VotingControllerStorageUpg.dbg.json +1 -1
  23. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.dbg.json +1 -1
  24. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleMainchain.sol/VotingEscrowPendleMainchain.json +2 -2
  25. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.dbg.json +1 -1
  26. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowPendleSidechain.sol/VotingEscrowPendleSidechain.json +2 -2
  27. package/build/artifacts/contracts/LiquidityMining/VotingEscrow/VotingEscrowTokenBase.sol/VotingEscrowTokenBase.dbg.json +1 -1
  28. package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.dbg.json +1 -1
  29. package/build/artifacts/contracts/LiquidityMining/libraries/VeBalanceLib.sol/VeBalanceLib.json +2 -2
  30. package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.dbg.json +1 -1
  31. package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/CheckpointHelper.json +2 -2
  32. package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.dbg.json +1 -1
  33. package/build/artifacts/contracts/LiquidityMining/libraries/VeHistoryLib.sol/Checkpoints.json +2 -2
  34. package/build/artifacts/contracts/core/BulkSeller/BulkSeller.sol/BulkSeller.dbg.json +1 -1
  35. package/build/artifacts/contracts/core/BulkSeller/BulkSeller.sol/BulkSeller.json +2 -2
  36. package/build/artifacts/contracts/core/BulkSeller/BulkSellerFactory.sol/BulkSellerFactory.dbg.json +1 -1
  37. package/build/artifacts/contracts/core/BulkSeller/BulkSellerFactory.sol/BulkSellerFactory.json +2 -2
  38. package/build/artifacts/contracts/core/BulkSeller/BulkSellerMathCore.sol/BulkSellerMathCore.dbg.json +1 -1
  39. package/build/artifacts/contracts/core/BulkSeller/BulkSellerMathCore.sol/BulkSellerMathCore.json +2 -2
  40. package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.dbg.json +1 -1
  41. package/build/artifacts/contracts/core/Market/MarketMathCore.sol/MarketMathCore.json +2 -2
  42. package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.dbg.json +1 -1
  43. package/build/artifacts/contracts/core/Market/OracleLib.sol/OracleLib.json +2 -2
  44. package/build/artifacts/contracts/core/Market/PendleGauge.sol/PendleGauge.dbg.json +1 -1
  45. package/build/artifacts/contracts/core/Market/PendleMarket.sol/PendleMarket.dbg.json +1 -1
  46. package/build/artifacts/contracts/core/Market/PendleMarket.sol/PendleMarket.json +2 -2
  47. package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.dbg.json +1 -1
  48. package/build/artifacts/contracts/core/Market/PendleMarketFactory.sol/PendleMarketFactory.json +2 -2
  49. package/build/artifacts/contracts/core/RewardManager/RewardManager.sol/RewardManager.dbg.json +1 -1
  50. package/build/artifacts/contracts/core/RewardManager/RewardManagerAbstract.sol/RewardManagerAbstract.dbg.json +1 -1
  51. package/build/artifacts/contracts/core/StandardizedYield/SYBase.sol/SYBase.dbg.json +1 -1
  52. package/build/artifacts/contracts/core/StandardizedYield/SYBaseWithRewards.sol/SYBaseWithRewards.dbg.json +1 -1
  53. package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.dbg.json +1 -1
  54. package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenHelper.sol/PendleQiTokenHelper.json +2 -2
  55. package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenSY.sol/PendleQiTokenSY.dbg.json +1 -1
  56. package/build/artifacts/contracts/core/StandardizedYield/implementations/BenQi/PendleQiTokenSY.sol/PendleQiTokenSY.json +2 -2
  57. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveFraxUsdcSY.sol/PendleCurveFraxUsdcSY.dbg.json +1 -1
  58. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveFraxUsdcSY.sol/PendleCurveFraxUsdcSY.json +2 -2
  59. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveUsdd3CrvSY.sol/PendleCurveUsdd3CrvSY.dbg.json +1 -1
  60. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/PendleCurveUsdd3CrvSY.sol/PendleCurveUsdd3CrvSY.json +2 -2
  61. package/build/artifacts/contracts/core/StandardizedYield/implementations/Convex/base/PendleConvexLPSY.sol/PendleConvexLPSY.dbg.json +1 -1
  62. package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleLooksStakingSY.sol/PendleLooksStakingSY.dbg.json +1 -1
  63. package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleLooksStakingSY.sol/PendleLooksStakingSY.json +2 -2
  64. package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleWstEthSY.sol/PendleWstEthSY.dbg.json +1 -1
  65. package/build/artifacts/contracts/core/StandardizedYield/implementations/PendleWstEthSY.sol/PendleWstEthSY.json +2 -2
  66. package/build/artifacts/contracts/core/YieldContracts/PendlePrincipalToken.sol/PendlePrincipalToken.dbg.json +1 -1
  67. package/build/artifacts/contracts/core/YieldContracts/PendlePrincipalToken.sol/PendlePrincipalToken.json +2 -2
  68. package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactory.sol/PendleYieldContractFactory.dbg.json +1 -1
  69. package/build/artifacts/contracts/core/YieldContracts/PendleYieldContractFactory.sol/PendleYieldContractFactory.json +2 -2
  70. package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.dbg.json +1 -1
  71. package/build/artifacts/contracts/core/YieldContracts/PendleYieldToken.sol/PendleYieldToken.json +2 -2
  72. package/build/artifacts/contracts/core/libraries/ArrayLib.sol/ArrayLib.dbg.json +1 -1
  73. package/build/artifacts/contracts/core/libraries/ArrayLib.sol/ArrayLib.json +2 -2
  74. package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.dbg.json +1 -1
  75. package/build/artifacts/contracts/core/libraries/Errors.sol/Errors.json +5 -134
  76. package/build/artifacts/contracts/interfaces/ConvexCurve/IRewards.sol/IRewards.dbg.json +1 -1
  77. package/build/artifacts/contracts/interfaces/ConvexCurve/IRewards.sol/IRewards.json +0 -18
  78. package/build/artifacts/contracts/interfaces/IPActionAddRemoveLiq.sol/IPActionAddRemoveLiq.dbg.json +1 -1
  79. package/build/artifacts/contracts/interfaces/IPActionMintRedeem.sol/IPActionMintRedeem.dbg.json +1 -1
  80. package/build/artifacts/contracts/interfaces/IPActionSwapPT.sol/IPActionSwapPT.dbg.json +1 -1
  81. package/build/artifacts/contracts/interfaces/IPActionSwapPTYT.sol/IPActionSwapPTYT.dbg.json +1 -1
  82. package/build/artifacts/contracts/interfaces/IPActionSwapYT.sol/IPActionSwapYT.dbg.json +1 -1
  83. package/build/artifacts/contracts/interfaces/IPAllAction.sol/IPAllAction.dbg.json +1 -1
  84. package/build/artifacts/contracts/interfaces/IPBulkSeller.sol/IPBulkSeller.dbg.json +1 -1
  85. package/build/artifacts/contracts/interfaces/IPFeeDistributor.sol/IPFeeDistributor.dbg.json +1 -1
  86. package/build/artifacts/contracts/interfaces/IPFeeDistributor.sol/IPFeeDistributor.json +32 -43
  87. package/build/artifacts/contracts/interfaces/IPFeeDistributorFactory.sol/IPFeeDistributorFactory.dbg.json +4 -0
  88. package/build/artifacts/contracts/interfaces/{Balancer/IGauge.sol/IGauge.json → IPFeeDistributorFactory.sol/IPFeeDistributorFactory.json} +33 -18
  89. package/build/artifacts/contracts/interfaces/IPMarket.sol/IPMarket.dbg.json +1 -1
  90. package/build/artifacts/contracts/interfaces/IPVotingController.sol/IPVotingController.dbg.json +1 -1
  91. package/build/artifacts/contracts/interfaces/IPVotingEscrowMainchain.sol/IPVotingEscrowMainchain.dbg.json +1 -1
  92. package/build/artifacts/contracts/offchain-helpers/BulkSellerOffchain.sol/BulkSellerOffchain.dbg.json +1 -1
  93. package/build/artifacts/contracts/offchain-helpers/BulkSellerOffchain.sol/BulkSellerOffchain.json +2 -2
  94. package/build/artifacts/contracts/offchain-helpers/MarketMathStatic.sol/MarketMathStatic.dbg.json +1 -1
  95. package/build/artifacts/contracts/offchain-helpers/MarketMathStatic.sol/MarketMathStatic.json +2 -42
  96. package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.dbg.json +1 -1
  97. package/build/artifacts/contracts/offchain-helpers/RouterStatic.sol/RouterStatic.json +100 -73
  98. package/build/artifacts/contracts/router/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.dbg.json +1 -1
  99. package/build/artifacts/contracts/router/ActionAddRemoveLiq.sol/ActionAddRemoveLiq.json +2 -2
  100. package/build/artifacts/contracts/router/ActionCallback.sol/ActionCallback.dbg.json +1 -1
  101. package/build/artifacts/contracts/router/ActionCallback.sol/ActionCallback.json +2 -2
  102. package/build/artifacts/contracts/router/ActionMintRedeem.sol/ActionMintRedeem.dbg.json +1 -1
  103. package/build/artifacts/contracts/router/ActionMintRedeem.sol/ActionMintRedeem.json +2 -2
  104. package/build/artifacts/contracts/router/ActionMisc.sol/ActionMisc.dbg.json +1 -1
  105. package/build/artifacts/contracts/router/ActionMisc.sol/ActionMisc.json +2 -2
  106. package/build/artifacts/contracts/router/ActionSwapPT.sol/ActionSwapPT.dbg.json +1 -1
  107. package/build/artifacts/contracts/router/ActionSwapPT.sol/ActionSwapPT.json +2 -2
  108. package/build/artifacts/contracts/router/ActionSwapPTYT.sol/ActionSwapPTYT.dbg.json +1 -1
  109. package/build/artifacts/contracts/router/ActionSwapPTYT.sol/ActionSwapPTYT.json +2 -2
  110. package/build/artifacts/contracts/router/ActionSwapYT.sol/ActionSwapYT.dbg.json +1 -1
  111. package/build/artifacts/contracts/router/ActionSwapYT.sol/ActionSwapYT.json +2 -2
  112. package/build/artifacts/contracts/router/PendleRouter.sol/PendleRouter.dbg.json +1 -1
  113. package/build/artifacts/contracts/router/PendleRouter.sol/PendleRouter.json +2 -2
  114. package/build/artifacts/contracts/router/base/ActionBaseMintRedeem.sol/ActionBaseMintRedeem.dbg.json +1 -1
  115. package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtInLib.dbg.json +1 -1
  116. package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtInLib.json +2 -2
  117. package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtOutLib.dbg.json +1 -1
  118. package/build/artifacts/contracts/router/base/MarketApproxLib.sol/MarketApproxPtOutLib.json +2 -2
  119. package/build/artifacts/contracts/router/kyberswap/AggregationRouterHelper.sol/AggregationRouterHelper.dbg.json +1 -1
  120. package/build/artifacts/contracts/router/kyberswap/AggregationRouterHelper.sol/AggregationRouterHelper.json +2 -2
  121. package/build/artifacts/contracts/router/kyberswap/IAggregatorRouterHelper.sol/IAggregationRouterHelper.dbg.json +1 -1
  122. package/build/artifacts/contracts/router/kyberswap/IMultihopRouter.sol/IMultihopRouter.dbg.json +4 -0
  123. package/build/artifacts/contracts/router/kyberswap/IMultihopRouter.sol/IMultihopRouter.json +136 -0
  124. package/build/artifacts/contracts/router/kyberswap/KyberSwapHelper.sol/KyberSwapHelper.dbg.json +1 -1
  125. package/contracts/LiquidityMining/CrossChainMsg/libraries/LayerZeroHelper.sol +9 -7
  126. package/contracts/LiquidityMining/FeeDistributor/EpochResultManager.sol +159 -0
  127. package/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributor.sol +99 -0
  128. package/contracts/LiquidityMining/FeeDistributor/PendleFeeDistributorFactory.sol +70 -0
  129. package/contracts/core/BulkSeller/BulkSeller.sol +1 -1
  130. package/contracts/core/StandardizedYield/SYBaseWithRewards.sol +3 -1
  131. package/contracts/core/libraries/ArrayLib.sol +0 -12
  132. package/contracts/core/libraries/Errors.sol +2 -15
  133. package/contracts/interfaces/ConvexCurve/IRewards.sol +0 -5
  134. package/contracts/interfaces/IPFeeDistributor.sol +10 -12
  135. package/contracts/interfaces/IPFeeDistributorFactory.sol +14 -0
  136. package/contracts/offchain-helpers/MarketMathStatic.sol +1 -1
  137. package/contracts/router/kyberswap/AggregationRouterHelper.sol +192 -194
  138. package/contracts/router/kyberswap/IMultihopRouter.sol +139 -0
  139. package/deployments/1-core.json +29 -0
  140. package/deployments/1-markets/FRAXUSDC-CURVELP-MARCH30.json +11 -0
  141. package/deployments/1-markets/LOOKS-STAKING-MARCH30.json +10 -0
  142. package/deployments/1-markets/STETH-JUNE29.json +10 -0
  143. package/deployments/1-markets/STETH-MARCH30.json +10 -0
  144. package/package.json +6 -6
  145. package/typechain-types/IApeStaking.ts +0 -31
  146. package/typechain-types/IPFeeDistributor.ts +78 -61
  147. package/typechain-types/IPFeeDistributorFactory.ts +139 -53
  148. package/typechain-types/IRewards.ts +5 -35
  149. package/typechain-types/MarketMathStatic.ts +0 -49
  150. package/typechain-types/PendleApeStakingSY.ts +204 -88
  151. package/typechain-types/PendleFeeDistributor.ts +117 -409
  152. package/typechain-types/RouterStatic.ts +49 -0
  153. package/typechain-types/factories/ActionAddRemoveLiq__factory.ts +1 -1
  154. package/typechain-types/factories/ActionCallback__factory.ts +1 -1
  155. package/typechain-types/factories/ActionMintRedeem__factory.ts +1 -1
  156. package/typechain-types/factories/ActionMisc__factory.ts +1 -1
  157. package/typechain-types/factories/ActionSwapPTYT__factory.ts +1 -1
  158. package/typechain-types/factories/ActionSwapPT__factory.ts +1 -1
  159. package/typechain-types/factories/ActionSwapYT__factory.ts +1 -1
  160. package/typechain-types/factories/AggregationRouterHelper__factory.ts +1 -1
  161. package/typechain-types/factories/BulkSellerFactory__factory.ts +1 -1
  162. package/typechain-types/factories/BulkSellerOffchain__factory.ts +1 -1
  163. package/typechain-types/factories/BulkSeller__factory.ts +1 -1
  164. package/typechain-types/factories/Errors__factory.ts +4 -133
  165. package/typechain-types/factories/IApeStaking__factory.ts +0 -34
  166. package/typechain-types/factories/IPFeeDistributorFactory__factory.ts +34 -25
  167. package/typechain-types/factories/IPFeeDistributor__factory.ts +31 -42
  168. package/typechain-types/factories/IRewards__factory.ts +0 -18
  169. package/typechain-types/factories/MarketMathStatic__factory.ts +1 -41
  170. package/typechain-types/factories/OracleLib__factory.ts +1 -1
  171. package/typechain-types/factories/PendleApeStakingSY__factory.ts +141 -57
  172. package/typechain-types/factories/PendleCurveFraxUsdcSY__factory.ts +1 -1
  173. package/typechain-types/factories/PendleCurveUsdd3CrvSY__factory.ts +1 -1
  174. package/typechain-types/factories/PendleFeeDistributorFactory__factory.ts +1 -1
  175. package/typechain-types/factories/PendleFeeDistributor__factory.ts +66 -341
  176. package/typechain-types/factories/PendleGaugeControllerMainchainUpg__factory.ts +1 -1
  177. package/typechain-types/factories/PendleGaugeControllerSidechainUpg__factory.ts +1 -1
  178. package/typechain-types/factories/PendleLooksStakingSY__factory.ts +1 -1
  179. package/typechain-types/factories/PendleMarketFactory__factory.ts +1 -1
  180. package/typechain-types/factories/PendleMarket__factory.ts +1 -1
  181. package/typechain-types/factories/PendleMsgReceiveEndpointUpg__factory.ts +1 -1
  182. package/typechain-types/factories/PendleMsgSendEndpointUpg__factory.ts +1 -1
  183. package/typechain-types/factories/PendlePrincipalToken__factory.ts +1 -1
  184. package/typechain-types/factories/PendleQiTokenHelper__factory.ts +1 -1
  185. package/typechain-types/factories/PendleQiTokenSY__factory.ts +1 -1
  186. package/typechain-types/factories/PendleRouter__factory.ts +1 -1
  187. package/typechain-types/factories/PendleVotingControllerUpg__factory.ts +1 -1
  188. package/typechain-types/factories/PendleWstEthSY__factory.ts +1 -1
  189. package/typechain-types/factories/PendleYieldContractFactory__factory.ts +1 -1
  190. package/typechain-types/factories/PendleYieldToken__factory.ts +1 -1
  191. package/typechain-types/factories/RouterStatic__factory.ts +41 -18
  192. package/typechain-types/factories/VotingEscrowPendleMainchain__factory.ts +1 -1
  193. package/typechain-types/factories/VotingEscrowPendleSidechain__factory.ts +1 -1
  194. package/typechain-types/hardhat.d.ts +40 -301
  195. package/typechain-types/index.ts +10 -68
  196. package/build/artifacts/contracts/LiquidityMining/VeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.dbg.json +0 -4
  197. package/build/artifacts/contracts/LiquidityMining/VeDistributor/PendleFeeDistributor.sol/PendleFeeDistributor.json +0 -592
  198. package/build/artifacts/contracts/core/StandardizedYield/StEthHelper.sol/StEthHelper.dbg.json +0 -4
  199. package/build/artifacts/contracts/core/StandardizedYield/StEthHelper.sol/StEthHelper.json +0 -10
  200. package/build/artifacts/contracts/core/StandardizedYield/implementations/Ape/sAPE.sol/sAPE.dbg.json +0 -4
  201. package/build/artifacts/contracts/core/StandardizedYield/implementations/Ape/sAPE.sol/sAPE.json +0 -1075
  202. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAura3EthSY.sol/PendleAura3EthSY.dbg.json +0 -4
  203. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAura3EthSY.sol/PendleAura3EthSY.json +0 -1257
  204. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraCbethWstethSY.sol/PendleAuraCbethWstethSY.dbg.json +0 -4
  205. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraCbethWstethSY.sol/PendleAuraCbethWstethSY.json +0 -1244
  206. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethRethSY.sol/PendleAuraWethRethSY.dbg.json +0 -4
  207. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethRethSY.sol/PendleAuraWethRethSY.json +0 -1218
  208. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethWstethSY.sol/PendleAuraWethWstethSY.dbg.json +0 -4
  209. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethWstethSY.sol/PendleAuraWethWstethSY.json +0 -1192
  210. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStableMath.sol/ComposableStableMath.dbg.json +0 -4
  211. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStableMath.sol/ComposableStableMath.json +0 -10
  212. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStablePreview.sol/ComposableStablePreview.dbg.json +0 -4
  213. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStablePreview.sol/ComposableStablePreview.json +0 -133
  214. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/FixedPoint.sol/FixedPoint.dbg.json +0 -4
  215. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/FixedPoint.sol/FixedPoint.json +0 -10
  216. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStableMath.sol/MetaStableMath.dbg.json +0 -4
  217. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStableMath.sol/MetaStableMath.json +0 -40
  218. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStablePreview.sol/MetaStablePreview.dbg.json +0 -4
  219. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStablePreview.sol/MetaStablePreview.json +0 -322
  220. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/PendleAuraBalancerStableLPSY.sol/PendleAuraBalancerStableLPSY.dbg.json +0 -4
  221. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/PendleAuraBalancerStableLPSY.sol/PendleAuraBalancerStableLPSY.json +0 -1171
  222. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePoolUserData.sol/StablePoolUserData.dbg.json +0 -4
  223. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePoolUserData.sol/StablePoolUserData.json +0 -10
  224. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePreviewBase.sol/StablePreviewBase.dbg.json +0 -4
  225. package/build/artifacts/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePreviewBase.sol/StablePreviewBase.json +0 -133
  226. package/build/artifacts/contracts/interfaces/Balancer/IAsset.sol/IAsset.dbg.json +0 -4
  227. package/build/artifacts/contracts/interfaces/Balancer/IAsset.sol/IAsset.json +0 -10
  228. package/build/artifacts/contracts/interfaces/Balancer/IBalancerFees.sol/IBalancerFees.dbg.json +0 -4
  229. package/build/artifacts/contracts/interfaces/Balancer/IBalancerFees.sol/IBalancerFees.json +0 -24
  230. package/build/artifacts/contracts/interfaces/Balancer/IBalancerStablePreview.sol/IBalancerStablePreview.dbg.json +0 -4
  231. package/build/artifacts/contracts/interfaces/Balancer/IBalancerStablePreview.sol/IBalancerStablePreview.json +0 -133
  232. package/build/artifacts/contracts/interfaces/Balancer/IBasePool.sol/IBasePool.dbg.json +0 -4
  233. package/build/artifacts/contracts/interfaces/Balancer/IBasePool.sol/IBasePool.json +0 -328
  234. package/build/artifacts/contracts/interfaces/Balancer/IComposableStable.sol/IComposableStable.dbg.json +0 -4
  235. package/build/artifacts/contracts/interfaces/Balancer/IComposableStable.sol/IComposableStable.json +0 -467
  236. package/build/artifacts/contracts/interfaces/Balancer/IGauge.sol/IGauge.dbg.json +0 -4
  237. package/build/artifacts/contracts/interfaces/Balancer/ILiquidityGaugeFactory.sol/ILiquidityGaugeFactory.dbg.json +0 -4
  238. package/build/artifacts/contracts/interfaces/Balancer/ILiquidityGaugeFactory.sol/ILiquidityGaugeFactory.json +0 -30
  239. package/build/artifacts/contracts/interfaces/Balancer/IMetaStablePool.sol/IMetaStablePool.dbg.json +0 -4
  240. package/build/artifacts/contracts/interfaces/Balancer/IMetaStablePool.sol/IMetaStablePool.json +0 -398
  241. package/build/artifacts/contracts/interfaces/Balancer/IRateProvider.sol/IRateProvider.dbg.json +0 -4
  242. package/build/artifacts/contracts/interfaces/Balancer/IRateProvider.sol/IRateProvider.json +0 -24
  243. package/build/artifacts/contracts/interfaces/Balancer/IVault.sol/IVault.dbg.json +0 -4
  244. package/build/artifacts/contracts/interfaces/Balancer/IVault.sol/IVault.json +0 -278
  245. package/build/artifacts/contracts/interfaces/IApeStaking.sol/IApeStaking.dbg.json +0 -4
  246. package/build/artifacts/contracts/offchain-helpers/Multicall2.sol/Multicall2.dbg.json +0 -4
  247. package/build/artifacts/contracts/offchain-helpers/Multicall2.sol/Multicall2.json +0 -322
  248. package/build/artifacts/contracts/offchain-helpers/PendleMulticall.sol/PendleMulticall.dbg.json +0 -4
  249. package/build/artifacts/contracts/offchain-helpers/PendleMulticall.sol/PendleMulticall.json +0 -47
  250. package/build/artifacts/contracts/router/kyberswap/ScaleDataHelperEthereum1.sol/ScaleDataHelperEthereum1.dbg.json +0 -4
  251. package/build/artifacts/contracts/router/kyberswap/ScaleDataHelperEthereum1.sol/ScaleDataHelperEthereum1.json +0 -10
  252. package/build/artifacts/contracts/router/kyberswap/interfaces/IAggregationExecutor.sol/IAggregationExecutor.dbg.json +0 -4
  253. package/build/artifacts/contracts/router/kyberswap/interfaces/IAggregationExecutor.sol/IAggregationExecutor.json +0 -65
  254. package/build/artifacts/contracts/router/kyberswap/interfaces/IExecutorHelperEthereum1.sol/IExecutorHelperEthereum1.dbg.json +0 -4
  255. package/build/artifacts/contracts/router/kyberswap/interfaces/IExecutorHelperEthereum1.sol/IExecutorHelperEthereum1.json +0 -388
  256. package/build/artifacts/contracts/router/kyberswap/interfaces/IHashflow.sol/IHashflow.dbg.json +0 -4
  257. package/build/artifacts/contracts/router/kyberswap/interfaces/IHashflow.sol/IHashflow.json +0 -101
  258. package/build/artifacts/contracts/router/kyberswap/interfaces/IMetaAggregationRouter.sol/IMetaAggregationRouter.dbg.json +0 -4
  259. package/build/artifacts/contracts/router/kyberswap/interfaces/IMetaAggregationRouter.sol/IMetaAggregationRouter.json +0 -183
  260. package/build/artifacts/contracts/router/kyberswap/interfaces/IMetaAggregationRouterV2.sol/IMetaAggregationRouterV2.dbg.json +0 -4
  261. package/build/artifacts/contracts/router/kyberswap/interfaces/IMetaAggregationRouterV2.sol/IMetaAggregationRouterV2.json +0 -215
  262. package/contracts/LiquidityMining/VeDistributor/PendleFeeDistributor.sol +0 -224
  263. package/contracts/core/StandardizedYield/StEthHelper.sol +0 -71
  264. package/contracts/core/StandardizedYield/implementations/Ape/sAPE.sol +0 -197
  265. package/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAura3EthSY.sol +0 -170
  266. package/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraCbethWstethSY.sol +0 -162
  267. package/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethRethSY.sol +0 -134
  268. package/contracts/core/StandardizedYield/implementations/BalancerStable/PendleAuraWethWstethSY.sol +0 -154
  269. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStableMath.sol +0 -289
  270. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/ComposableStable/ComposableStablePreview.sol +0 -618
  271. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/FixedPoint.sol +0 -68
  272. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStableMath.sol +0 -322
  273. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/MetaStable/MetaStablePreview.sol +0 -390
  274. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/PendleAuraBalancerStableLPSY.sol +0 -329
  275. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePoolUserData.sol +0 -30
  276. package/contracts/core/StandardizedYield/implementations/BalancerStable/base/StablePreviewBase.sol +0 -189
  277. package/contracts/interfaces/Balancer/IAsset.sol +0 -4
  278. package/contracts/interfaces/Balancer/IBalancerFees.sol +0 -6
  279. package/contracts/interfaces/Balancer/IBalancerStablePreview.sol +0 -22
  280. package/contracts/interfaces/Balancer/IBasePool.sol +0 -30
  281. package/contracts/interfaces/Balancer/IComposableStable.sol +0 -39
  282. package/contracts/interfaces/Balancer/IGauge.sol +0 -10
  283. package/contracts/interfaces/Balancer/ILiquidityGaugeFactory.sol +0 -6
  284. package/contracts/interfaces/Balancer/IMetaStablePool.sol +0 -31
  285. package/contracts/interfaces/Balancer/IRateProvider.sol +0 -6
  286. package/contracts/interfaces/Balancer/IVault.sol +0 -78
  287. package/contracts/interfaces/IApeStaking.sol +0 -30
  288. package/contracts/offchain-helpers/Multicall2.sol +0 -103
  289. package/contracts/offchain-helpers/PendleMulticall.sol +0 -26
  290. package/contracts/router/kyberswap/ScaleDataHelperEthereum1.sol +0 -147
  291. package/contracts/router/kyberswap/interfaces/IAggregationExecutor.sol +0 -17
  292. package/contracts/router/kyberswap/interfaces/IExecutorHelperEthereum1.sol +0 -191
  293. package/contracts/router/kyberswap/interfaces/IHashflow.sol +0 -30
  294. package/contracts/router/kyberswap/interfaces/IMetaAggregationRouter.sol +0 -33
  295. package/contracts/router/kyberswap/interfaces/IMetaAggregationRouterV2.sol +0 -42
  296. package/deployments/43113-core.json +0 -29
  297. package/deployments/43113-helper.json +0 -4
  298. package/deployments/43113-markets/APE-30-MARCH.json +0 -10
  299. package/deployments/43113-markets/USDC-FEB-2ND.json +0 -10
  300. package/deployments/43113-markets/USDC-FEB-4TH.json +0 -10
  301. package/deployments/43113-markets/WETH-FEB-2ND.json +0 -11
  302. package/deployments/43113-markets/WETH-FEB-4TH.json +0 -11
  303. package/deployments/43113-testenv.json +0 -22
  304. package/deployments/80001-core.json +0 -28
  305. package/deployments/80001-helper.json +0 -4
  306. package/deployments/80001-markets/USDC-DEC-8TH.json +0 -10
  307. package/deployments/80001-markets/USDC-FEB-4TH.json +0 -10
  308. package/deployments/80001-markets/WETH-FEB-4TH.json +0 -11
  309. package/deployments/80001-testenv.json +0 -22
  310. package/typechain-types/BribeDistributor.ts +0 -363
  311. package/typechain-types/ComposableStablePreview.ts +0 -217
  312. package/typechain-types/DistributorBase.ts +0 -363
  313. package/typechain-types/FeeDistributor.ts +0 -416
  314. package/typechain-types/GMXPreviewHelper.ts +0 -134
  315. package/typechain-types/I1inchAggregationRouterV5.ts +0 -257
  316. package/typechain-types/IAggregationExecutor.ts +0 -182
  317. package/typechain-types/IBalancerFees.ts +0 -89
  318. package/typechain-types/IBalancerStablePreview.ts +0 -217
  319. package/typechain-types/IBasePool.ts +0 -482
  320. package/typechain-types/IComposableStable.ts +0 -730
  321. package/typechain-types/IExecutorHelperEthereum1.ts +0 -643
  322. package/typechain-types/IGMXVault.ts +0 -494
  323. package/typechain-types/IGauge.ts +0 -160
  324. package/typechain-types/IGlpManager.ts +0 -115
  325. package/typechain-types/IHashflow.ts +0 -159
  326. package/typechain-types/IKyberSwapAggregationRouterHelper.ts +0 -109
  327. package/typechain-types/ILiquidityGaugeFactory.ts +0 -99
  328. package/typechain-types/IMetaAggregationRouter.ts +0 -213
  329. package/typechain-types/IMetaAggregationRouterV2.ts +0 -221
  330. package/typechain-types/IMetaStablePool.ts +0 -619
  331. package/typechain-types/IMultihopRouterEthereum.ts +0 -209
  332. package/typechain-types/IPYieldTokenV2.ts +0 -915
  333. package/typechain-types/IRateProvider.ts +0 -81
  334. package/typechain-types/IRewardRouterV2.ts +0 -303
  335. package/typechain-types/ISwapAggregator.ts +0 -124
  336. package/typechain-types/IVault.ts +0 -410
  337. package/typechain-types/IVaultPriceFeed.ts +0 -114
  338. package/typechain-types/InterestManagerYTV2.ts +0 -124
  339. package/typechain-types/MetaStableMath.ts +0 -113
  340. package/typechain-types/MetaStablePreview.ts +0 -501
  341. package/typechain-types/Multicall2.ts +0 -437
  342. package/typechain-types/PendleAura3EthSY.ts +0 -1600
  343. package/typechain-types/PendleAuraBalancerStableLPSY.ts +0 -1523
  344. package/typechain-types/PendleAuraCbethWstethSY.ts +0 -1587
  345. package/typechain-types/PendleAuraWethRethSY.ts +0 -1549
  346. package/typechain-types/PendleAuraWethWstethSY.ts +0 -1523
  347. package/typechain-types/PendleGlpSY.ts +0 -1449
  348. package/typechain-types/PendleMulticall.ts +0 -110
  349. package/typechain-types/PendlePrincipalTokenV2.ts +0 -614
  350. package/typechain-types/PendleYieldContractFactoryV2.ts +0 -801
  351. package/typechain-types/PendleYieldTokenV2.ts +0 -1304
  352. package/typechain-types/SAPE.ts +0 -1395
  353. package/typechain-types/StEthHelper.ts +0 -107
  354. package/typechain-types/StablePreviewBase.ts +0 -217
  355. package/typechain-types/SwapAggregator.ts +0 -406
  356. package/typechain-types/factories/BribeDistributor__factory.ts +0 -303
  357. package/typechain-types/factories/ComposableStablePreview__factory.ts +0 -190
  358. package/typechain-types/factories/DistributorBase__factory.ts +0 -249
  359. package/typechain-types/factories/FeeDistributor__factory.ts +0 -339
  360. package/typechain-types/factories/GMXPreviewHelper__factory.ts +0 -78
  361. package/typechain-types/factories/I1inchAggregationRouterV5__factory.ts +0 -179
  362. package/typechain-types/factories/IAggregationExecutor__factory.ts +0 -84
  363. package/typechain-types/factories/IBalancerFees__factory.ts +0 -36
  364. package/typechain-types/factories/IBalancerStablePreview__factory.ts +0 -152
  365. package/typechain-types/factories/IBasePool__factory.ts +0 -340
  366. package/typechain-types/factories/IComposableStable__factory.ts +0 -482
  367. package/typechain-types/factories/IExecutorHelperEthereum1__factory.ts +0 -407
  368. package/typechain-types/factories/IGMXVault__factory.ts +0 -320
  369. package/typechain-types/factories/IGauge__factory.ts +0 -70
  370. package/typechain-types/factories/IGlpManager__factory.ts +0 -55
  371. package/typechain-types/factories/IHashflow__factory.ts +0 -113
  372. package/typechain-types/factories/IKyberSwapAggregationRouterHelper__factory.ts +0 -56
  373. package/typechain-types/factories/ILiquidityGaugeFactory__factory.ts +0 -49
  374. package/typechain-types/factories/IMetaAggregationRouterV2__factory.ts +0 -234
  375. package/typechain-types/factories/IMetaAggregationRouter__factory.ts +0 -202
  376. package/typechain-types/factories/IMetaStablePool__factory.ts +0 -413
  377. package/typechain-types/factories/IMultihopRouterEthereum__factory.ts +0 -155
  378. package/typechain-types/factories/IPYieldTokenV2__factory.ts +0 -702
  379. package/typechain-types/factories/IRateProvider__factory.ts +0 -36
  380. package/typechain-types/factories/IRewardRouterV2__factory.ts +0 -180
  381. package/typechain-types/factories/ISwapAggregator__factory.ts +0 -66
  382. package/typechain-types/factories/IVaultPriceFeed__factory.ts +0 -60
  383. package/typechain-types/factories/IVault__factory.ts +0 -287
  384. package/typechain-types/factories/InterestManagerYTV2__factory.ts +0 -63
  385. package/typechain-types/factories/MetaStableMath__factory.ts +0 -93
  386. package/typechain-types/factories/MetaStablePreview__factory.ts +0 -375
  387. package/typechain-types/factories/Multicall2__factory.ts +0 -372
  388. package/typechain-types/factories/PendleAura3EthSY__factory.ts +0 -1326
  389. package/typechain-types/factories/PendleAuraBalancerStableLPSY__factory.ts +0 -1190
  390. package/typechain-types/factories/PendleAuraCbethWstethSY__factory.ts +0 -1317
  391. package/typechain-types/factories/PendleAuraWethRethSY__factory.ts +0 -1291
  392. package/typechain-types/factories/PendleAuraWethWstethSY__factory.ts +0 -1265
  393. package/typechain-types/factories/PendleGlpSY__factory.ts +0 -1255
  394. package/typechain-types/factories/PendleMulticall__factory.ts +0 -100
  395. package/typechain-types/factories/PendlePrincipalTokenV2__factory.ts +0 -564
  396. package/typechain-types/factories/PendleYieldContractFactoryV2__factory.ts +0 -674
  397. package/typechain-types/factories/PendleYieldTokenV2__factory.ts +0 -1122
  398. package/typechain-types/factories/SAPE__factory.ts +0 -1142
  399. package/typechain-types/factories/StEthHelper__factory.ts +0 -62
  400. package/typechain-types/factories/StablePreviewBase__factory.ts +0 -148
  401. package/typechain-types/factories/SwapAggregator__factory.ts +0 -309
@@ -1,31 +0,0 @@
1
- // SPDX-License-Identifier: GPL-3.0-or-later
2
- pragma solidity 0.8.17;
3
-
4
- import "./IBasePool.sol";
5
-
6
- interface IMetaStablePool is IBasePool {
7
- function getLastInvariant()
8
- external
9
- view
10
- returns (uint256 lastInvariant, uint256 lastInvariantAmp);
11
-
12
- function getAmplificationParameter()
13
- external
14
- view
15
- returns (
16
- uint256 value,
17
- bool isUpdating,
18
- uint256 precision
19
- );
20
-
21
- function getSwapFeePercentage() external view returns (uint256);
22
-
23
- function getPriceRateCache(IERC20 token)
24
- external
25
- view
26
- returns (
27
- uint256 rate,
28
- uint256 duration,
29
- uint256 expires
30
- );
31
- }
@@ -1,6 +0,0 @@
1
- // SPDX-License-Identifier: GPL-3.0-or-later
2
- pragma solidity 0.8.17;
3
-
4
- interface IRateProvider {
5
- function getRate() external view returns (uint256);
6
- }
@@ -1,78 +0,0 @@
1
- // SPDX-License-Identifier: GPL-3.0-or-later
2
- pragma solidity 0.8.17;
3
-
4
- import "@openzeppelin/contracts/token/ERC20/IERC20.sol";
5
- import "./IAsset.sol";
6
-
7
- interface IVault {
8
- struct JoinPoolRequest {
9
- address[] assets;
10
- uint256[] maxAmountsIn;
11
- bytes userData;
12
- bool fromInternalBalance;
13
- }
14
-
15
- function joinPool(
16
- bytes32 poolId,
17
- address sender,
18
- address recipient,
19
- JoinPoolRequest memory request
20
- ) external payable;
21
-
22
- struct ExitPoolRequest {
23
- address[] assets;
24
- uint256[] minAmountsOut;
25
- bytes userData;
26
- bool toInternalBalance;
27
- }
28
-
29
- function exitPool(
30
- bytes32 poolId,
31
- address sender,
32
- address payable recipient,
33
- ExitPoolRequest memory request
34
- ) external;
35
-
36
- enum SwapKind {
37
- GIVEN_IN,
38
- GIVEN_OUT
39
- }
40
-
41
- struct SingleSwap {
42
- bytes32 poolId;
43
- SwapKind kind;
44
- IAsset assetIn;
45
- IAsset assetOut;
46
- uint256 amount;
47
- bytes userData;
48
- }
49
-
50
- struct FundManagement {
51
- address sender;
52
- bool fromInternalBalance;
53
- address payable recipient;
54
- bool toInternalBalance;
55
- }
56
-
57
- function swap(
58
- SingleSwap memory singleSwap,
59
- FundManagement memory funds,
60
- uint256 limit,
61
- uint256 deadline
62
- ) external payable returns (uint256);
63
-
64
- function getPoolTokens(bytes32 poolId)
65
- external
66
- view
67
- returns (
68
- IERC20[] memory tokens,
69
- uint256[] memory balances,
70
- uint256 lastChangeBlock
71
- );
72
-
73
- function WETH() external view returns (IERC20);
74
-
75
- function getPool(bytes32 poolId) external view returns (address, uint8);
76
-
77
- function getProtocolFeesCollector() external view returns (address);
78
- }
@@ -1,30 +0,0 @@
1
- // SPDX-License-Identifier: GPL-3.0-or-later
2
-
3
- pragma solidity 0.8.17;
4
-
5
- interface IApeStaking {
6
- function apeCoin() external view returns (address);
7
-
8
- function depositSelfApeCoin(uint256 _amount) external;
9
-
10
- function withdrawApeCoin(uint256 _amount, address _recipient) external;
11
-
12
- function claimSelfApeCoin() external;
13
-
14
- /**
15
- * @notice when poolId is set to 0, tokenId's value does not matter
16
- */
17
- function pendingRewards(
18
- uint256 _poolId,
19
- address _address,
20
- uint256 _tokenId
21
- ) external view returns (uint256);
22
-
23
- function addressPosition(address addr)
24
- external
25
- view
26
- returns (uint256 stakedAmount, int256 rewardsDebt);
27
-
28
- // for SDK
29
- function pools(uint256 id) external view returns (uint48, uint16, uint96 totalStaked, uint96);
30
- }
@@ -1,103 +0,0 @@
1
- pragma solidity >=0.5.0;
2
- pragma experimental ABIEncoderV2;
3
-
4
- /// @title Multicall2 - Aggregate results from multiple read-only function calls
5
- /// @author Michael Elliot <mike@makerdao.com>
6
- /// @author Joshua Levine <joshua@makerdao.com>
7
- /// @author Nick Johnson <arachnid@notdot.net>
8
-
9
- contract Multicall2 {
10
- struct Call {
11
- address target;
12
- bytes callData;
13
- }
14
- struct Result {
15
- bool success;
16
- bytes returnData;
17
- }
18
-
19
- function aggregate(Call[] memory calls)
20
- public
21
- returns (uint256 blockNumber, bytes[] memory returnData)
22
- {
23
- blockNumber = block.number;
24
- returnData = new bytes[](calls.length);
25
- for (uint256 i = 0; i < calls.length; i++) {
26
- (bool success, bytes memory ret) = calls[i].target.call(calls[i].callData);
27
- require(success, "Multicall aggregate: call failed");
28
- returnData[i] = ret;
29
- }
30
- }
31
-
32
- function blockAndAggregate(Call[] memory calls)
33
- public
34
- returns (
35
- uint256 blockNumber,
36
- bytes32 blockHash,
37
- Result[] memory returnData
38
- )
39
- {
40
- (blockNumber, blockHash, returnData) = tryBlockAndAggregate(true, calls);
41
- }
42
-
43
- function getBlockHash(uint256 blockNumber) public view returns (bytes32 blockHash) {
44
- blockHash = blockhash(blockNumber);
45
- }
46
-
47
- function getBlockNumber() public view returns (uint256 blockNumber) {
48
- blockNumber = block.number;
49
- }
50
-
51
- function getCurrentBlockCoinbase() public view returns (address coinbase) {
52
- coinbase = block.coinbase;
53
- }
54
-
55
- function getCurrentBlockDifficulty() public view returns (uint256 difficulty) {
56
- difficulty = block.difficulty;
57
- }
58
-
59
- function getCurrentBlockGasLimit() public view returns (uint256 gaslimit) {
60
- gaslimit = block.gaslimit;
61
- }
62
-
63
- function getCurrentBlockTimestamp() public view returns (uint256 timestamp) {
64
- timestamp = block.timestamp;
65
- }
66
-
67
- function getEthBalance(address addr) public view returns (uint256 balance) {
68
- balance = addr.balance;
69
- }
70
-
71
- function getLastBlockHash() public view returns (bytes32 blockHash) {
72
- blockHash = blockhash(block.number - 1);
73
- }
74
-
75
- function tryAggregate(bool requireSuccess, Call[] memory calls)
76
- public
77
- returns (Result[] memory returnData)
78
- {
79
- returnData = new Result[](calls.length);
80
- for (uint256 i = 0; i < calls.length; i++) {
81
- (bool success, bytes memory ret) = calls[i].target.call(calls[i].callData);
82
-
83
- if (requireSuccess) {
84
- require(success, "Multicall2 aggregate: call failed");
85
- }
86
-
87
- returnData[i] = Result(success, ret);
88
- }
89
- }
90
-
91
- function tryBlockAndAggregate(bool requireSuccess, Call[] memory calls)
92
- public
93
- returns (
94
- uint256 blockNumber,
95
- bytes32 blockHash,
96
- Result[] memory returnData
97
- )
98
- {
99
- blockNumber = block.number;
100
- blockHash = blockhash(block.number);
101
- returnData = tryAggregate(requireSuccess, calls);
102
- }
103
- }
@@ -1,26 +0,0 @@
1
- // SPDX-License-Identifier: MIT
2
- pragma solidity 0.8.17;
3
-
4
- /// @title PendleMulticall - A more gas-efficient version of Multicall3 (~700 gas saved for each call)
5
- /// @author UncleGrandpa925 <longvh@pendle.finance>
6
- contract PendleMulticall {
7
- error MulticallFailed(uint256 index);
8
-
9
- struct Call {
10
- address target;
11
- bytes callData;
12
- }
13
-
14
- function aggregate(Call[] calldata calls) external payable {
15
- uint256 length = calls.length;
16
- Call calldata call;
17
- for (uint256 i = 0; i < length; ) {
18
- call = calls[i];
19
- (bool success, ) = call.target.call(call.callData);
20
- if (!success) revert MulticallFailed(i);
21
- unchecked {
22
- ++i;
23
- }
24
- }
25
- }
26
- }
@@ -1,147 +0,0 @@
1
- // SPDX-License-Identifier: MIT
2
- pragma solidity 0.8.17;
3
-
4
- import "./interfaces/IExecutorHelperEthereum1.sol";
5
-
6
- library ScaleDataHelperEthereum1 {
7
- function newUniSwap(
8
- bytes memory data,
9
- uint256 oldAmount,
10
- uint256 newAmount
11
- ) internal pure returns (bytes memory) {
12
- IExecutorHelperEthereum1.UniSwap memory uniSwap = abi.decode(
13
- data,
14
- (IExecutorHelperEthereum1.UniSwap)
15
- );
16
- uniSwap.collectAmount = (uniSwap.collectAmount * newAmount) / oldAmount;
17
- return abi.encode(uniSwap);
18
- }
19
-
20
- function newStableSwap(
21
- bytes memory data,
22
- uint256 oldAmount,
23
- uint256 newAmount
24
- ) internal pure returns (bytes memory) {
25
- IExecutorHelperEthereum1.StableSwap memory stableSwap = abi.decode(
26
- data,
27
- (IExecutorHelperEthereum1.StableSwap)
28
- );
29
- stableSwap.dx = (stableSwap.dx * newAmount) / oldAmount;
30
- return abi.encode(stableSwap);
31
- }
32
-
33
- function newCurveSwap(
34
- bytes memory data,
35
- uint256 oldAmount,
36
- uint256 newAmount
37
- ) internal pure returns (bytes memory) {
38
- IExecutorHelperEthereum1.CurveSwap memory curveSwap = abi.decode(
39
- data,
40
- (IExecutorHelperEthereum1.CurveSwap)
41
- );
42
- curveSwap.dx = (curveSwap.dx * newAmount) / oldAmount;
43
- return abi.encode(curveSwap);
44
- }
45
-
46
- function newKyberDMM(
47
- bytes memory data,
48
- uint256 oldAmount,
49
- uint256 newAmount
50
- ) internal pure returns (bytes memory) {
51
- IExecutorHelperEthereum1.UniSwap memory kyberDMMSwap = abi.decode(
52
- data,
53
- (IExecutorHelperEthereum1.UniSwap)
54
- );
55
- kyberDMMSwap.collectAmount = (kyberDMMSwap.collectAmount * newAmount) / oldAmount;
56
- return abi.encode(kyberDMMSwap);
57
- }
58
-
59
- function newUniV3ProMM(
60
- bytes memory data,
61
- uint256 oldAmount,
62
- uint256 newAmount
63
- ) internal pure returns (bytes memory) {
64
- IExecutorHelperEthereum1.UniSwapV3ProMM memory uniSwapV3ProMM = abi.decode(
65
- data,
66
- (IExecutorHelperEthereum1.UniSwapV3ProMM)
67
- );
68
- uniSwapV3ProMM.swapAmount = (uniSwapV3ProMM.swapAmount * newAmount) / oldAmount;
69
-
70
- return abi.encode(uniSwapV3ProMM);
71
- }
72
-
73
- function newBalancerV2(
74
- bytes memory data,
75
- uint256 oldAmount,
76
- uint256 newAmount
77
- ) internal pure returns (bytes memory) {
78
- IExecutorHelperEthereum1.BalancerV2 memory balancerV2 = abi.decode(
79
- data,
80
- (IExecutorHelperEthereum1.BalancerV2)
81
- );
82
- balancerV2.amount = (balancerV2.amount * newAmount) / oldAmount;
83
- return abi.encode(balancerV2);
84
- }
85
-
86
- function newDODO(
87
- bytes memory data,
88
- uint256 oldAmount,
89
- uint256 newAmount
90
- ) internal pure returns (bytes memory) {
91
- IExecutorHelperEthereum1.DODO memory dodo = abi.decode(
92
- data,
93
- (IExecutorHelperEthereum1.DODO)
94
- );
95
- dodo.amount = (dodo.amount * newAmount) / oldAmount;
96
- return abi.encode(dodo);
97
- }
98
-
99
- function newSynthetix(
100
- bytes memory data,
101
- uint256 oldAmount,
102
- uint256 newAmount
103
- ) internal pure returns (bytes memory) {
104
- IExecutorHelperEthereum1.Synthetix memory synthetix = abi.decode(
105
- data,
106
- (IExecutorHelperEthereum1.Synthetix)
107
- );
108
- synthetix.sourceAmount = (synthetix.sourceAmount * newAmount) / oldAmount;
109
- return abi.encode(synthetix);
110
- }
111
-
112
- function newWrappedstETHSwap(
113
- bytes memory data,
114
- uint256 oldAmount,
115
- uint256 newAmount
116
- ) internal pure returns (bytes memory) {
117
- IExecutorHelperEthereum1.WSTETH memory wstEthData = abi.decode(
118
- data,
119
- (IExecutorHelperEthereum1.WSTETH)
120
- );
121
- wstEthData.amount = (wstEthData.amount * newAmount) / oldAmount;
122
- return abi.encode(wstEthData);
123
- }
124
-
125
- function newPSM(
126
- bytes memory data,
127
- uint256 oldAmount,
128
- uint256 newAmount
129
- ) internal pure returns (bytes memory) {
130
- IExecutorHelperEthereum1.PSM memory psm = abi.decode(data, (IExecutorHelperEthereum1.PSM));
131
- psm.amountIn = (psm.amountIn * newAmount) / oldAmount;
132
- return abi.encode(psm);
133
- }
134
-
135
- function newFrax(
136
- bytes memory data,
137
- uint256 oldAmount,
138
- uint256 newAmount
139
- ) internal pure returns (bytes memory) {
140
- IExecutorHelperEthereum1.UniSwap memory frax = abi.decode(
141
- data,
142
- (IExecutorHelperEthereum1.UniSwap)
143
- );
144
- frax.collectAmount = (frax.collectAmount * newAmount) / oldAmount;
145
- return abi.encode(frax);
146
- }
147
- }
@@ -1,17 +0,0 @@
1
- // SPDX-License-Identifier: MIT
2
-
3
- pragma solidity >=0.6.12;
4
-
5
- interface IAggregationExecutor {
6
- function callBytes(bytes calldata data) external payable; // 0xd9c45357
7
-
8
- // callbytes per swap sequence
9
- function swapSingleSequence(bytes calldata data) external;
10
-
11
- function finalTransactionProcessing(
12
- address tokenIn,
13
- address tokenOut,
14
- address to,
15
- bytes calldata destTokenFeeData
16
- ) external;
17
- }
@@ -1,191 +0,0 @@
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
-
186
- function executeFraxSwap(
187
- uint256 index,
188
- bytes memory data,
189
- uint256 previousAmountOut
190
- ) external payable returns (uint256);
191
- }
@@ -1,30 +0,0 @@
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
- }
@@ -1,33 +0,0 @@
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
- }