diff --git a/chains/RealLib.sol b/chains/RealLib.sol index 53974591..7fa54271 100644 --- a/chains/RealLib.sol +++ b/chains/RealLib.sol @@ -73,9 +73,29 @@ library RealLib { // 21.10.2024: TVL $78.34K, APR 0% address public constant POOL_PEARL_SACRA_reETH_10000 = 0x2EC05Ab55867719f433d8ab0a446C48003B3BE8F; - // ALMs + // *** ALMs *** + // Trident + // We extract ALM, Gauge and BoxManager addresses from this factory address public constant TRIDENT_LIQUID_BOX_FACTORY = 0xEfeFFa36b9FA787b500b2d18a3829271526023b1; + // Ichi + address public constant ICHI_VAULT_DEPOSIT_GUARD = 0x89FFdaa18b296d9F0CF02fBD88e5c633FEFA5f34; + // IchiVaultFactory 0x860F3881aCBbF05D48a324C5b8ca9004D31A146C allVautls(index) 0-9 + address public constant IV_PEARL_USTB_PEARL_10000 = 0x2ea611fF2Db242Efb65A548e2B2DF6B5d2a02191; + address public constant IV_PEARL_WREETH_RWA_3000 = 0xC77531EAEe4b0eCa6B4626197277E12CE29bA672; + address public constant IV_PEARL_UKRE_arcUSD_500 = 0x863ca0dED740e8c2111b9e616Fe672278Ba707c6; + address public constant IV_PEARL_CVR_PEARL_500 = 0x7F23e2822470EFA9a642f12916AD89549a28A7C7; + address public constant IV_PEARL_USTB_MORE_100 = 0x7DA0e0187Ee2fB1B979398787179FF202769a0B6; + address public constant IV_PEARL_USDC_PEARL_10000 = 0x04BBef2aa336ff7736eb0994D22170261937A7bF; + address public constant IV_PEARL_arcUSD_UKRE_500 = 0xE68Ab89E2E734A3e2A954823BE3bf6361148c0a0; + address public constant IV_PEARL_PEARL_CVR_500 = 0x378A179B3E8c558d8c69dfe2B0b220F0F9BfD01d; + address public constant IV_PEARL_USDC_MORE_100 = 0x6c357a3E7f92cB048Dc9FB6AB73273efab09feE0; + address public constant IV_PEARL_RWA_WREETH_3000 = 0x797bb030438a0BC2F042dCcdf2598eD62F7348Cb; + // ************ + + // Pearl + address public constant MULTI_FEE_DISTRIBUTION_FACTORY = 0xb42D5956cDe4386B65C087CfCD16910aB6114F15; + // Oracles address public constant ORACLE_DIA_WREETH_USDC = 0xA2c62937987815A9Bb9d3b2F4580e629F9FA3Bc8; diff --git a/src/integrations/pearl/IGaugeV2CL.sol b/src/integrations/pearl/IGaugeV2CL.sol index 3f1558af..4dcd302b 100644 --- a/src/integrations/pearl/IGaugeV2CL.sol +++ b/src/integrations/pearl/IGaugeV2CL.sol @@ -20,7 +20,7 @@ interface IGaugeV2CL { ///@notice User harvest function function collectReward() external; - function periodFinish() external view returns(uint); + function periodFinish() external view returns (uint); /** * @notice Notifies the contract of a reward amount. diff --git a/src/integrations/pearl/ILiquidBox.sol b/src/integrations/pearl/ILiquidBox.sol index dcbe5df1..296deb8c 100644 --- a/src/integrations/pearl/ILiquidBox.sol +++ b/src/integrations/pearl/ILiquidBox.sol @@ -45,13 +45,10 @@ interface ILiquidBox { * other words, how much of each token the vault would hold if it withdrew * all its liquidity from Uniswap. */ - function getTotalAmounts() external view returns ( - uint total0, - uint total1, - uint pool0, - uint pool1, - uint128 liquidity - ); + function getTotalAmounts() + external + view + returns (uint total0, uint total1, uint pool0, uint pool1, uint128 liquidity); /** * @dev Returns the amount of tokens in existence. @@ -64,8 +61,5 @@ interface ILiquidBox { function gauge() external view returns (address); - function getRequiredAmountsForInput( - uint amount0, - uint amount1 - ) external view returns (uint, uint); + function getRequiredAmountsForInput(uint amount0, uint amount1) external view returns (uint, uint); } diff --git a/src/integrations/pearl/IMultiFeeDistribution.sol b/src/integrations/pearl/IMultiFeeDistribution.sol new file mode 100644 index 00000000..1f072c7c --- /dev/null +++ b/src/integrations/pearl/IMultiFeeDistribution.sol @@ -0,0 +1,42 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.23; + +interface IMultiFeeDistribution { + /** + * @notice Total balance of an account, including unlocked, locked and earned tokens. + * @param user address. + */ + function totalBalance(address user) external view returns (uint); + + /** + * @notice Address and claimable amount of all reward tokens for the given account. + * @param account for rewards + * @return rewardsData array of rewards + * @dev this estimation doesn't include rewards that are yet to be collected from the ICHIVault via collectRewards + */ + function claimableRewards(address account) external view returns (address[] memory, uint[] memory); + + /** + * @notice Stake tokens to receive rewards. + * @dev Locked tokens cannot be withdrawn for defaultLockDuration and are eligible to receive rewards. + * @param amount to stake. + * @param onBehalfOf address for staking. + */ + function stake(uint amount, address onBehalfOf) external; + + function unstake(uint amount) external; + + /** + * @notice Claim all pending staking rewards. + * @param _rewardTokens array of reward tokens + */ + function getReward( + address _onBehalfOf, + address[] memory _rewardTokens + ) external returns (uint[] memory claimableAmounts); + + /** + * @notice Claim all pending staking rewards. + */ + function getAllRewards() external returns (uint[] memory claimableAmounts); +} diff --git a/src/integrations/pearl/IMultiFeeDistributionFactory.sol b/src/integrations/pearl/IMultiFeeDistributionFactory.sol new file mode 100644 index 00000000..f9988f42 --- /dev/null +++ b/src/integrations/pearl/IMultiFeeDistributionFactory.sol @@ -0,0 +1,6 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.23; + +interface IMultiFeeDistributionFactory { + function vaultToStaker(address ichiVault) external view returns (address staker); +} diff --git a/src/strategies/libs/StrategyDeveloperLib.sol b/src/strategies/libs/StrategyDeveloperLib.sol index bf1767bc..1867463f 100644 --- a/src/strategies/libs/StrategyDeveloperLib.sol +++ b/src/strategies/libs/StrategyDeveloperLib.sol @@ -44,6 +44,9 @@ library StrategyDeveloperLib { if (CommonLib.eq(strategyId, StrategyIdLib.TRIDENT_PEARL_FARM)) { return 0x88888887C3ebD4a33E34a15Db4254C74C75E5D4A; } + if (CommonLib.eq(strategyId, StrategyIdLib.ICHI_PEARL_FARM)) { + return 0x88888887C3ebD4a33E34a15Db4254C74C75E5D4A; + } return address(0); } } diff --git a/src/strategies/libs/StrategyIdLib.sol b/src/strategies/libs/StrategyIdLib.sol index 4978a8b3..b326d98c 100644 --- a/src/strategies/libs/StrategyIdLib.sol +++ b/src/strategies/libs/StrategyIdLib.sol @@ -16,4 +16,5 @@ library StrategyIdLib { string internal constant CURVE_CONVEX_FARM = "Curve Convex Farm"; string internal constant YEARN = "Yearn"; string internal constant TRIDENT_PEARL_FARM = "Trident Pearl Farm"; + string internal constant ICHI_PEARL_FARM = "Ichi Pearl Farm"; }