Integration with DEX
Integration with decentralized stock markets
As described above in the Issue Model section, when creating a post or comment, a certain number of Page.Token tokens is generated for the creator and the owner of such a post, while the number of generated tokens is based on the amount of gas spent on creating the post.
To determine the number of tokens that corresponds to the amount of gas, Page.Token smart contracts (via calls to Page.Bank) turn to a decentralized stock market on this blockchain (such as Uniswap) and determine the current value of Page.Token on such a stock market in relation to the base coin of the blockchain (for example, ETH for Ethereum) and then convert the amount of spent gas into the amount of Page.Token that should be generated.
The Crypto.Page team will open trading of Page.Token <-> Blockchain base coin pair on each blockchain where it will be deployed, moreover, the presence of such a pair is necessary for the initial deployment of the Crypto.Page solution on any blockchain.
The operational manager of Page.DAO (a Supermoderator at the initial stage of project development) can suspend the determination of the token value from a decentralized exchange for a period of no more than 30 days and set a fixed value of the Page.Token token in relation to the cost of gas. Page.DAO can vote and use another stock market or the method of determining the ratio of the value of Page.Token to the gas cost.
To protect against Flash Loan attacks, the final value of the token is defined as its average value within the last 15 minutes, and not its current value at the moment of the transaction. The time setting of 15 minutes is configurable and is configured by Page.DAO.