help me to get websocket data

Lukket Opslået 3 år siden Betalt ved levering
Lukket Betalt ved levering

i am trying to get a proper websocket feed from an exchange , i can get 20 lvl deep data but it is not enough for me ,a doc shows method for bigger level guide but i couldnt figure it out. Plz help me to get a feed for 150 lvls

this is doc url:

--[login to view URL]

this is my code:

const WebSocket = require('ws')

const pako = require('pako');

let huobbidsorderBooks = []

let huobasksorderBooks = []

let koinA = ['ankrusdt']

ws = new WebSocket('wss://[login to view URL]');

[login to view URL] = () => {

[login to view URL]((coinz) => {

[login to view URL]([login to view URL]({

"sub": "market." + coinz + ".mbp.150",

"id": "id1"

}));

[login to view URL]([login to view URL]({

"req": "market." + coinz + ".mbp.150",

"id": "id2"

}));

});

}

[login to view URL]('message', function(data) {

data = [login to view URL](data, { to: 'string' });

let msg = [login to view URL](data);

try {

let Pair = [login to view URL]('.')[1]

let pairz = [login to view URL](0, -4)

huobbidsorderBooks[Pair] = [login to view URL]

huobasksorderBooks[Pair] = [login to view URL]

// [login to view URL](huobbidsorderBooks['ankrusdt'])

[login to view URL](msg)

} catch (error) {

[login to view URL](error)

}

});

all you need to do is make this msg to turn usable one array that have price and size info like this:

[

[ 0.193509, 1554.47 ], [ 0.193508, 8999.47 ],

[ 0.193277, 4001.49 ], [ 0.193273, 516.62 ],

[ 0.193272, 3099.58 ], [ 0.193271, 14589.41 ],

[ 0.193269, 753.84 ], [ 0.193265, 4540 ],

[ 0.193264, 5375.71 ], [ 0.193263, 2261.52 ],

[ 0.193226, 754.31 ], [ 0.193222, 754.3 ],

[ 0.193216, 1900 ], [ 0.193195, 615.83 ],

[ 0.193192, 5372.54 ], [ 0.193189, 5376.75 ],

[ 0.193181, 13000 ], [ 0.193173, 1508.66 ],

[ 0.193168, 754.31 ], [ 0.193157, 18814.71 ]

..... // total 150 levels (lines)

]

right now you can have this with sending

"sub": "market." + coinz + ".mbp.refresh.20",

this line change but it only give 20 lines and that s not enough for me 100 or 150 prorably fits for me

your whole job is explained here budget is 100 usd

JavaScript Node.js Socket IO

Projekt ID: #29901905

Om projektet

3 bud Remote projekt Aktiv 2 år siden

3 freelancere byder i gennemsnit $350 timen for dette job

IakovAgababian

Hi $100 for project I am a full stack developer over 6 years for website and so I can help you with my skills please contact me and discuss more thanks

$250 USD på 1 dag
(3 bedømmelser)
3.4
romasatrian

Hello, dear. I can do your job perfectly, as I am a Node JS expert. I have great experience with NodeJS/Express, MongoDB and mysql. As well as I have strong knowledge of Frontend such as ReactJS, Vue JS , Angular Flere

$300 USD in 2 dage
(0 bedømmelser)
0.0