Regarding buysells ("side") in Unified trade history
See original GitHub issueKroitor you are an impressive human. i have been writing a similar lib for only 6 exchanges over the past 3 months and would love to help with the websocket stuff in the future if you’d like that. One thing I’ve found is that it’s useful to have both orderbooks, trades, and “orderbook changes” (add, updates, removes), errors, and resets, as available endpoints.
I was wondering what you thought of the “side” parameter in the public trade APIs for each coin. For example, GDAX has the following listed for their buy/sell trade history:
buy side indicates a down-tick because the maker was a buy order and their order was removed. Conversely, sell side indicates an up-tick.
On the other hand, Gemini seems to list them the other way:
- buy means that an ask was removed from the book by an incoming buy order.* sell means that a bid was removed from the book by an incoming sell order. * auction indicates a bulk trade from an auction.
Thus a “buy” on Gemini is considered a “sell” on Gdax, messing up a Unified API that doesn’t take this into consideration. As someone who has spent some time making the exact same thing as you, I feel your frustration with tedious differences like this.
I noticed in the docs you have listed:
'side': 'buy', // direction of the trade, 'buy' or 'sell'
Which is a little ambiguous.
I was just wondering whether CCXT has taken into account these buysell paramter differences between the exchanges.
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (3 by maintainers)
Top GitHub Comments
Hi! Thx for the feedback!
This is currently a work in progress and we think that the side of the trade should indicate the taker order side. So, pay attention to that, because we don’t have it unified completely yet, namely, the order API (including the trades) is still under development. There may be bugs and inconsistencies here and there, because, yes, those little differences are overwhelming. We will be happy if you report all inconsistencies that you find, and this way we will find and fix them completely. We will be even happier if you submit your contributions to the library, PRs are welcome. Fixing those types of inconsistencies is most of the time very straightforward, just make sure to read the CONTRIBUTING doc in the root of this repo. As with any public library, users are free to submit their contributions, this is what a library really means, many authors. So, the answer to your questions is: YES, but NO 😃 We are working on it, be careful, pay attention and report bugs, plz.
Let me know if the above answered your question, please. I’d close this for now. And I’ll fix the difference of GDAX vs Gemini. Btw, thanks for the testing method suggestion as well, appreciate your involvement! If you find any particular inconsistency feel free to reopen this issue or open another one, or just ask your questions here if you have more.
Thanks. It appears Gdax is the exception to the 6 exchanges I’m looking at.