Google Identity Toolkit Does Not Receive Client Login ID

I use the Google Identity Toolkit for federated login in my iOS 9 compatible application. I recently updated all frameworks and libraries and started using Cocoapod for dependency management. Now that the Facebook login is working fine, when the user enters the "log in using Google" button, the following error is issued:

*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'You must specify |clientID| for |GIDSignIn|' 

The configuration code in my AppDelegate, where I set the client ID, is as follows:

  - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { GITClient *gitkitClient = [GITClient sharedInstance]; gitkitClient.apiKey = GITKIT_API_KEY; gitkitClient.widgetURL = GITKIT_WIDGET_URL; gitkitClient.providers = GITKIT_PROVIDERS; [GPPSignIn sharedInstance].clientID = GOOGLE_CLIENT_ID; ...various unrelated code... } 

Any guidance would be truly appreciated.

+8
ios ios9 google-signin google-identity-toolkit
source share
3 answers

The answer was virtually completely unrelated to the code configuration, and it seems likely that there was a Google-end error. A new update was released, so a few weeks later a simple pod update fixed the problem.

0
source share

As explained in https://developers.google.com/identity/toolkit/ios/quickstart#step_3_set_up_the_quick-start_app , you need to initialize [GIDSignIn sharedInstance].clientID :

  GITClient *gitkitClient = [GITClient sharedInstance]; gitkitClient.apiKey = GITKIT_API_KEY; gitkitClient.widgetURL = GITKIT_WIDGET_URL; gitkitClient.providers = @[ kGITProviderGoogle ]; [GIDSignIn sharedInstance].clientID = GOOGLE_CLIENT_ID; 
+1
source share

Did you skip this step → Add URL schemes to your project ?

Find it at https://developers.google.com/identity/sign-in/ios/start-integrating

It has URL schemes that need to be configured. Client ID is one of them.

0
source share

All Articles