Interactions

setBounds

Updates the bounds for a specific parameter. Only callable by the Keeper (Governor role).


function setBounds(ParamKey key, Bounds calldata newBounds) external;

Parameters

Name
Type
Description

key

ParamKey

The parameter key to update (A, SwapFee, MintFee, etc.)

newBounds

Bounds

The new bounds structure containing max, min, and percentage limits

aParams

Returns the bounds for the amplification coefficient - most commonly queried parameter.


function aParams() external view returns (Bounds memory);

swapFeeParams / mintFeeParams / redeemFeeParams

Returns bounds for fee parameters - commonly needed for fee calculations.


function swapFeeParams() external view returns (Bounds memory);
function mintFeeParams() external view returns (Bounds memory);
function redeemFeeParams() external view returns (Bounds memory);

Data Structures

Bounds Structure

struct Bounds {
    uint256 max;              // Maximum hard cap for the parameter value
    uint256 min;              // Minimum hard cap for the parameter value
    uint64 maxDecreasePct;    // Maximum decrease per transaction (1e10 = 100%)
    uint64 maxIncreasePct;    // Maximum increase per transaction (1e10 = 100%)
}

ParamKey Enum

enum ParamKey {
    A,                        // Amplification coefficient
    SwapFee,                  // Swap fee parameter
    MintFee,                  // Mint fee parameter
    RedeemFee,                // Redeem fee parameter
    OffPeg,                   // Off-peg multiplier
    ExchangeRateFee,          // Exchange rate fee factor
    DecayPeriod,              // Fee multiplier decay period
    RateChangeSkipPeriod,     // Rate change skip period
    FeeErrorMargin,           // Fee error margin
    YieldErrorMargin,         // Yield error margin
    MinRampTime,              // Minimum ramp time
    BufferPercent             // Buffer percentage
}

Last updated