Is there anyway to check entered mobile number in login activity is already registered with firebase before generating OTP? If not registered, I want to goto signup activity
There is no API in the Firebase Authentication Android SDK to check if a phone number is already in use. I'm not sure why that is actually, so it might be worth filing a feature request.
The only place such an API currently exists in the Firebase Admin SDK, which is designed to be used in a trusted environment such as a server you control, or Cloud Functions. For more on this API, see the reference documentation.
You'll have to wrap this call in an endpoint you can call from your Android code. The simplest way to do this right now is with a so-called Callable Function. But this is still quite involved, so only go this path if you're comfortable with the technologies used.