Earmuff a Call Member

This guide covers earmuffing a call. Before you begin, make sure you added the SDK to your app and (Android, iOS, JS) and you are able to make or receive calls.

Earmuff

Earmuff stops the call member from hearing other members.

//Enable earmuff myself (can not hear others)
// After creating a session
client.enableEarmuff(callId)
    .then(() => {
        console.log("Success enabling earmuff.");
    })
    .catch(error => {
        console.error("Error enabling earmuff: ", error);
    });

Disable Earmuff

Disabling earmuff allows a previously earmuffed call member to hear other members.

//Disable Earmuff (can hear others)
// After creating a session
client.disableEarmuff(callId)
    .then(() => {
        console.log("Success disabling earmuff.");
    })
    .catch(error => {
        console.error("Error disabling earmuff: ", error);
    });

Reference