1
0
mirror of https://github.com/oceanprotocol/docs.git synced 2024-06-13 08:03:15 +02:00

Issue-#1017: Asset pricing in pool

This commit is contained in:
Akshay 2022-06-24 11:45:12 +02:00
parent 869dfbe685
commit d1de2cee31

View File

@ -44,25 +44,25 @@ Ocean Protocol also allows publishers to set the pricing using ocean.js and ocea
### Asset price
#### Action: Add liquidity from pool
#### Action: Add liquidity
With one-sided staking, when liquidity is added to the pool, the ocean tokens are added to the liquidity pool. To protect funds from impermanent loss due to changes in the ratio of tokens in the liquidity pool, Ocean protocol's bot mints new datatokens and adds them to the pool. Thus, when liquidity is added to the pool, the ratio of tokens remains constant, and there is no price impact on the datatoken.
#### Action: Remove liquidity from pool
#### Action: Remove liquidity
When the liquidity is removed from the pool, the Ocean tokens are returned to the respective address. The address only receives Ocean tokens due to one-sided staking. Ocean protocol's bot burns the datatokens from the pool to protect funds from impermanent loss due to changes in the ratio of tokens in the liquidity pool. Thus, in this case, there is also no price impact on the datatoken.
When the liquidity is removed from the pool, the Ocean tokens are returned to the respective address. Ocean protocol's bot burns the datatokens from the liquidity pool to protect funds from impermanent loss due to changes in the ratio of tokens in the liquidity pool. Thus, even in this case, there is no price impact on the datatoken.
#### Action: Buy datatoken
When a datatoken is bought by paying Ocean tokens to the pool, the ratio of Ocean token and datatoken changes, there would be more Ocean tokens and fewer datatokens in the pool than previously. As there would be fewer datatokens, the pool will increase the amount of Ocean tokens required to buy a datatoken in the following transactions to maintain the constant ratio between tokens. Thus, the price of the datatoken increases whenever datatokens are bought.
When a datatoken is bought by paying Ocean tokens to the pool, the ratio of Ocean token and datatoken changes, there are more Ocean tokens and fewer datatokens in the liquidity pool. Therefore, as the ratio of datatokens/Ocean tokens changes, the liquidity pool increases the amount of Ocean tokens required to buy a datatoken in the following transactions(to maintain a constant ratio). Thus, the price of the datatoken increases whenever a datatoken is bought.
#### Action: Buy dataset
Buying a dataset requires that the datatokens are swapped from the pool by paying Ocean tokens. Thus, if users buy datatokens, the price of datatokens will increase. However, if users already have the datatokens, they can simply use them to buy the asset or the service without requiring interaction with the pool. In such a case, the price of the datatoken doesn't change.
Buying a dataset involves swapping a datatoken from the pool by paying Ocean tokens. Thus, if users buy datatokens, the price of datatokens will increase. However, if users already have the datatokens, they can use them to buy the asset or the service without requiring interaction with the pool. In such a case, the price of the datatoken doesn't change.
#### Action: Sell datatoken
When the a datatoken is sold Ocean tokens are removed from the pool in exchange of datatoken, the ratio of Ocean token and datatoken changes, and there would be fewer Ocean tokens and more datatokens in the pool than previously. As there would be more datatokens, the pool will decrease the amount of Ocean tokens required to buy a datatoken in the following transactions to maintain the constant ratio between tokens. Thus, the price of the datatoken decreases whenever datatokens are sold.
When a datatoken is sold, Ocean tokens are removed from the liquidity pool in exchange for datatoken. Thus, the ratio of Ocean tokens and datatokens changes: there would be fewer Ocean tokens and more datatokens in the liquidity pool. As there would be more datatokens, the pool decreases the amount of Ocean tokens required to buy a datatoken in the following transactions(to maintain the constant ratio). Thus, the price of the datatoken decreases whenever a datatoken is sold.
## Free pricing