Skip to content

Commit 909df0e

Browse files
committed
binance oracle
1 parent 2b966d0 commit 909df0e

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed

oracle/BinanceOracle.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# Binance Oracle
2+
3+
## Introduction
4+
5+
This oracle fetchs prices of assets from Binance on-chain oracle.
6+
7+
## Solidity APIs
8+
9+
### initialize
10+
11+
```solidity
12+
function initialize(contract FeedRegistryInterface feed) public
13+
```
14+
15+
Sets the contracts required to fetch price
16+
17+
#### Parameters
18+
19+
| Name | Type | Description |
20+
| ---- | ---- | ----------- |
21+
| feed | contract FeedRegistryInterface | Address of binance oracle feed registry. |
22+
23+
### getUnderlyingPrice
24+
25+
```solidity
26+
function getUnderlyingPrice(contract VBep20Interface vToken) public view returns (uint256)
27+
```
28+
29+
Gets the price of vToken from binance oracle
30+
31+
#### Parameters
32+
33+
| Name | Type | Description |
34+
| ---- | ---- | ----------- |
35+
| vToken | contract VBep20Interface | Address of the vToken |
36+
37+
#### Return Values
38+
39+
| Name | Type | Description |
40+
| ---- | ---- | ----------- |
41+
| [0] | uint256 | price in USD |

0 commit comments

Comments
 (0)