Additional parameters for Websocket client and server connections

Websocket client connects to server:

  1. The server cannot know the client type when it receives the client handshake

  2. The server cannot forward communication according to the client’s request business

  3. I need to get the client to connect to the server with additional parameters, such as the client type.

Hi

Can’t you just send a message over the new web socket identifying the client?

Thank you for your answer.

I can’t just send messages through client sockets, because different client types are different, and I need to know whether it’s mobile, PC, or server.Although sockets are convenient and can be stored, it is important to record the type of client when a different client forwards a message to another client.

But so far I haven’t found a solution, if you have a better suggestion.