Consider these structures:
The gob package handles the passing of the populated and mismatched fields during the encode / decode.
Below is a noddy example of passing such message structures through a secure websocket. The code not only shows the gob package in action but also highlights how trivial golang makes the coding of a secure websocket for both the client and server.
Server:
Client: