Need phone number authentication

Hello guys I wondered if there is method or any way to use firebase number authentication service in mit app Inventor like in kodular,

I really searched a lot and found some some not effective solutions ,

What I need is way or extension like in kodular to sign up and sign in phone number with OTP

I I'll be grateful if anyone helps me in this issue

Thanks.

Not available at this time maybe next update to available

https://community.appinventor.mit.edu/search?q=Otp

Try the first search return guide

He Was Saying Like Kodular

and you know something ?

I am not sure but one post available on kodular & App inverter community

You are possibly looking at a year minimum, if not years....

work with what is available now.

I found a couple of solutions, but they were not very effective. For example, one solution involved using HTML and JS through a web viewer, but there were issues with signing up and the Captcha kept appearing repeatedly.


Another solution involved using an API and assuming that the phone number was already verified. However, this may not be a feasible option for everyone.


It would be helpful if there were an update to include this method in MIT App Inventor.

I have not observed these issues in my tests with my solution. perhaps you can provide your aia project / blocks and code where this is happening?

@TIMAI2 this is what I mean by repeating

Yes, the catchpa element appears to be broken. I will see if I can fix it. Thank you for reporting.

Thanks for your help

I have made a change and it works for me, with a test number and my own real mobile number. This was tested in an aia project using a webviewer with companion app on Android 13. Also tested in Chrome browser on my computer.

In the html file find this section:

      // Create a Recaptcha verifier instance globally
      // Calls submitPhoneNumberAuth() when the captcha is verified
      window.recaptchaVerifier = new firebase.auth.RecaptchaVerifier(
        "recaptcha-container",
        {
          size: "normal",
          callback: function(response) {
            submitPhoneNumberAuth();
          }
        }
      );

and change the word normal to invisible.

      // Create a Recaptcha verifier instance globally
      // Calls submitPhoneNumberAuth() when the captcha is verified
      window.recaptchaVerifier = new firebase.auth.RecaptchaVerifier(
        "recaptcha-container",
        {
          size: "invisible",
          callback: function(response) {
            submitPhoneNumberAuth();
          }
        }
      );

In some situations no recaptcha is required, in others a recaptcha is offered.

I will update my guide accordingly.

Now it shows the captcha but there's no code was sent to my number i tested it on chrome browser

Are you testing with a real mobile phone number or a test number from the firebase console?

I tested it with two real phone numbers and there's no code sent to both of them
It works with tested number from the console with placed manual code but when i try real number it doesn't send any code

Hmmm

Not sure what else to suggest, given that it works OK for me here, on my real phone with a real number.
Probably needs other testers to try to pinpoint the problem?

Have you tried in a compiled app ?

Ok no problem don't worry I will check it again
Thank you again @TIMAI2