Skip to main content
updateParticipants(updates) Modifies multiple participants at once. Internally loops over the keys of updates and calls updateParticipant() for each. Use this instead of calling updateParticipant() in a loop — changes are batched together, making updates faster.

Parameters

updates
{ [sessionId: string]: DailyParticipantUpdateOptions }
required
An object whose keys are participant session IDs and whose values are the update options for each participant. See updateParticipant() for all available actions.Use '*' as a key to apply the same update to all current participants at once.

Return value

Returns this (the DailyCall instance) for chaining.

Examples

// Mute all participants using '*'
call.updateParticipants({ '*': { setAudio: false } });
// Apply different updates to specific participants
call.updateParticipants({
  'session-id-1': { setAudio: false },
  'session-id-2': { setVideo: false },
});

See also