Skip to navigation

demote

  • demote(params): Promise<void>
Deprecated

Audience participants are deprecated and will be removed, along with promoting and demoting members between the audience and member roles. Don’t use them in new applications: join every participant as a member.

Demotes a participant from “member” to “audience”. See join and promote.

Parameters

params
object

Object containing the parameters of the method.

memberId
string

Id of the member to affect. If omitted, affects the current member.

mediaAllowed
"all" | "audio-only" | "video-only"

Specifies the media that the client will be allowed to receive. An audience participant cannot send any media.

Returns

Promise<void>

Permissions

  • room.member.demote

You need to specify the permissions when creating the Video Room Token on the server side.

Example

await roomSession.demote({
memberId: "de550c0c-3fac-4efd-b06f-b5b8614b8966",
mediaAllowed: "all",
});