Comment on page
Reserves are an accounting entry in each qToken contract that represents a portion of historical interest set aside as cash which can be withdrawn or transferred through the protocol's governance. A small portion of borrower interest accrues into the protocol, determined by the reserve factor.
function totalReserve() external view returns (uint);
- RETURN: The total amount of reserves held in the market.
QToken qToken = QToken(<qTokenAddress>);
uint reserve = qToken.totalReserve();
const qToken = await ethers.getContractAt(<qTokenABI>, <qTokenAddress>);
const reserve = await qToken.totalReserve();