ecoppen / futuresboard

Dashboard to monitor the performance of your Binance or Bybit Futures account
http://www.futuresboard.dev/
GNU General Public License v3.0
139 stars 52 forks source link

Unified Trading Account #98

Open georgedevelopment opened 1 year ago

georgedevelopment commented 1 year ago

Hello,

It would be great if you could add support for ByBits new Unified Trading Account.

I have upgraded to Unified Trading Account & the dashboard throws errors. When i tried updating the wallet-balance api request from CONTRACT to UNIFIED, when starting futuresboard, it still throws an error regarding it using CONTRACT still

Not sure how i'll fix this, but would be great if you added support for UTA in config

ecoppen commented 1 year ago

The fix for you is to change this line of code: https://github.com/ecoppen/futuresboard/blob/001b38e6692016e7f5106dae9a25a51c0ea175d5/src/futuresboard/scraper.py#L547 to params = {"coin": "USDT", "accountType": "UNIFIED"}

This should be implemented in #91 #93 #95 #97 for version 2 hopefully but I need to work out how to accommodate both types. I won't be updating version 1 with this change though.