Sweep coin
Storage
Fetch minter (stabilizer) info
Gets the information about a minter. Returns 4 values: 1. boolean that represents if the minter is listed or not. 2. uint that represents the max mint amount. 3. uint that represents the minted amount 4. boolean that represents if the minter can mint or not.
Valid minters
Returns true if the minter is listed in the minter list and if they have a mix amount above of zero.
Target prices
Fetches the current and the next target price.
Fetches the target price, that is used to peg the SWEEP price safely. If periodTime is over, returns the nextTargetPrice, otherwise the currentTargetPrice.
Interest rate periods
Fetches the period's start time.
Fetches the delta amount of interest rate to increase/decrease. It has 6 decimals of precision. 1% = 10.000.
Total supply
Displays the total floating SWEEP (minted amount).
Admin Role
Approve a stabilizer deal and add to the minter list
The most important action for Sweep governance is to control the list of Stabilizers that it funds. Each Stabilizer represents an asset, and a maximum allocation to that asset. Stabilizers should match the mission, liquidity requirements, and risk tolerance of SWEEP.
minter: Address to be added into minter list
maxAmount: Max amount for mint
Change the max mint amount (borrow limit)
This is how to change the borrow limit or turn off borrowing
minter: Minter address
maxAmount: Max mint amount to be changed
Enable/disable a specific minter
On/Off minting for a specific address.
Change transfer permissioning
This is how to change transfer approver
approver: New contract address for transfer approving
Change interest rate
This is how to change interest rate of SWEEP
dailyRate: Interest rate for SWEEP that be changed every day. newPeriodStart: New period start time.
Change target price
Sets the current target price and the next target price.
Set step value
The value to increment/decrement the interest rate every time there is the interest rate is refreshed.
Pause SWEEP
This is how to pause transfer of SWEEP token
Unpause SWEEP
This is how to unpause transfer of SWEEP token
Change the treasury address
Sets the treasury address
Change the balancer
Sets the balancer address
Code upgrades
Sweep code will be upgradeable during the beta period.
The SWEEP coin, Sweep.sol, is an upgradeable proxy contract. It can accept code upgrades from the contract owner.
The contract owner is controlled by protocol governance in the following way [describe]
Stabilizer code cannot be upgraded. The code for a Stabilizer represents a specific agreement between the protocol and a borrower. To change this agreement, the protocol and the borrower should create and fund a new Stabilizer. The protocol will then set the borrow limits to zero on the old Stabilizer and request redemption.
Other contracts can be upgraded by deploying new versions, and attaching the new versions to the Sweep.sol contract. This will help the protocol change the logic of the Balancer and the transfer permissions.
Last updated