diff --git a/electrum/currencies.json b/electrum/currencies.json index ec9240015..657072bef 100644 --- a/electrum/currencies.json +++ b/electrum/currencies.json @@ -386,6 +386,9 @@ "TWD", "USD" ], + "Bylls": [ + "CAD" + ], "CoinCap": [ "USD" ], diff --git a/electrum/exchange_rate.py b/electrum/exchange_rate.py index 228d020ed..6d710e0c9 100644 --- a/electrum/exchange_rate.py +++ b/electrum/exchange_rate.py @@ -238,6 +238,13 @@ class BlockchainInfo(ExchangeBase): return dict([(r, Decimal(json[r]['15m'])) for r in json]) +class Bylls(ExchangeBase): + + async def get_rates(self, ccy): + json = await self.get_json('bylls.com', '/api/price?from_currency=BTC&to_currency=CAD') + return {'CAD': Decimal(json['public_price']['to_price'])} + + class Coinbase(ExchangeBase): async def get_rates(self, ccy):