Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dia.md #646

Merged
merged 1 commit into from
Mar 20, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
16 changes: 4 additions & 12 deletions docs/build/integrations/oracles/dia.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,21 +53,13 @@ DIA Development Oracle contracts are not intended to be integrated into a dApp.
The oracle contains information about crypto assets. You can access a price quotation (see [sources](https://docs.diadata.org/documentation/methodology/digital-assets/cryptocurrency-trading-data) and [methodology](https://docs.diadata.org/documentation/methodology/digital-assets/exchangeprices)) and the current circulating supply as well as the timestamp of the last update.

1. Access the corresponding oracle smart contract (see table above).
2. Call `getCoinInfo(coin_name)` with `coin_name` being the full coin name such as `Bitcoin`. You can use the "Read" section on Etherscan to execute this call.
3. The response of the call contains four values:
1. The current asset price in USD with a fix-comma notation of five decimals.
2. The current circulating supply.
3. The [UNIX timestamp](https://www.unixtimestamp.com/) of the last oracle update.
4. The short name of the asset, e.g., `BTC` for Bitcoin.
2. Call `getValue(symbol)` with `symbol` being the asset symbol such as `BTC/USD`. You can use the "Read" section on Etherscan to execute this call.
3. The response of the call contains two values:
1. The current asset price in USD with a fix-comma notation of eight decimals.
2. The [UNIX timestamp](https://www.unixtimestamp.com/) of the last oracle update.

The development oracle supports price quotations for, at the very least, the following assets:

- BTC
- ETH
- DIA
- USDC
- FTM
- SDN
- KSM
- MOVR
- ASTR