Developers
Search…
Total Reserve
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.

QToken

function totalReserve() external view returns (uint);
  • RETURN: The total amount of reserves held in the market.

Solidity

QToken qToken = QToken(<qTokenAddress>);
uint reserve = qToken.totalReserve();

Ethers.js

const qToken = await ethers.getContractAt(<qTokenABI>, <qTokenAddress>);
const reserve = await qToken.totalReserve();
Copy link
On this page
QToken
Solidity
Ethers.js