webrtcgateway: refactor API message handling
- Introduce JSON models to validate data
- Detach message handling from the WebSocket protocol
This paves the way to fully-detaching a user's connection from the WS connection,
which will allow us to support a push-notification scheme in which a connection is detached
when a user's device goes to sleep and it's kept lingering until the device comes back.