Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Custom scheme URIs are not allowed for 'Web' client type - Google with Firebase

I am trying to implement google sign in using firebase in to my iOS app. I follow this tutorial. https://firebase.google.com/docs/auth/ios/google-signin I have setup the iOS app in firebase and use the google clientID and reversedClientID from the dowloaded GoogleService-Info.plist.

FYI: I have a custom sign-in button instead of the google sign in button. Anyway when i click the sign in button, google following error display in a webview.

enter image description here

I know my problem is the same as which described in this question.

Google 400 Error: invalid request Custom scheme URIs are not allowed for 'Web' client type

But, in my case, I have created the app in Firebase still I get the error. Any idea please...

like image 749
smartsanja Avatar asked Mar 28 '17 04:03

smartsanja


1 Answers

The first step is to check if you have already the OAuth 2.0 ID for iOS. To do this please open the Credentials page in the API Console. I hope you will find iOS client for your application under OAuth 2.0 client IDs section. If not, please follow this Guide The second step is to replace the Web Client ID with in iOS Client ID from OAuth 2.0 client IDs section. To do this, you should open the GoogleService-Info.plist and modify following keys: CLIENT_ID with [value].apps.googleusercontent.com and REVERSED_CLIENT_ID with com.googleusercontent.apps.[value].

like image 149
Valeriy Kliuk Avatar answered Nov 10 '22 19:11

Valeriy Kliuk