After posting this I figured out the solution pretty quickly using FMEServer.js as a reference.
Basically - You have to create a new WebSocket object with the URL and then "onopen" send a message to the server with a special FME JSON object describing what stream you are interested in and how the server should handle it. below is an example of just subscribing to a particular stream:
let streamId = "myStreamId";
let fmeWebSocket = new WebSocket("ws://myWebServer:7078/websocket");
fmeWebSocket.onopen = function(event){
console.log("websocket connected!!!!");
let openMsg = {
ws_op : 'open',
ws_stream_id : streamId
};
fmeWebSocket.send(JSON.stringify(openMsg));
};
fmeWebSocket.onmessage = function(event) {
console.log("Got the message from the server!!! Event data: " + event.data);
};