The WeChat applet does not support directly using the wss:// format to set the domain name
, but in fact we can use a delaying strategy.
Here we directly change it to https
and then we connect through wss://ws-api.turingapi.com/api/v2 as usual.
You can see that he is still connected successfully here.
Solution to the problem that the wss/ws setting of WebSocket in the WeChat applet requesting a legal domain name reports an error that the protocol header of the domain name is illegal
Guess you like
Origin blog.csdn.net/weixin_45966674/article/details/133303862
Recommended
Ranking