Skip to content
This repository is currently being migrated. It's locked while the migration is in progress.

Wrong type in returnTradeHistory #38

Open
bikerduweb opened this issue Aug 7, 2018 · 1 comment
Open

Wrong type in returnTradeHistory #38

bikerduweb opened this issue Aug 7, 2018 · 1 comment

Comments

@bikerduweb
Copy link

It seems that there is a bug in the "returnTradeHistory" API. The "type" field is always filled with "buy" value, even when the order is a sell order... So how to differentiate a buy and sell order in the returned history?

@bikerduweb
Copy link
Author

bikerduweb commented Aug 7, 2018

As an exemple here is what API returns for one of my trade on pair ETH_OWN
{"date"=>"2018-08-07 03:46:47", "amount"=>"250000", "type"=>"buy", "total"=>"0.2025", "price"=>"0.00000081", "orderHash"=>"0x0aa2bc7c2277c51e4c78b6becc6fd82547261f06eaa3a990867b2a0ea7bdeaef", "uuid"=>"82513470-99f4-11e8-bbe8-6d8f1f4c08e7", "buyerFee"=>"500", "sellerFee"=>"0.0002025", "gasFee"=>"2098.76543209876525", "timestamp"=>1533613607, "maker"=>"0x93d92fc160318c65efba60c48815b631862693ec", "taker"=>"0x93af941a7dcafba72204a37f60a98bfb0bbb5107", "transactionHash"=>"0x980a25e8e17ef7219e5c8238546e964bbffbd2c9970ec6500dd340b38efe10d5", "usdValue"=>"141.75"}

In the web interface, this is a sell order, which is right ... But through the API, the type is "buy" which is wrong ... I didn't buy but sold OWN tokens.

What is expected is that when my trade is me selling, the type should be filled with "sell" value like in all other exchange api ... Because otherwise, how can I differentiate beetween my buy and my sell orders ?

PS: i've seen that a similar issue was closed because of lack of information... I hope that thoses comments provides more information.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant