Usage of DIA Oracles on Stacks
dApps building on Stacks can utilize DIA oracles to obtain up-to-date asset price information. These deployed oracles are suitable for use in production environments. They come with a list of supported assets and settings. However, if dApps require a custom oracle with a different set of assets and configurations, they should contact DIA on Telegram.Oracle Details
Chain | Address |
---|---|
Mainnet | SP1G48FZ4Y7JY8G2Z0N51QTCYGBQ6F4J43J77BQC0.dia-oracle |
Testnet | ST1S5ZGRZV5K4S9205RWPRTX9RGS9JV40KQMR4G1J.dia-oracle |
Oracle Configuration
Pricing Methodology | MAIR |
Deviation (%) & Refresh Frequency | 5% and 120 seconds |
Heartbeat | 15 minutes |
Asset Feeds
The Stacks oracle includes the following asset feeds:Asset Ticker | Asset Blockchain | Asset Address | Asset Sources |
---|---|---|---|
STX | Stacks | 0x0000000000000000000000000000000000000000 | STX Market |
stSTX | Stacks | SP4SZE494VC2YC5JYG7AYFQ44F5Q4PYV7DVMDPBG.ststx-token | stSTX Market |
DIKO | Stacks | SP2C2YFP12AJZB4MABJBAJ55XECVS7E4PMMZ89YZR.arkadiko-token | DIKO Market |
WELSH | Stacks | SP3NE50GEXFG9SZGTT51P40X2CKYSZ5CC4ZTZ7A2G.welshcorgicoin-token | WELSH Market |
VELAR | Stacks | SP1Y5YSTAHZ88XYK1VPDH24GY0HPX5J4JECTMY4A1.velar-token | VELAR Market |
ALEX | Stacks | SP3K8BC0PPEVCV7NZ6QSRWPQ2JE9E5B6N3PA0KBR9.age000-governance-token | ALEX Market |
sBTC | Stacks | SM3VDXK3WZZSA84XXFKAFAF15NNZX32CTSG82JFQ4.sbtc-token | sBTC Market |
aeUSDC | Stacks | SP3Y2ZSH8P7D50B0VBTSX11S7XSG24M1VB9YFQA4K.token-aeusdc | aeUSDC Market |
USDh | Stacks | SPN5AKG35QZSK2M8GAMR4AFX45659RJHDW353HSG.usdh-token-v1 | USDh Market |
BTC | Bitcoin | 0x0000000000000000000000000000000000000000 | BTC Market |
How to Access Data
You can query for assets like"STX/USD"
or "stSTX/USD"
in the get-value()
read function. It returns two values:
- The price of STX/USD with 8 decimals
- The timestamp of the last update (UTC timezone)
Oracle Grants Program
The DIA Oracle Grants Program provides zero-cost oracle access for up to 1 year, covering deployment and update costs to accelerate dApp development on Stacks. Learn more about the grant here:DIA Oracle Grants Program | Apply Now
Request a Custom Oracle
DIA offers highly customizable oracles that are individually tailored to each dApp’s needs. Each oracle can be customized in the following ways, including:- Data Sources & Asset Feeds
- Pricing Methodologies
- Update Triggers (Frequency, Deviation, Heartbeat, …etc)