drpout / boilr

Price alarms for Bitcoin, cryptocurrencies, cryptoassets, futures and options.
http://boilr.mobi
GNU General Public License v3.0
128 stars 67 forks source link

Decimal places don't match quotes #284

Open shonut opened 6 years ago

shonut commented 6 years ago

First off, great work, I've finally found an app that works with Coinsquare, where I trade. I really like how I can select what I'm interested in, and it's right there. I have a few issues, which I will address in separate posts. This one relates to reported decimal places. I don't know if it's a libdynticker issue or a boilr issue. For Consquare, the information is pulled from:

https://coinsquare.io/api/v1/data/quotes

The data is reported by the site link in satoshis (except BTC/CAD), but the app reports an inaccurate conversion to BTC, off by a factor of 100. Coincidentally, the classic coinsquare site uses uBTC, which is satoshi divided by by 100. As an example, please see the following pairs:

CAD/BTC reported by the above link as 8559 satoshi (i.e. 0.00008559 BTC) reported by the app as 0.008559 BTC. It's off by a factor of 100

LTC/BTC reported by the above link as 1767000 satoshi (i.e. 0.01767000 BTC) reported by the app as 1.767 BTC. It's off by a factor of 100

ETH/BTC reported by the above link as 10540000 satoshi (i.e. 0.10540000 BTC) reported by the app as 10.54 BTC. It's off by a factor of 100

Note that BTC/CAD is reported correctly reported by the above link as 1162115 cents (i.e. $11,621.15 CAD) reported by the app as $11,621.15 CAD. It's correct as noted

As noted, I don't know if this is a libdynticker issue or a boilr issue. If Boiler, the ideal solution would to have the user be able to set a multiplier (for example, I would want to have the app report uBTC as that's what I'm used to trading on the site, which I would set to be 0.001 to multiply by the reported valve to display uBTC. If this is not an option to add a user-set multiplier, then please look into why the math is incorrect for Coinsquare.

Thanks in advance for your time!