Created
July 25, 2018 21:57
-
-
Save sixstringsg/5c6f71d5465feef2e49e801752933f9d to your computer and use it in GitHub Desktop.
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
#!/usr/bin/python | |
import json | |
import requests | |
# Note: Change localhost to the correct IP if needed. | |
r = requests.get('http://10.22.22.154/admin/api.php') | |
rstats = json.loads(r.text) | |
stats = {} | |
for x in rstats: | |
stats[x] = float(rstats[x].replace(',', '')) | |
print json.dumps(stats) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment