Liquidity pool
Token owners can create a liquidity pool for their token on token creation or later on. The liquidity pool will be seeded with funds so that other users can start trading the token.
Liquidity pool creation
On pool creation, some decisions have to be made:
The token has to be paired with a stablecoin. This decision cannot be reversed
The liquidity unlocking period has to be set: Liquidity that is withdrawn from the pool will be locked for the defined period of time before being returned to users. The value can be changed at any time.
The trade fee is taken from each trade and given in part to the protocol and to liquidity providers. The higher the trade fee, the higher the reward for providers is, while at the same time it might become too unattractive for users to trade. The trade fee can be changed at any time, enabling token owners to find an equilibrium.
The initial pool funds determine the initial price of the token. The minimum pool size is 100
Providing liquidity
Any user can provide liquidity for a token's liquidity pool. There are two ways to provide:
Adding both currencies means when adding liquidity, the ratio of funds won't be changed when adding additional liquidity. If a pool contains 1000 TOKEN and 100 kUSD, new funds have to be added in a ratio 10:1.
Alternatively, users can add one of the pool's currencies. This means the ratio is not respected but in fact changed. If the ratio is 10:1, for example when the pool contains 1000 TOKEN and 100 kUSD, and 100 kUSD is added, then after adding liquidity the ratio becomes 5:1, i.e. the token's price is changed.
In both cases when liquidity is added, the protocol updates each liquidity provider's share of pool liquidity. When the pool was created by the admin with 1000 TOKEN and 100 kUSD, the token admin owns 100% of the liquidity. Then, if another user adds additional 1000 TOKEN and 100 kUSD, both liquidity providers will be listed with a 50% share.
Liquidity pool APY
Having provided liquidity comes with the benefit of being entitled to a part of the pool's generated trade fee income. The presented APR values of the website represent an estimate yield based on past income. They are calculated as follows:
Imagine a pool with 100 kUSD and 1000 TOKEN. The pool generates 10 kUSD of fee income. The APY is generally calculated as
Pool size: 100
Trade fee: 10
APY: (pool_size + fee_income) / pool_size = (100 + 10) / 100 = 10%
When there are multiple trades with various pool sizes (since liquidity can be added and withdrawing constantly), the pool's APY is a little more complicated to calculated. It is done by considering the pool sizes at the various moments fee income has been generated and then using the average of the pool sizes and the sum of the fee income:
Timestep 1:
Pool size: 100
Trade fee: 10
Timestep 2:
Pool size: 300
Trade fee: 10
Average size: 200
Total income: 20
APY: (average_pool_size + total_fee_income) / average_pool_size = (200 + 20) / 200 = 10%
The presented APY on the website is calculated the presented way based on past data and then extrapolated to yearly values. That means, when in one week there was a 10% income, that value is multiplied by 52. When a pool just has been created and a lot of trades have happened after creation, the yearly number might look inflated. The longer a pool exists, the more accurate the APY calculation becomes.
Please always remember the shown APY is an estimate calculated using past data and is no promised reward.
Withdrawing liquidity
Added liquidity can be withdrawn anytime. When withdrawing liquidity, it has to be removed with respect to the ratio. For example, when there are 1000 TOKEN and 100 kUSD in the pool and the user wants to withdraw 10 kUSD, 100 TOKEN have to be withdrawn as well.
The withdrawn liquidity will be sent to an address managed by the protocol, also an entry in an unlocking list will be created. At the end of each block, the protocol will check whether the withdrawn liquidity has been locked for the requirement amount of time. If yes, the protocol will send the locked funds to the users wallet.
Last updated