0

I'm trying to record audio on website of mine the website is like sarahaha you share your link on the social media ex: Facebook and messenger and get feedback by voice message

https://www.atklem.com/users/MohamedDeux/08d68eb1-e5a4-9572-bd40-08777437c2b8

This is the kind of links that users share to their friends

I'm thinking that facebook is using Custom Chrome Tab to open the link instead of the native chrome app

my problem: we can't record audio in this custom tab because of not getting the permission dialog to Allow recording audio (get user Media)

we currently using RecordRTC js library How can we solve this problem ?

thanks

WizKid
  • 4,888
  • 2
  • 23
  • 23

1 Answers1

0

currently on android the original app must give chrome custom tap permissions to access microphone like this

mWebView.setWebChromeClient(new WebChromeClient() {
    @Override
    public void onPermissionRequest(PermissionRequest request) {
        request.grant(request.getResources());
    }
});

i believe facebook app doesn't do so and it does not work on ios too.

see this

https://github.com/BasqueVoIPMafia/cordova-plugin-iosrtc/issues/250#issuecomment-336240953