burakoner / OKEx.Net

Open source .Net API wrapper for the @OKEx V5 Rest API and V5 Websocket API
MIT License
86 stars 48 forks source link

SubscribeToOrderUpdates not working #71

Closed mo-kml closed 2 years ago

mo-kml commented 2 years ago

hello there Im using socketClient and i want to Subscribe to orders channel but it doesnt work. AccountUpdate DOES work but orderAndPosition doesnt work at all and i dont receive any message im using your sample code CallResult<UpdateSubscription> b = socketClient.SubscribeToOrderUpdates(OkexInstrumentType.SWAP, "1INCH-USDT-SWAP", "1INCH-USDT", (data) => { if (data != null) { // ... Your logic is here } });

var a = socketClient.SubscribeToPositionUpdates(OkexInstrumentType.SWAP, "1INCH-USDT-SWAP", "1INCH-USDT", (data) => { if (data != null) { // ... Your logic is here } });

it returns success but i dont receive any message when i manually add a trigger position to this coin

mo-kml commented 2 years ago

update if i set instrument type to ANY and pass null to all parameters then i get the message async is there any problem with OKX?

tohoff82 commented 2 years ago

I have the same problem with getting order updates via sockets. Update events are not coming.

tohoff82 commented 2 years ago

I have the same problem with getting order updates via sockets. Update events are not coming.

I figured out my issue. I am using demo trading and have not set the appropriate flag in OkexSocketClientOptions. My apologies.