Let's say I have a room with 5 participants. 1 moderator and 4 participants and the moderator needs to mute a particular participant in the room or mute everyone but him/her self. I keep coming across code that seems to indicate a "localParticipant" which seems to be a client side construct referring to the code connected to the examples. I tried to use the following code to drill down into the room and participants but I am not seeing anything helpful under tracks which would be ideal:
let client = await twilio(ACCOUNT_SID, AUTH_TOKEN);
let room = await client.video.rooms(roomSid).fetch();
let participant = await room.participants().get(participantSid).fetch();
let tracks = await participant.publishedTracks.get('Camera').fetch();
I would like to allow the client side code to hit an endpoint that would take the room and participant sid's and mute/unmute from there. Can this be controlled via an express endpoint? I saw a twilio-video package on npm but that seems to be for client-side purposes.