♻️Borrowing mechanism

After pledging an NFT, the Zumer protocol will calculate the largest possible borrow value (liquidity) for the user. Unless interacting with our helper contract, all assets obtained will be in ERC-20. Currently Zumer supports WETH.

L=min(floor price,30MA)LTVnumber of NFTs pledgedborrow valueL = min(\text{floor price}, 30_{MA}) * LTV * \text{number of NFTs pledged} - \text{borrow value}

To obtain the current liquidity for an address:

// contract: Comptroller.sol
// @notice Calculate the liquidation amount given the ZNft token Id
// @param  borrower  The borrower that owns the tokenId ZNft
// @param  ZBondBorrowed  The ZBond that the borrower borrows from
// @param  tokenId  The ZNft collateral tokenId
// @param  ZNft  The ZNft used as collateral
function calculateLiquidationAmount(
    address borrower,
    address ZBondBorrowed,
    uint256 tokenId,
    address ZNft
) external view override returns (uint256)

When a user has positive liquidity, they can borrow from the zBond contract. Note that, different from most of the DeFi lending protocols, the liquidity is calculated separately for each NFT project. (e.g., with 1 BAYC valued at 50 ETH pledged, the user can only borrow 50 ETH in the BAYC's zBond pool. They cannot borrow from Doodle's zBond pool, unless they have pledged Doodle in the zDoodle contract.)

To borrow, users need to call the borrow function, where the users specify how long the loan term is, and the total amount of assets to borrow. When borrowing, the users will automatically pay an upfront underwriting fee. Currently, the underwriting fee is sitting at 5% per loan.

To borrow when there's enough liquidity:

Paying back the loan

For each loan, the borrower has to pay back to the protocol a minimum payment at least every 30 days. The duration of the minimum payment is subject to change depending on how our community feels about the frequency. The minimum payment is the interest accrued at the block where repayBorrow() is called. Additionally, at the end of the loan term, the user has to pay back all of the borrowed amount plus interest.

To check the address' current loan balance:

To check the address' loan balance at maturity:

To repay loan:

Interest rate calculation

Zumer protocol has a unique way of determining the interest rate. The total interest rate for a loan position is determined by two parts: Credit Cost and Funding Ratio.

Credit Cost

Each project has a flat interest rate, depending on how risky a project is. We have 3 tiers of interest rates for projects ranging from risky, normal, and safe. This stable interest rate depending on the project is called the Credit Cost.

Funding Ratio

All projects share a varying interest ratio determined by how long the loan term is. We call this interest ratio the Funding Ratio. The longer a loan term is, the higher the Funding Rate. This pattern is to discourage longer-than-needed loan terms so that the lenders' funds can be at lower risk when extreme market movement happens. The parameters for the funding rate can be changed

Last updated