Is there a way to disable the mic of a participant in a call or meeting using the API?

Tom Brown 6 Reputation points
2022-10-12T13:02:40.39+00:00

Is there a way to enable/disable an individuals mic through the API (like you can as presenter in an online meeting using the UI)?

There is a participant mute but not exactly what we need.

Thanks

Microsoft Teams | Development
Microsoft Security | Microsoft Graph
0 comments No comments
{count} vote

2 answers

Sort by: Most helpful
  1. Shivam Dhiman 6,081 Reputation points
    2022-10-12T22:29:59.677+00:00

    Hi @Tom Brown

    While creating onlineMeeting you can use property "allowAttendeeToEnableMic" to disable mic for attendees. By default mic is enabled and value is true.
    You need to pass false, as this property require Boolean value to disable mic for attendees. Please refer to the below sample screenshot

    249790-disable.png

    Result:
    249779-mic.png

    Hope this helps.

    If the answer is helpful, please click Accept Answer and kindly upvote. If you have any further questions about this answer, please click Comment.


  2. Priyank Dhameliya 1 Reputation point
    2022-10-19T13:09:02.74+00:00

    You may refer this graph call - graph/api/participant-mute

    In here you need to pass - clientContext, participant id, and call id which you might get from contextAPI call from graph.

    ----------

    const options = {
    authProvider,
    };

    const client = Client.init(options);

    const muteParticipantOperation = {
    clientContext: 'd45324c1-fcb5-430a-902c-f20af696537c'
    };

    await client.api('/communications/calls/57dab8b1-894c-409a-b240-bd8beae78896/participants/2765eb15-01f8-47c6-b12b-c32111a4a86f/mute')
    .post(muteParticipantOperation);

    ----------

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.