🪙bToken Introduction

Introduction

Each asset supported by Blueberry Bank is integrated through a bToken contract, which is an EIP-20 compliant representation of balances supplied to the protocol. By minting bTokens, users (1) earn interest through the bToken's exchange rate, which increases in value relative to the underlying asset, and (2) gain the ability to use bTokens as collateral.

bTokens are the primary means of interaction with Blueberry Bank; when user mints, redeems, borrows, repays a borrow, liquidates a borrow, or transfers bTokens, they will do so using the bToken Contract.

Blueberry Bank GitHHub Organization: https://github.com/blueberryfi

All mentions of BErc20 refer to https://github.com/blueberryfi/compound-protocol/blob/eth/contracts/BCollateralCapErc20.sol

Mint

The mint function transfers an asset into the protocol, which begins accumulating interest based on the current Supply Rate for the asset. The user receives a quantity of bTokens equal to the underlying tokens supplied, divided by the current Exchange Rate.

BErc20

// funcation mint(uint mintAmount) returns (uint)

Last updated