EVENT | Description |
Error Event | |
Kicked out of room event | |
Current user Kicked off line event | |
UserSig Expiration Event | |
Host Destroy Room Event | |
Room Name Change Event | |
Room Speech Mode Change Event | |
All members Camera Usage Permission Change Event | |
All members Mic Usage Permission Change Event | |
All members Send Message Status Change Event | |
Room Maximum Seat Count Change Event | |
Remote User Entered Room Event | |
Remote User Leave Room Event | |
User Role Change Event | |
User Video Status Change Event | |
User Audio Status Change Event | |
User Send Message Status Event | |
User Volume Change Event | |
User Network Quality Change Event | |
Seat List Change Event | |
User Kicked off Seat Event | |
Request Received Event | |
Request Cancelled Event | |
Receive Text Message Event | |
Receive Custom Message Event | |
Device Change Event | |
Screen Sharing Stopped Event When the user uses the built-in browser stop sharing button to end screen sharing, the user will receive the 'onUserScreenCaptureStopped' event to modify the screen sharing status. |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onError, (error) => {console.log('TUIRoomError error', error);})
Parameter | Type | Meaning |
code | number | Error Code |
message | string | Error Information |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onKickedOutOfRoom, ({ roomId, message }) => {console.log('roomEngine.onKickedOutOfRoom', roomId, message);});
Parameter | Type | Meaning |
roomId | string | Room ID |
message | string | Kicked out of room information |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onKickedOffLine, ({ message }) => {console.log('roomEngine.onKickedOffLine', message);});
Parameter | Type | Meaning |
roomId | string | Room ID |
message | string | User logged in on other end information |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onUserSigExpired, () => {console.log('roomEngine.onUserSigExpired');});
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onRoomDismissed, ({ roomId }) => {console.log('roomEngine.onRoomDismissed', roomId);});
Parameter | Type | Meaning |
roomId | string | Room ID |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onRoomNameChanged, ({ roomId, roomName }) => {console.log('roomEngine.onRoomNameChanged', roomId, roomName);});
Parameter | Type | Meaning |
roomId | string | Room ID |
roomName | string | Room Name |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onRoomSpeechModeChanged, ({ roomId, speechMode }) => {console.log('roomEngine.onRoomSpeechModeChanged', roomId, speechMode);});
Parameter | Type | Meaning |
roomId | string | Room ID |
speechMode | Speech Mode |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onAllUserCameraDisableChanged, ({ isDisable }) => {console.log('roomEngine.onAllUserCameraDisableChanged', isDisable);});
Parameter | Type | Meaning |
isDisable | boolean | Allow Camera Usage |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onAllUserMicrophoneDisableChanged, ({ isDisable }) => {console.log('roomEngine.onAllUserMicrophoneDisableChanged', isDisable);});
Parameter | Type | Meaning |
isDisable | boolean | Allow Mic Usage |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onSendMessageForAllUserDisableChanged, ({ isDisable }) => {console.log('roomEngine.onSendMessageForAllUserDisableChanged', isDisable);});
Parameter | Type | Meaning |
isDisable | boolean | Allow Sending Text Message |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onRoomMaxSeatCountChanged, ({ maxSeatNumber }) => {console.log('roomEngine.onRoomMaxSeatCountChanged', maxSeatNumber);});
Parameter | Type | Meaning |
maxSeatNumber | number | Maximum Seat Count |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onRemoteUserEnterRoom, ({ roomId, userInfo }) => {console.log('roomEngine.onRemoteUserEnterRoom', roomId, userInfo);});
Parameter | Type | Meaning |
roomId | string | Room ID |
userInfo | User Information |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onRemoteUserLeaveRoom, ({ roomId, userInfo }) => {console.log('roomEngine.onRemoteUserLeaveRoom', roomId, userInfo);});
Parameter | Type | Meaning |
roomId | string | Room ID |
userInfo | User Information |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onUserRoleChanged, ({ userId, userRole }) => {console.log('roomEngine.onUserRoleChanged', userId, userRole);});
Parameter | Type | Meaning |
userId | string | User Id |
userRole | User Changed Role |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onUserVideoStateChanged, ({ userId, streamType, hasVideo, reason }) => {console.log('roomEngine.onUserVideoStateChanged', userId, streamType, hasVideo, reason);});
Parameter | Type | Meaning |
userId | string | User Id |
streamType | User Stream Type | |
hasVideo | boolean | Has Video streams |
reason | Change Reason, Self-operation/Host-operation |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onUserAudioStateChanged, ({ userId, hasAudio, reason }) => {console.log('roomEngine.onUserAudioStateChanged', userId, hasAudio, reason);});
Parameter | Type | Meaning |
userId | string | User Id |
hasVideo | boolean | Has Audio streams |
reason | Change Reason, Self-operation/Host-operation |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onSendMessageForAllUserDisableChanged, ({ isDisable }) => {console.log('roomEngine.onSendMessageForAllUserDisableChanged', isDisable);});
Parameter | Type | Meaning |
isDisable | boolean | Allow Sending Text Message |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onUserVoiceVolumeChanged, ({ userVolumeList }) => {userVolumeList.forEach(userVolume => {console.log('roomEngine.onUserVoiceVolumeChanged', userVolume.userId, userVolume.volume);})});
Parameter | Type | Meaning |
userVolumeList | Array.<object> | Volume of all users in the room, including userId and volume information, volume range is 1-100 |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onUserNetworkQualityChanged, ({ userNetworkList }) => {userNetworkList.forEach(userNetwork => {console.log('roomEngine.onUserNetworkQualityChanged', userNetwork.userId, userNetwork.volume);})});
Parameter | Type | Meaning |
networkMap | Traverse Network Quality Level |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onSeatListChanged, ({ seatList, seatedList, leftList }) => {console.log('roomEngine.onSeatListChanged',seatList, seatedList, leftList);});
Parameter | Type | Meaning |
seatList | Seat List | |
seatedList | New Seat Information | |
leftList | Left Seat Information |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onKickedOffSeat, ({ userId }) => {console.log('roomEngine.onKickedOffSeat', userId);});
Parameter | Type | Meaning |
userId | String | Kicked off Seat User Id |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onRequestReceived, ({ request }) => {console.log('roomEngine.onRequestReceived', request);});
Parameter | Type | Meaning |
request | Request Received |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onRequestCancelled, ({ requestId, userId }) => {console.log('roomEngine.onRequestCancelled', requestId, userId);});
Parameter | Type | Meaning |
requestId | string | Request Id |
userId | string | User Id of Cancelled Request |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onReceiveTextMessage, ({ roomId, message }) => {console.log('roomEngine.onReceiveTextMessage', roomId, message);});
Parameter | Type | Meaning |
roomId | string | Room Id |
message | Receive Text Message |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onReceiveCustomMessage, ({ roomId, message }) => {console.log('roomEngine.onReceiveCustomMessage', roomId, message);});
Parameter | Type | Meaning |
roomId | string | Room Id |
message | Receive Text Message |
const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onDeviceChange, ({ deviceId, type, state }) => {console.log('roomEngine.onDeviceChange', deviceId, type, state);});
Parameter | Type | Meaning |
deviceId | string | Device Id |
type | Device Type | |
state | Device Change Status |
onUserScreenCaptureStopped
' event to modify the screen sharing status.const roomEngine = new TUIRoomEngine();roomEngine.on(TUIRoomEvents.onUserScreenCaptureStopped, () => {console.log('roomEngine.onUserScreenCaptureStopped', deviceId, type, state);});
Was this page helpful?