Skip to main content
한국어로 읽기

What does an oracle do?

A smart contract is a program that executes rules on a blockchain. It can read information recorded onchain, but it cannot directly look up an exchange price or FX rate on the internet. An oracle supplies external information to smart contracts. Lending protocols use its prices to value collateral and check whether that value is sufficient to back the debt. Each protocol sets its own liquidation thresholds and rules.

How does batt use oracles?

Loans in batt are denominated in KRW*, so batt also needs to value collateral in won. For ETH collateral, the protocol needs the amount deposited, ETH’s dollar price, and the won-dollar exchange rate. batt uses those inputs to calculate the collateral’s value in won. It then compares that value with the debt to calculate the collateral ratio and determine whether the position can be liquidated.

Combining the dollar price and exchange rate

For ETH, the relationship is ETH/USD × USD/KRW = ETH/KRW, where USD/KRW means the number of won per dollar. Multiply the resulting price in won by the amount deposited to get the position’s collateral value. The formula describes how to calculate that value; it does not specify a data provider or feed configuration. When valuing wrapped tokens or yield-bearing collateral, account for the conversion rate into the underlying asset and any difference between the token’s market price and its underlying value.

A constant ETH price does not mean a constant won value

Consider the value of one ETH: When the won strengthens, each dollar is worth fewer won, so the collateral is worth less in won. A fall in ETH’s dollar price would reduce that value further. The exchange rate does not increase the number of KRW* tokens you owe. See Managing your position for collateral-ratio calculations and ways to respond.

Check when each price was updated

An up-to-date collateral price combined with an old exchange rate can give a valuation that differs from the current market. When assessing your collateral ratio, check when each price was last updated. FX data availability and update intervals vary by provider. A paused feed does not mean that won trading has stopped in every market. When a stale input updates, the collateral ratio can change abruptly.

A valuation is not an execution price

An oracle provides a reference price, but it does not provide a buyer at that price. The price you can sell the collateral for depends on liquidity, price impact, and fees. The oracle’s valuation of your collateral and KRW*‘s market price are separate. The reference values used to calculate your collateral ratio do not determine how much you will pay to buy KRW* for repayment.

Implementation details not yet published

We have not yet published feed addresses, limits on how old a price can be, or rules for handling feed failures. This explanation should not be taken as confirmation that fallback feeds, weekend handling, or automatic transaction halts are implemented. Manage changes in your collateral ratio