I developed games and mobile games using Unity.
The connection between Unity and the web application is via web socket.
We have developed a game app for real-time video conferencing(webRTC, RTCMultiConnection).
The jslib method is used to call web functions in Unity.
Real-time calling of Unity functions on the web uses websocket, jslib.
Thanks for reading.