ccxws icon indicating copy to clipboard operation
ccxws copied to clipboard

ws agent support

Open zhaoqinghai opened this issue 3 years ago • 0 comments

i try to modify smart-wss.js to add proxy like this:

const { default: HttpsProxyAgent } = require("https-proxy-agent/dist/agent");
this._wss = new WebSocket(wssPath, {
  perMessageDeflate: false,
  handshakeTimeout: 15000,
  agent: new HttpsProxyAgent('http://127.0.0.1:8001')
});

i hope do this when i new exchange like this:

let binance = new ccxws.Binance({
  agent: new HttpsProxyAgent('http://127.0.0.1:8001')
})

zhaoqinghai avatar Jun 13 '21 07:06 zhaoqinghai