add bithumb
This commit is contained in:
parent
c39648a711
commit
ed722077fa
21
price.py
21
price.py
|
@ -439,6 +439,7 @@ def tall(bot, trigger):
|
||||||
usdcny = fixerjson['rates']['CNY']
|
usdcny = fixerjson['rates']['CNY']
|
||||||
usdeur = fixerjson['rates']['EUR']
|
usdeur = fixerjson['rates']['EUR']
|
||||||
usdjpy = fixerjson['rates']['JPY']
|
usdjpy = fixerjson['rates']['JPY']
|
||||||
|
usdkrw = fixerjson['rates']['KRW']
|
||||||
except:
|
except:
|
||||||
usdcny = 7
|
usdcny = 7
|
||||||
# Bitstamp
|
# Bitstamp
|
||||||
|
@ -484,14 +485,22 @@ def tall(bot, trigger):
|
||||||
finexjson = False
|
finexjson = False
|
||||||
if finexjson:
|
if finexjson:
|
||||||
stringtosend += "Bitfinex last: {0:,.2f}, vol: {1:,.1f} | ".format(float(finexjson['last_price']), float(finexjson['volume']))
|
stringtosend += "Bitfinex last: {0:,.2f}, vol: {1:,.1f} | ".format(float(finexjson['last_price']), float(finexjson['volume']))
|
||||||
# BTCC
|
# Bitthumb
|
||||||
try:
|
try:
|
||||||
btccresult = requests.get(btccurl)
|
thumbresult = requests.get(thumbbtcurl)
|
||||||
btccjson = btccresult.json()
|
thumbjson = thumbresult.json()
|
||||||
except:
|
except:
|
||||||
btccjson = False
|
thumbjson = False
|
||||||
if btccjson:
|
if thumbjson:
|
||||||
stringtosend += "BTCC last: {0:,.2f}, vol: {1:,.1f} | ".format(float(btccjson['ticker']['last'])/usdcny, float(btccjson['ticker']['vol']))
|
stringtosend += "Bithumb last: {0:,.2f}, vol: {1:,.1f} | ".format(float(thumbjson['data']['buy_price'])/float(usdkrw), float(thumbjson['data']['volume_1day']))
|
||||||
|
# BTCC
|
||||||
|
# try:
|
||||||
|
# btccresult = requests.get(btccurl)
|
||||||
|
# btccjson = btccresult.json()
|
||||||
|
# except:
|
||||||
|
# btccjson = False
|
||||||
|
# if btccjson:
|
||||||
|
# stringtosend += "BTCC last: {0:,.2f}, vol: {1:,.1f} | ".format(float(btccjson['ticker']['last'])/usdcny, float(btccjson['ticker']['vol']))
|
||||||
# Huobi
|
# Huobi
|
||||||
try:
|
try:
|
||||||
huobiresult = requests.get(huobiurl)
|
huobiresult = requests.get(huobiurl)
|
||||||
|
|
Loading…
Reference in New Issue