AMM ERC
The AMMs are used to swap a pegged token to the tenXXX version of the token and the other way around.
Functions
toggleBuy() external onlyOwner returns (bool)
canBuy() external view returns (bool)
getTenToken() external view returns (address)
buy(uint256 tokenAmount) external nonReentrant returns (bool)
sell(uint256 amount) external nonReentrant returns (bool)
getInPrice(uint256 amount) external view returns (uint256)
getOutPrice(uint256 amount) external view returns (uint256)
toggleBuy() external onlyOwner returns (bool)
Toggles the possibility to buy over the amm.
canBuy() external view returns (bool)
Getter for the possibility to buy over the amm.
getTenToken() external view returns (address)
Returns the ten-Token address.
buy(uint256 tokenAmount) external nonReentrant returns (bool)
Mints new ten-Tokens for the sent ERC20 tokens.
sell(uint256 amount) external nonReentrant returns (bool)
Burns ten-Tokens and sends the ERC20 token amount.
getInPrice(uint256 amount) external view returns (uint256)
Returns the actual price for swapping pegged token to ten-Token which can change.
getOutPrice(uint256 amount) external view returns (uint256)
Returns the actual price for swapping ten-Token to pegged token which can change.
Last updated