Created
November 24, 2021 09:40
-
-
Save mmajewsk/1c5fbda814fc749a647cd9136618c908 to your computer and use it in GitHub Desktop.
snippet for viewing ETH EUR trading pair from kraken in XFCE
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import requests | |
r = requests.get("https://api.kraken.com/0/public/OHLC?pair=XETHZEUR&interval=60") | |
data = r.json() | |
viewable = data['result']["XETHZEUR"][-1][-3] | |
print(viewable[:-3]+'€') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment