IKeeper
Interface for the Keeper contract that enforces parameter bounds for curators
Functions
rampA
Allows curators to gradually ramp the A coefficient within allowed bounds
function rampA(uint256 newA, uint256 endTime) external;
Parameters
Name | Type | Description |
---|---|---|
newA | uint256 | The target A value |
endTime | uint256 | Timestamp when ramping should complete |
setMinRampTime
Set the minimum ramp time
function setMinRampTime(uint256 newMinRampTime) external;
Parameters
Name | Type | Description |
---|---|---|
newMinRampTime | uint256 | is the new minimum ramp time |
setSwapFee
Set the swap fee within allowed bounds
function setSwapFee(uint256 newFee) external;
Parameters
Name | Type | Description |
---|---|---|
newFee | uint256 | The new swap fee value |
setMintFee
Set the mint fee within allowed bounds
function setMintFee(uint256 newFee) external;
Parameters
Name | Type | Description |
---|---|---|
newFee | uint256 | The new mint fee value |
setRedeemFee
Set the redeem fee within allowed bounds
function setRedeemFee(uint256 newFee) external;
Parameters
Name | Type | Description |
---|---|---|
newFee | uint256 | The new redeem fee value |
setOffPegFeeMultiplier
Set the off-peg fee multiplier within allowed bounds
function setOffPegFeeMultiplier(uint256 newMultiplier) external;
Parameters
Name | Type | Description |
---|---|---|
newMultiplier | uint256 | The new off-peg fee multiplier value |
setExchangeRateFeeFactor
Set the exchange rate fee within allowed bounds
function setExchangeRateFeeFactor(uint256 newFeeFactor) external;
Parameters
Name | Type | Description |
---|---|---|
newFeeFactor | uint256 | The new exchange rate fee value |
setBufferPercent
Set the buffer within allowed bounds
function setBufferPercent(uint256 newBuffer) external;
Parameters
Name | Type | Description |
---|---|---|
newBuffer | uint256 | The new buffer value |
setTokenSymbol
Set the token symbol
function setTokenSymbol(string calldata newSymbol) external;
Parameters
Name | Type | Description |
---|---|---|
newSymbol | string | The new token symbol |
setDecayPeriod
Set the decay period
function setDecayPeriod(uint256 newDecayPeriod) external;
Parameters
Name | Type | Description |
---|---|---|
newDecayPeriod | uint256 | The new decay period in seconds |
setRateChangeSkipPeriod
Set the rate change skip period
function setRateChangeSkipPeriod(uint256 newSkipPeriod) external;
Parameters
Name | Type | Description |
---|---|---|
newSkipPeriod | uint256 | The new skip period in seconds |
updateFeeErrorMargin
Set the fee error margin within allowed bounds
function updateFeeErrorMargin(uint256 newMargin) external;
Parameters
Name | Type | Description |
---|---|---|
newMargin | uint256 | The new fee error margin value |
updateYieldErrorMargin
Set the yield error margin within allowed bounds
function updateYieldErrorMargin(uint256 newMargin) external;
Parameters
Name | Type | Description |
---|---|---|
newMargin | uint256 | The new yield error margin value |
distributeLoss
Distribute any losses incurred
function distributeLoss() external;
pause
Pause the SPA
function pause() external;
unpause
Unpause the SPA
function unpause() external;
cancelRamp
Allows guardians to cancel an ongoing A ramp in emergencies
function cancelRamp() external;
getRegistry
Get the parameter registry used for bounds checking
function getRegistry() external view returns (IParameterRegistry);
Returns
Name | Type | Description |
---|---|---|
<none> | IParameterRegistry | The parameter registry address |
getRampAController
Get the RampAController being managed
function getRampAController() external view returns (IRampAController);
Returns
Name | Type | Description |
---|---|---|
<none> | IRampAController | The RampAController address |
getSpa
Get the SelfPeggingAsset being managed
function getSpa() external view returns (SelfPeggingAsset);
Returns
Name | Type | Description |
---|---|---|
<none> | SelfPeggingAsset | The SelfPeggingAsset address |
getSpaToken
Get the SPA token being managed
function getSpaToken() external view returns (SPAToken);
Returns
Name | Type | Description |
---|---|---|
<none> | SPAToken | The SPA token address |
Events
RampAInitiated
event RampAInitiated(uint256 oldA, uint256 newA, uint256 endTime);
MinRampTimeUpdated
event MinRampTimeUpdated(uint256 oldTime, uint256 newTime);
SwapFeeUpdated
event SwapFeeUpdated(uint256 oldFee, uint256 newFee);
MintFeeUpdated
event MintFeeUpdated(uint256 oldFee, uint256 newFee);
RedeemFeeUpdated
event RedeemFeeUpdated(uint256 oldFee, uint256 newFee);
OffPegFeeMultiplierUpdated
event OffPegFeeMultiplierUpdated(uint256 oldMultiplier, uint256 newMultiplier);
ExchangeRateFeeFactorUpdated
event ExchangeRateFeeFactorUpdated(uint256 oldFactor, uint256 newFactor);
BufferPercentUpdated
event BufferPercentUpdated(uint256 oldBuffer, uint256 newBuffer);
TokenSymbolUpdated
event TokenSymbolUpdated(string oldSymbol, string newSymbol);
DecayPeriodUpdated
event DecayPeriodUpdated(uint256 oldPeriod, uint256 newPeriod);
RateChangeSkipPeriodUpdated
event RateChangeSkipPeriodUpdated(uint256 oldPeriod, uint256 newPeriod);
FeeErrorMarginUpdated
event FeeErrorMarginUpdated(uint256 oldMargin, uint256 newMargin);
YieldErrorMarginUpdated
event YieldErrorMarginUpdated(uint256 oldMargin, uint256 newMargin);
LossDistributed
event LossDistributed();
ProtocolPaused
event ProtocolPaused();
ProtocolUnpaused
event ProtocolUnpaused();
RampCancelled
event RampCancelled();
TreasuryChanged
event TreasuryChanged(address indexed oldTreasury, address indexed newTreasury);
AdminFeeWithdrawn
event AdminFeeWithdrawn(address indexed to, uint256 amount, uint256 bufferLeft);