project screenshot 1
project screenshot 2
project screenshot 3

1UP

Unlock liquidity on your staked 1inch tokens while benefitting of full staking potential !

1UP

Created At

ETHGlobal Lisbon

Winner of

trophy

🥇 1inch — Best Yield Optimization Protocol 🦄

Project Description

This project has for objective to make a yield optimizer for staked 1inch (related to Fusion mode). This optimizer will enable the following: -Stake your 1inch for max duration and UP power. -Get liquidity on your staked tokens. -Keeping max duration, thus max UP power constant as long as there is demand while always being able to withdraw (depending of underlying pool conditions). -Receive tokens that represent your share of staked tokens, and get extra incentives by earning trading fees in a stable pool.

How it's Made

This project was built with Solidity and uses the ERC4626 Vault. ERC4626 as a tokenized vault will help us manage an asset and distribute profits to the vault "shareholders". As in our case, no assets are held by the Vault, some modifications had to be done to the totalAssets() function for the accounting (amongst others).

A Balancer stable pool is linked to the Vault and composed of 1inch/1UP tokens (1UP = ERC20 issued by the vault).

The Vault works as the following:

--Deposits-- -A user deposits 1inch tokens. -In the same transaction, 1inch is staked and UP gets delegated to a resolver. -User gets 1UP tokens, which is their share of the vault minted upon deposit.

note: As long as people are depositing, the duration of the staking will extend, keeping UP to the max. This will happen every 30 days, if new deposits are still made, period extends with 30 days.

--Claim-- -Anyone can claim rewards when those are available by calling claimRewardsFromDelegate(). -Claiming will automatically transfer the rewards (1inch) to the Balancer Pool, putting liquidity at disposition of stakers willing to exit their position. This would happen by swapping 1UP tokens to 1inch tokens inside the pool. -The Vaults accumulates LP tokens of the Balancer Pool that it will account for in his totalAssets() and will redistribute when Vault ends.

--Withdraw-- -Anyone will be able to call the withdraw function once the total duration of staked 1inch tokens from the vault has passed. This will end the vault and sends all 1inch previously staked back to the vault. -This function will also remove the liquidity from the Balancer Pool, those 1inch tokens will account as extra rewards and be claimable from the pool.

Also note that 1UP holders will have the possibility to provide liquidity to the Balancer Pool and accrue trading fees.

In the future a specific Balancer Vault could be setup as well with additional incentives. A rebalance function in order to delegate to the most promising resolvers could also be implemented inside the vault.

background image mobile

Join the mailing list

Get the latest news and updates