BitMEX / api-connectors

Libraries for connecting to the BitMEX API.
https://www.bitmex.com/app/restAPI
910 stars 796 forks source link

official nodejs client for bitmex #68

Closed adityamertia closed 6 years ago

adityamertia commented 6 years ago

Is there an official nodejs client for bitmex apart from the autogenerated swagger based one? How do people use bitmex APIs till date in nodejs?

pabx06 commented 6 years ago

https://github.com/BitMEX/api-connectors/tree/master/official-ws/nodejs

i use websocket to get a stream price then restfull api for orders placement

adityamertia commented 6 years ago

@pabx06 This is for websocket. What about REST API clients. Mostly i see swagger autogenerated clients which do not work and some reference sample code. Nothing like official client from bitmex. Am i missing something ?

pabx06 commented 6 years ago

i am done with bitmex too much nerve wreaking getting 50% of the time today server "Overloaded response from API". as a result could not exit a trade whenever you want is a bit too much for my nerves. have my desktop ip banned at their firewall & my server API key banned.

you cant have more than 140 limit order to exit or enter gradualy either ...

too much of headache and unhealthy for me ...

i also suspect the swagger thing to be outdated ... you want ever be able to figure out what are the meaning of their gazillions filied in their api responses like new execution unless you had a background in the FIX protocol FIX is a brain fuck protocol

tanmaykumar commented 6 years ago

@pabx06 Did your IP get banned because of too many requests during a time the server was overloaded? If so then you can just add a sleep time of 0.5 seconds if you receive a 503 response and then try again. At least you won't get banned.

STRML commented 6 years ago

@pabx06 Keep on topic - your complaint about hitting ratelimits is not relevant to this discussion or even correct. As was already explained to you through another channel, you must use this API responsibly and pay attention to return codes and errors. Ignoring them and continuing to generate errors will get you banned from any decent API on the planet.

adityamertia commented 6 years ago

@tanmaykumar @STRML @pabx06 Can we stick to the core issue? I still do not have answer to it.

STRML commented 6 years ago

Yes @adityamertia: See the official-http and official-ws folders in the root, both of which have Node connectors. They are starting points and you can work from there. There is also a sample market making bot at https://github.com/BitMEX/sample-market-maker/.

adityamertia commented 6 years ago

Thanks @STRML. This sample market maker bot does support all APIs of bitmex? Is it as close i can get to the official REST client? Is there a nodejs version of the market maker bot?

STRML commented 6 years ago

That is for specific market making functionality only. Please see the Readme of each project. There is not yet a nodejs market making sample.

On Jan 18, 2018 9:16 AM, "Aditya Mertia" notifications@github.com wrote:

Thanks @STRML https://github.com/strml. This sample market maker bot does support all APIs of bitmex? Is it as close i can get to the official REST client? Is there a nodejs version of the market maker bot?

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/BitMEX/api-connectors/issues/68#issuecomment-358677676, or mute the thread https://github.com/notifications/unsubscribe-auth/ABJFP86NZjPjKT_c-qqCxL_g4z5MxUpeks5tL2BegaJpZM4Rijn7 .

IlanFrumer commented 6 years ago

A new BitMEX API connector https://github.com/IlanFrumer/BitMEX-nodejs