Hu-Fi / Mr.Market

Mr. Market is the exchange oracle of HuFi, and a CeFi crypto bot on Mixin Messenger
https://mr-market-one.vercel.app
GNU Affero General Public License v3.0
1 stars 6 forks source link

Add watchTicker and watchOHLCV for candlestick and enhanced data format #15

Closed zed-wong closed 6 months ago

zed-wong commented 6 months ago

Updated backend supported pairs API data format Added frontend fetch supported pairs on load and removed unused data Designed and updated backend websocket ticker data format Added ticker client and watch orderbook client in candlestick page

Encountered a new problem, some exchanges doesn't support watchOHLCV so the candlestick won't be live. Will filter these supported exchanges and apply watchOHLCV. Otherwise fallback to fetchOHLCV.

Now spot page orderbook, spot pair selector, candlestick pair selector and candlestick price/info are connected. Candlestick chart and real time orderbook is waiting to be done.

For now these changes won't be able to see from frontend deployment beacuse the backend tls is not configured so the websocket would be blocked by browser. Also the backend coingecko rate limit is not solved so sometimes the market page won't load properly.

Tomorrow's goal is to get candlestick page done. Including both the frontend and the backend.

zed-wong commented 6 months ago

23 Feb 2024

  1. Add access candlestick by path /market/candle/[exchange]/[symbol]
  2. Add switch candlestick via selector
  3. Add fetchOHLCV client code and connected OHLCV chart
  4. Tested timeRange for 3 exchanges and reduced options
  5. Add switch candlestick timeframe

I'm going to finish orderbook inside candlestick page today. No blockers yet.