I am little bit confused about the right flow of the phone authentication. I have noticed there is couple of scenarios that I cannot reproduce due to reason I can not comple
I cannot reproduce due to reason I can not completely delete my user from Firebase
-> Yes you can. have a look at image.
Answer of Question 1: -> It is not. SMS is obviously relevant. without SMS, phone-authentication will not work.
Answer of Question 2:
-> onVerificationCompleted will be called every-time.
Answer of Question 3:
-> Yes. onCodeSent is not being called every-time.
Answer of Question 4:
-> You do not need OTP in onCodeSent method. We can get verificationId and PhoneAuthProvider.ForceResendingToken in onCodeSent. we need to save verificationId in a variable. and use it while authentication user entered OTP.
PhoneAuthCredential credential = PhoneAuthProvider.getCredential(mVerificationId, YouEditTextValueString);
My opinion:
I had also these questions in my mind when I worked first time on it. I experienced that if we use same device with same phone-number, SMS is not coming and I guess Firebase or google-play-service handle it.
Somehow right-now I am receiving SMS every time for the same device and phone-number.
but we don't need to care about it.