BitMEX / api-connectors

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

DeltaServer: Error on request 'curl http://localhost:4444/instrument' #268

Open golfdriver opened 5 years ago

golfdriver commented 5 years ago

The curl request causes the following error:

TypeError: data.map is not a function at clone (/home/ec2-user/bm-delta/api-connectors/official-ws/nodejs/index.js:231:15) at BitMEXClient.getData (/home/ec2-user/bm-delta/api-connectors/official-ws/nodejs/index.js:98:10) at /home/ec2-user/bm-delta/api-connectors/official-ws/delta-server/lib/server.js:76:21 at Layer.handle [as handle_request] (/home/ec2-user/bm-delta/api-connectors/official-ws/delta-server/node_modules/express/lib/router/layer.js:95:5) at next (/home/ec2-user/bm-delta/api-connectors/official-ws/delta-server/node_modules/express/lib/router/route.js:137:13) at Route.dispatch (/home/ec2-user/bm-delta/api-connectors/official-ws/delta-server/node_modules/express/lib/router/route.js:112:3) at Layer.handle [as handle_request] (/home/ec2-user/bm-delta/api-connectors/official-ws/delta-server/node_modules/express/lib/router/layer.js:95:5) at /home/ec2-user/bm-delta/api-connectors/official-ws/delta-server/node_modules/express/lib/router/index.js:281:22 at param (/home/ec2-user/bm-delta/api-connectors/official-ws/delta-server/node_modules/express/lib/router/index.js:354:14) at param (/home/ec2-user/bm-delta/api-connectors/official-ws/delta-server/node_modules/express/lib/router/index.js:365:14)

CoreyNelson commented 5 years ago

You need to include the symbol used in your config. Like this: http://localhost:4444/instrument?symbol=XBTUSD