Retrieve Pools Info inside Contract
Read the supply ceiling and borrow cap ratio for a NAVI reserve in Move.
Select a reserve
Choose the market's Storage and the reserve's u8 asset index within that market. NAVI keeps its reserve fields private and exposes public getters in lending_core::storage.
Read the reserve caps
use lending_core::storage::{Self, Storage};
public fun reserve_caps(storage: &mut Storage, asset: u8): (u256, u256) {
let supply_ceiling = storage::get_supply_cap_ceiling(storage, asset);
let borrow_ceiling_ratio = storage::get_borrow_cap_ceiling_ratio(storage, asset);
(supply_ceiling, borrow_ceiling_ratio)
}The first value is the configured supply ceiling. The second is a borrow cap ratio. To look up current reserve settings by market, see Market parameters.