Skip to main content

DyteParticipants

This module represents all the participants in the meeting (except the local user). It consists of 4 maps:

  • joined: A map of all participants that have joined the meeting.
  • waitlisted: A map of all participants that have been added to the waitlist.
  • active: A map of active participants who should be displayed in the meeting grid.
  • pinned: A map of pinned participants.

module.exports ⏏

Kind: Exported class

new module.exports(self)

This constructs a new DyteParticipant object and maintains the maps of active/joined/waitlisted/pinned/selectedPeers maps.

ParamDescription
self: DyteSelf

module.exports.waitlisted

Returns a list of participants waiting to join the meeting.

module.exports.joined

Returns a list of all participants in the meeting.

module.exports.active

Returns a list of participants whose streams are currently consumed.

module.exports.pinned

Returns a list of participants who have been pinned.

module.exports.all

Returns all added participants irrespective of whether they are currently in the meeting or not

module.exports.pip

Return the controls for Picture-in-Picture

module.exports.roomJoined

Returns true if the local participant has joined the meeting.

module.exports.viewMode

Indicates whether the meeting is in 'ACTIVE_GRID' mode or 'PAGINATED' mode.

In 'ACTIVE_GRID' mode, participants are populated in the participants.active map dynamically. The participants present in the map will keep changing when other participants unmute their audio or turn on their videos.

In 'PAGINATED' mode, participants are populated in the participants.active map just once, and the participants in the map will only change if the page number is changed by the user using setPage(page).

module.exports.currentPage

This indicates the current page that has been set by the user in PAGINATED mode. If the meeting is in ACTIVE_GRID mode, this value will be 0.

module.exports.lastActiveSpeaker

This stores the participantId of the last participant who spoke in the meeting.

module.exports.selectedPeers

Keeps a list of all participants who have been present in the selected peers list.

module.exports.count

Returns the number of participants who are joined in the meeting.

module.exports.maxActiveParticipantsCount

Returns the maximum number of participants that can be present in the active map.

module.exports.pageCount

Returns the number of pages that are available in the meeting in PAGINATED mode. If the meeting is in ACTIVE_GRID mode, this value will be 0.

module.exports.acceptWaitingRoomRequest(id)

Accepts requests from waitlisted participants if user has appropriate permissions.

Kind: instance method of module.exports

ParamDescription
idpeerId or userId of the waitlisted participant.

module.exports.acceptAllWaitingRoomRequest()

We need a new event for socket service events since if we send them all together, sequence of events can be unreliable

Kind: instance method of module.exports

module.exports.rejectWaitingRoomRequest(id)

Rejects requests from waitlisted participants if user has appropriate permissions.

Kind: instance method of module.exports

ParamDescription
idparticipantId of the waitlisted participant.

module.exports.setViewMode(viewMode)

Sets the view mode of the meeting to either ACTIVE_GRID or PAGINATED.

Kind: instance method of module.exports

ParamDescription
viewModeThe mode in which the active map should be populated

module.exports.setPage(page)

Populates the active map with participants present in the page number indicated by the parameter page in PAGINATED mode. Does not do anything in ACTIVE_GRID mode.

Kind: instance method of module.exports

ParamDescription
pageThe page number to be set.

module.exports.disableAllAudio(allowUnmute)

Disables audio for all participants in the meeting.

Kind: instance method of module.exports

ParamDescription
allowUnmuteAllow participants to unmute after they are muted.

module.exports.disableAllVideo()

Disables video for all participants in the meeting.

Kind: instance method of module.exports

module.exports.disableAudio(participantId)

Deprecated

Kind: instance method of module.exports

ParamDescription
participantIdID of participant to be muted.

module.exports.disableVideo(participantId)

Deprecated

Kind: instance method of module.exports

ParamDescription
participantIdID of participant to be muted.

module.exports.kick(participantId)

Deprecated

Kind: instance method of module.exports

ParamDescription
participantIdID of participant to be kicked.

module.exports.kickAll()

Kicks all participants from the meeting.

Kind: instance method of module.exports

module.exports.broadcastMessage()

Broadcasts the message to all participants including self.

Kind: instance method of module.exports

module.exports.acceptAllRequestToJoinStageRequests()

Deprecated

Kind: instance method of module.exports

module.exports.getAllJoinedPeers()

Returns all peers currently present in the room If you are in a group call or webinar use meeting.participants.joined instead

Kind: instance method of module.exports

sidebar_position: ((sidebar_position)) web_core_version: ((web_core_version))


This module represents all the participants in the meeting (except the local user). It consists of 4 maps:

  • joined: A map of all participants that have joined the meeting.
  • waitlisted: A map of all participants that have been added to the waitlist.
  • active: A map of active participants who should be displayed in the meeting grid.
  • pinned: A map of pinned participants.

module.exports ⏏

Kind: Exported class

new module.exports(self)

This constructs a new DyteParticipant object and maintains the maps of active/joined/waitlisted/pinned/selectedPeers maps.

ParamDescription
self: DyteSelf

module.exports.waitlisted

Returns a list of participants waiting to join the meeting.

module.exports.joined

Returns a list of all participants in the meeting.

module.exports.active

Returns a list of participants whose streams are currently consumed.

module.exports.pinned

Returns a list of participants who have been pinned.

module.exports.all

Returns all added participants irrespective of whether they are currently in the meeting or not

module.exports.pip

Return the controls for Picture-in-Picture

module.exports.roomJoined

Returns true if the local participant has joined the meeting.

module.exports.viewMode

Indicates whether the meeting is in 'ACTIVE_GRID' mode or 'PAGINATED' mode.

In 'ACTIVE_GRID' mode, participants are populated in the participants.active map dynamically. The participants present in the map will keep changing when other participants unmute their audio or turn on their videos.

In 'PAGINATED' mode, participants are populated in the participants.active map just once, and the participants in the map will only change if the page number is changed by the user using setPage(page).

module.exports.currentPage

This indicates the current page that has been set by the user in PAGINATED mode. If the meeting is in ACTIVE_GRID mode, this value will be 0.

module.exports.lastActiveSpeaker

This stores the participantId of the last participant who spoke in the meeting.

module.exports.selectedPeers

Keeps a list of all participants who have been present in the selected peers list.

module.exports.count

Returns the number of participants who are joined in the meeting.

module.exports.maxActiveParticipantsCount

Returns the maximum number of participants that can be present in the active map.

module.exports.pageCount

Returns the number of pages that are available in the meeting in PAGINATED mode. If the meeting is in ACTIVE_GRID mode, this value will be 0.

module.exports.acceptWaitingRoomRequest(id)

Accepts requests from waitlisted participants if user has appropriate permissions.

Kind: instance method of module.exports

ParamDescription
idpeerId or userId of the waitlisted participant.

module.exports.acceptAllWaitingRoomRequest()

We need a new event for socket service events since if we send them all together, sequence of events can be unreliable

Kind: instance method of module.exports

module.exports.rejectWaitingRoomRequest(id)

Rejects requests from waitlisted participants if user has appropriate permissions.

Kind: instance method of module.exports

ParamDescription
idparticipantId of the waitlisted participant.

module.exports.setViewMode(viewMode)

Sets the view mode of the meeting to either ACTIVE_GRID or PAGINATED.

Kind: instance method of module.exports

ParamDescription
viewModeThe mode in which the active map should be populated

module.exports.setPage(page)

Populates the active map with participants present in the page number indicated by the parameter page in PAGINATED mode. Does not do anything in ACTIVE_GRID mode.

Kind: instance method of module.exports

ParamDescription
pageThe page number to be set.

module.exports.disableAllAudio(allowUnmute)

Disables audio for all participants in the meeting.

Kind: instance method of module.exports

ParamDescription
allowUnmuteAllow participants to unmute after they are muted.

module.exports.disableAllVideo()

Disables video for all participants in the meeting.

Kind: instance method of module.exports

module.exports.disableAudio(participantId)

Deprecated

Kind: instance method of module.exports

ParamDescription
participantIdID of participant to be muted.

module.exports.disableVideo(participantId)

Deprecated

Kind: instance method of module.exports

ParamDescription
participantIdID of participant to be muted.

module.exports.kick(participantId)

Deprecated

Kind: instance method of module.exports

ParamDescription
participantIdID of participant to be kicked.

module.exports.kickAll()

Kicks all participants from the meeting.

Kind: instance method of module.exports

module.exports.broadcastMessage()

Broadcasts the message to all participants including self.

Kind: instance method of module.exports

module.exports.acceptAllRequestToJoinStageRequests()

Deprecated

Kind: instance method of module.exports

module.exports.getAllJoinedPeers()

Returns all peers currently present in the room If you are in a group call or webinar use meeting.participants.joined instead

Kind: instance method of module.exports