2️⃣Get Pools Config and Oracle Price Feeds
NAVI offers essential data about specific lending and borrowing pools, as well as oracle price feeds, through its public API and NAVI SDK. This data includes key details like pool ID, reserve ID, borrow and supply balances, caps, interest rates, and oracle prices. It enables developers and users to understand the current state of a pool, its limitations, and potential opportunities for interaction, such as borrowing, supplying, and calculating rewards.
Oracles in the NAVI Protocol
In the NAVI protocol, each oracle is associated with a specific poolId
, enabling developers to efficiently access and interact with oracle data. The oracle provides essential fields for accurate financial operations:
Decimal: Defines the decimal precision of the pool's coin, ensuring calculations are accurate.
OracleID: The unique identifier for the oracle, specifying its asset ID.
Value: The current data point provided by the oracle, typically a numeric metric such as an asset price or exchange rate.
Price: The market price retrieved from the oracle, ensuring real-time accuracy in financial computations.
Valid: A boolean that indicates whether the oracle’s data is reliable and up-to-date. If
valid
is true, the data can be used safely for calculations. If false, the data may be outdated or unreliable.
To query an oracle, use the API to retrieve the oracle object linked to each pool and ensure you are accessing the correct data.
Sample Data of Sui Price from API:
Sample Tx and on-chain event of NAVI Orace Sui Price:
Last updated