Skip to main content

DyteClient

The DyteClient class is the main class of the web core library. An object of the DyteClient class can be created using await DyteClient.init({ ... }). Typically, an object of DyteClient is named meeting.

meeting.participants

The participants object consists of 4 maps of participants, waitlisted, joined, active, pinned. The maps are indexed by peerIds, and the values are the corresponding participant objects.

Kind: instance property of DyteClient

meeting.self

The self object can be used to manipulate audio and video settings, and other configurations for the local participant. This exposes methods to enable and disable media tracks, share the user's screen, etc.

Kind: instance property of DyteClient

meeting.meta

The room object stores information about the current meeting, such as chat messages, polls, room name, etc.

Kind: instance property of DyteClient

meeting.plugins

The plugins object stores information about the plugins available in the current meeting. It exposes methods to activate and deactivate them.

Kind: instance property of DyteClient

meeting.chat

The chat object stores the chat messages that were sent in the meeting. This includes text messages, images, and files.

Kind: instance property of DyteClient

meeting.polls

The polls object stores the polls that were initiated in the meeting. It exposes methods to create and vote on polls.

Kind: instance property of DyteClient

meeting.remote

The remote object stores the remote control requests for the meeting. It exposes methods to request, accept and end the remote control.

Kind: instance property of DyteClient

meeting.joinRoom()

The joinRoom() method can be used to join the meeting. A roomJoined event is emitted on self when the room is joined successfully.

Kind: instance method of DyteClient

meeting.leaveRoom()

The leaveRoom() method can be used to leave a meeting.

Kind: instance method of DyteClient

meeting.init(options)

The init method can be used to instantiate the DyteClient class. This returns an instance of DyteClient, which can be used to perform actions on the meeting.

Kind: static method of DyteClient

ParamDescription
optionsThe options object.
options.roomNameThe name of the room.
options.authTokenThe authorization token received using the API.
options.apiBaseThe base URL of the API.
options.defaultsThe default audio and video settings.