migrate oracle docs

This commit is contained in:
Oliver Eggert
2024-08-08 18:39:31 -07:00
parent 54b2de8271
commit cc16be9066
9 changed files with 537 additions and 1 deletions

View File

@@ -0,0 +1,33 @@
# Price Oracles
_(Requires the [PriceOracle amendment][] {% not-enabled /%})_
Blockchains can't inherintly interact with and "know" what's happening off the network, but many of its use cases in decentralized finance require this information.
Price oracles solve this problem. An oracle is a service or technology that gathers real-world information, such as market prices, exchange rates, or interest rates, and relays it to the blockchain. Like blockchains, most oracles are also decentralized and validate data through multiple nodes.
{% admonition type="info" name="Note" %}
Oracles aren't limited to only providing financial information. It can provide any type of info, such as what sports team won a game, or even the weather. The oracle implementation on the XRP Ledger, however, only gathers the price of assets.
{% /admonition %}
## How Oracles Works
Most oracle blockchain interactions work like this:
1. An oracle validates data on its network.
2. The data is sent to the blockchain.
3. The blockchain uses that information to execute a smart contract, such as releasing funds from an escrow.
This process can also work in reverse, pushing transaction information to external systems.
## Price Oracles on the XRP Ledger
XRPL price oracles are a native, on-chain oracle, enhancing the native DeFi functionality of the XRP Ledger. Off-chain price oracles send their data to XRPL oracles, which store that information on-chain. Decentralized apps can then query the XRPL oracles for price data; multiple XRPL oracles can be queried to minimize risk and inaccuracies.
By standardizing price feeds in this manner, all XRPL apps can access a dependable, shared data source.
{% raw-partial file="/docs/_snippets/common-links.md" /%}