JS chat example fail on client connection: HTTP Authentication failed
I'm testing the service using the chat example and it doesn't work for me.
Following the documentation or downloading the JavaScript chat example from https://github.com/Azure/azure-webpubsub/tree/main/samples/javascript/chatapp, always find an "HTTP Authentication failed; no valid credentials available" when the client try to open a websocket connection with the token url.

WIth the Live Trace Tool, I found the following message that doesn't help so much

And the ngrok always has a 401 error on eventhandler

I also checked the token at jwt.ms and It's seemed good

any help?
The live trace shows that you've registered connect event and it returns 401

So for this chat sample, the sample code only configured connected event, you can either:
- Update event handler in the portal to uncheck
connectevent:

- Or update the node.js server code to handle
connectevent: