Skip to main content

IBorrowBlueToMidnightCallback

Git Source - Generated with forge doc

Inherits: ISellCallback

Title: IBorrowBlueToMidnightCallback

Interface of the callback that migrates borrower positions from Morpho Blue to Morpho Midnight.

Events

BorrowMigratedBlueToMidnight

event BorrowMigratedBlueToMidnight(
address indexed borrower,
bytes32 indexed sourceBlueMarketId,
bytes32 indexed targetMarketId,
uint256 debtRepaid,
uint256 debtUnits,
address collateralToken,
uint256 collateralMigrated,
uint256 fee
);

Structs

CallbackData

Data encoded in the offer's callbackData.

struct CallbackData {
MarketParams sourceMarketParams;
uint256 feeRate;
address feeRecipient;
uint256 tick;
}

Properties

NameTypeDescription
sourceMarketParamsMarketParamsThe Morpho Blue market to exit.
feeRateuint256Fee rate on the interest, in WAD.
feeRecipientaddressThe address receiving the fee; address(0) does not disable the fee, only feeRate == 0 does.
tickuint256Must be set exactly equal to offer.tick; the callback does not enforce this equality. A mismatch mis-scales the fill and may revert or settle on unintended terms.