Updated Coinsecure Api

Added Unocoin Api
This commit is contained in:
Anwesh 2015-12-10 15:51:19 +05:30
parent b7cef8dd58
commit b23c22b29d
1 changed files with 8 additions and 3 deletions

View File

@ -212,9 +212,14 @@ class CoinDesk(ExchangeBase):
class Coinsecure(ExchangeBase):
def get_rates(self, ccy):
json = self.get_json('api.coinsecure.in', '/v0/noauth/lasttrade')
return {'INR': Decimal(json['result'][0]['lasttrade'][0][bid][0][rate] / 100.0 )}
json = self.get_json('api.coinsecure.in', '/v0/noauth/newticker')
return {'INR': Decimal(json['lastprice'] / 100.0 )}
class Unocoin(ExchangeBase):
def get_rates(self, ccy):
json = self.get_json('www.unocoin.com', 'trade?buy')
return {'INR': Decimal(json)}
class itBit(ExchangeBase):
def get_rates(self, ccy):
ccys = ['USD', 'EUR', 'SGD']