79608890

Date: 2025-05-06 14:15:15
Score: 1
Natty:
Report link

I've been through something similar today. With the help of ChatGPT (which was not around 2 years ago haha), I think I got some answers... but, yeah, it's weird and it does not make a lot of sense.

Using the google_sign_in Flutter package on Android, when you provide a clientId, it overrides the behavior and ignores the google-services.json file. So, if you go the road of downloading the google-services.json file from Firebase, then do not provide a clientId.

The thing is that I did not want to use Firebase in my use case. So, how do I provide the necessary context to the package if I cannot provide a client id? And, I don't understand why that does not work because that's precisely what I did on iOS. Here is a working version:

Here's how ChatGPT summarized it for me:

Even if the Android Client ID isn't directly used in the app, registering it in the Google Cloud Console (with the correct package name and SHA-1 certificate) ensures that Google's authentication services recognize the app.

Maybe it made that up, I don't know, but the important part is that it works!

Reasons:
  • Blacklisted phrase (1): how do I
  • Blacklisted phrase (0.5): I cannot
  • Long answer (-1):
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • Low reputation (0.5):
Posted by: Jordan