Welcome to the new Daily Docs. Please let us know what you think.

Participant Events

You might also want to monitor for events that happen to a specific participant on a call. This group of events is emitted when a participant joins or leaves a call, or when something about the participant has changed, like their audio or video track status.

See participants() for details on the information that the participants object returns for each participant property.

participant-joined

Compatibility:
Prebuilt
Custom

Fires when a new remote participant has joined the call. The participant property includes all available information about who joined, like whether or not their audio is on.

See participants() for more information on the participant property.

Note: this event may arrive for a remote participant before the local joined-meeting event fires.

participant-updated

Compatibility:
Prebuilt
Custom

Emitted when a local or remote participant's state changes.

The event object's participant property contains all the available information about the participant.

See participants() for more information on the participant property.

participant-left

Compatibility:
Prebuilt
Custom

A remote participant leaves the call.

The event's participant property contains all of the available information about the participant just before the participant disconnected.

See participants() for more information on the participant property.

waiting-participant-added

Compatibility:
Prebuilt
Custom

A participant has been added to the waitingParticipants() set.

Payload object:

waiting-participant-updated

Compatibility:
Prebuilt
Custom

A participant in the waitingParticipants() set has updated details (right now, this just indicates a name change).

Payload object:

waiting-participant-removed

Compatibility:
Prebuilt
Custom

A participant has been removed from the waitingParticipants() set.

Payload object:

app-message

Compatibility:
Prebuilt
Custom

This event fires when somebody broadcasts a message to other participants in the call via the sendAppMessage() method.

The event object returns information about the participant who broadcast the message, and also the data they sent. The data they sent is always in the form of a JavaScript object that can be serialized into JSON.

Messages are not sent to the person who sends the message, and they are not stored. If a participant joins a call after a message is sent, they will never see it.

Calling this method and listening for the event could be used to build out a custom chat UI, or to implement a "Raise Your Hand" feature, for example.

track-started

Compatibility:
Prebuilt
Custom

Fires when a participant's audio or video track begins.

The event object returned includes a MediaStreamTrack object and information about the participant whose track started.

track-stopped

Compatibility:
Prebuilt
Custom

Fires when a participant's audio or video track stops.

The event object returned includes a MediaStreamTrack object and information about the participant whose track stopped.

lang-updated

Compatibility:
Prebuilt
Custom

lang-updated fires after the setDailyLang() method is called to update the call's language setting.

The payload includes two values: lang and langSetting. lang is the language currently in effect. langSetting is the value the user explicitly specified (e.g. via setDailyLang()) that resulted in that language ultimately being set. For example, if you call setDailyLang('en'), both your lang and your langSetting will be 'en'. If you call setDailyLang('user'), where 'user' is a special language setting that instructs Daily to use the user's browser's language preference, then langSetting will be 'user' and lang will be the language chosen based on the browser setting: 'en', 'fr', 'pt', or any other Daily-supported language.