Market Information

Fetch a metadata struct in the Qubit's markets constant.
A qToken's collateral factor can range from 0-90%, and represents the proportionate increase in liquidity (borrow limit) that an account receives by minting the qToken.
Generally, large or liquid assets have high collateral factors, while small or illiquid assets have low collateral factors. If an asset has a 0% collateral factor, it can't be used as collateral (or seized in liquidation), though it can still be borrowed.


struct MarketInfo {
bool isListed;
uint borrowCap;
uint collateralFactor;
function marketInfoOf(address qToken) external view returns (MarketInfo memory);
  • RETURN: Metadata struct named MarketInfo


Qore qore = Qore(<qoreAddress>);
MarketInfo memory info = qore.marketInfoOf(<qTokenAddress>);


const qore = await ethers.getContractAt(<qoreABI>, <qoreAddress>);
const info = await qore.marketInfoOf(<qTokenAddress>);
const { collateralInUSD, supplyInUSD, borrowInUSD } = info;