I have tried using the native websocket library to initiate upgrade connection requests. However, my server requires the access token to be sent as a header.
Is there a way to pass access token as a custom header using the Websocket library, or is there any other alternative that I can use
I tried using socket io client but that doesn’t give a proper solution as the custom header is not passed when the transport is set to ‘websocket’
New contributor
TeeeeJ is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
2