When you just starting with Firebase Authentication and Flutter, you might get an error: “An internal error has occurred, print and inspect the error details for more information.” This is most likely the problem with not enabling ‘Sign-in provider’.
For example, if you trying to authenticate a user via the phone number, you should also make sure that you enabled Phone verification in Firebase console. Here are simple steps to resolve the issue.
Solution: Turn on phone option in sign-in provider
To solve this issue, make sure that you turned on a phone option in Firebase Console / Authentication / Sign-in method. You can see the image below: