How do I enable "Call via device Audio" automatically

I am using Android SDK for Zoom integration and I join a zoom meeting using MeetingService.handZoomWebUrl.
Although before joining a meeting, I do not want to give the user the popup to select an Audio device, and it should enable the “Call via Device Audio” option by default. Is there any param that I should pass in the URL so that this happens automatically.

Hi @karthik.rt_01, thanks for using the devforum.

Looking at our Client URL Scheme documentation, there does not appear to be a query parameter that will allow you to join with audio turned on. Your only option would be to enable it programmatically after successfully joining the meeting with the following code:

ZoomSDK.getInstance().getInMeetingService().getInMeetingAudioController().connectAudioWithVoIP();

Thanks!

When is the proper time to call this function? Is immediately after joinMeeting too early?

Hi @joek,

You would only be able to join meeting audio after successfully joining a meeting. Since joinMeeting starts an asynchronous process, calling connectAudioWithVoIP immediately after creates a race condition which may not be met by the time you attempt to connect to audio.

To ensure you have successfully joined the meeting before connecting to audio, please listen to the onMeetingStatusChanged callback within MeetingServiceListener:

@Override
 public void onMeetingStatusChanged(MeetingStatus meetingStatus, int i, int i1) {
    if (meetingStatus == MeetingStatus.MEETING_STATUS_INMEETING) {
        // You have successfully joined the meeting
    }
}

Thanks!

Thank you so much after reading all the discussions my problem has been solved. Thank you, Sir/ma’am.

Hi @rehnsaeed08, thanks for using the dev forum.

I’m really happy to hear that we were able to solve your issue! Please don’t hesitate to reach back out if you encounter any other problems using our SDKs. :slightly_smiling_face:

Thanks!

This helps thanks! I assume it’s the same for iOS?

Hey @joek,

There is not a direct equivalent to connectAudioWithVoIP on iOS. However, you can set your audio type to VoIP by changing the audioType property within MobileRTCAudioStatus to MobileRTCAudioType_VoIP for the user. Then you can call connectMyAudio.

The onMeetingStateChange is available on iOS as well, however.

Thanks!
Michael

For iOS can I just call [[[MobileRTC sharedRTC] getMeetingSettings] setAutoConnectInternetAudio: YES]; ?

From the documentation it seems like I could just call this and it should connect automatically.

Hey @joek,

The call

[[[MobileRTC sharedRTC] getMeetingSettings] setAutoConnectInternetAudio: YES];

will turn on the AutoConnectInternetAudio meeting setting. Which will connect the users’ audio via the internet when they join. The behavior is slightly different than that in my comment but yes this should work for your use case :slight_smile:

Thanks!
Michael