coinfloor / API

All you need to know about the APIs for Coinfloor's Trade Engine
Apache License 2.0
34 stars 20 forks source link

websocket orderbook events look wrong #35

Closed npomfret closed 4 years ago

npomfret commented 4 years ago

I've subscribing to one and only one orderbook feed in my process

{ message: 'subscribing to ob feed',
  key: '63488.64032',
  marketSymbol: 'BTC/GBP',
  baseMapping: { ccy: 'XBT', scale: 10000, id: 63488 },
  quoteMapping: { ccy: 'GBP', scale: 100, id: 64032 } }

But I occasionally get events for another channel:

{ base: 63488,
     counter: 64000,
     id: 35119760,
     notice: 'OrderClosed',
     price: 811700,
     quantity: -28,
     tonce: 1590511543, }
whitslack commented 4 years ago

You always get notifications related to your own orders, regardless of your book subscriptions. (You can tell it's your own order because it includes the tonce field.)

npomfret commented 4 years ago

Ah right, thanks. Did I miss this in the docs?

whitslack commented 4 years ago

Ah right, thanks. Did I miss this in the docs?

Yes:

Authenticated users receive notice of their own orders.

[tonce] is present only if the recipient of the notification is the owner of the order.