Hi this might be duplicate to this question. But I did not find right answer for this. I have developed an app like zello push to talk using react-native. I want to play the audio message automatically without any user interaction when the app is in background or killed. Whenever any user sending real time audio message, I am sending a push notification to ios app and after receiving notification I am invoking a function which establishes socket connection with the webrtc server and then join in the room in which webrtc audio broadcasting is happening. Now I checked that socket is connected and also joining in room successfully done after receiving push notification when app is in background. But there I could not hear any audio and received following error message.
AURemoteIO.cpp:1668 AUIOClient_StartIO failed (561145187)
Then I have set AVAudioSessionCategoryPlayback and that error gone. But this time also did not hear any audio sound. The app is working fine when it is in foreground. I am using react-native and this is happening for IOS app only. Any help is appreciated. In xcode I have enabled push-notifications, background-fetch, background-airplay etc.