简体   繁体   中英

Twilio Chat - can we use the npm package `twilio-chat` on server side?

I am trying an approach to encapsulate Twilio to our back end and using our own web socket for real-time chat experience. Can I use twilio-chat behind my web socket as a proxy server?

Twilio developer evangelist here.

twilio-chat is built as a browser based SDK and consequently relies on browser platform APIs, most notably web sockets. Node.js does not have a native or standard library implementation of web sockets, so you would have to polyfill them and likely other APIs into the global scope.

What I'm saying is that it's likely possible, but probably a hassle.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM