mirror of
https://github.com/status-im/status-react.git
synced 2025-01-09 18:46:19 +00:00
69610e41ad
Signed-off-by: yevh-berdnyk <ie.berdnyk@gmail.com>
12 lines
357 B
Python
12 lines
357 B
Python
import requests
|
|
|
|
|
|
def get_ethereum_price_in_usd() -> float:
|
|
url = 'https://min-api.cryptocompare.com/data/price?fsym=ETH&tsyms=USD'
|
|
return float(requests.request('GET', url).json()['USD'])
|
|
|
|
|
|
def get_token_info(address: str):
|
|
url = 'http://api.ethplorer.io/getTokenInfo/%s?apiKey=freekey' % address
|
|
return requests.request('GET', url).json()
|