CompV3RatioCheck

Description

Action ID: 0x2ce67bb9

Checks if CompV3 positions ratio is in target range

SDK Action

const checkerAction = new dfs.actions.checkers.CompV3RatioCheck(
        checkRepayState,
        targetRatio,
        market
    );

Contract

This is a DFS CHECK_ACTION.

5% offset acceptable

Input:

    /// @param ratioState Enum if we're doing a Boost or Repay strategy
    /// @param targetRatio Ratio that the strategy is supposed to hit (within allowed offset)
    /// @param market Address of the Comp V3 Market
    struct Params {
        RatioState ratioState;
        uint256 targetRatio;
        address market;
    }

Return value:

return bytes32(currRatio);

Events:

emit ActionEvent("CompV3RatioCheck", abi.encode(currRatio));

Last updated