Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

'Your app is missing support for the following URL schemes: com .googleusercontent.apps.xxx'

I found the question and answer in many times but no one from that help me :( . Anyone can you please help me?

<key>CFBundleURLTypes</key>
<array>
    <dict>
        <key>CFBundleTypeRole</key>
        <string>Editor</string>
        <key>CFBundleURLSchemes</key>
        <array>
            <string>http://com.googleusercontent.apps.241222885422-bquei744e1i8q3h0r82k7fm31fbuej7m</string>
        </array>
    </dict>
    <dict>
        <key>CFBundleTypeRole</key>
        <string>Editor</string>
        <key>CFBundleURLSchemes</key>
        <array>
            <string>sixsquarepc08.GoogleIntegration</string>
        </array>
    </dict>
</array>

This is my info.plist.

These are some questions that I referred,

  • App getting crash when click on GoogleSignIn button
  • https://github.com/googlesamples/google-services/issues/81
  • https://medium.com/codespace69/ios-login-google-crash-your-app-is-missing-support-for-the-following-url-schemes-d0e0ede1c01f
like image 620
Angel F Syrus Avatar asked Jun 21 '18 04:06

Angel F Syrus


5 Answers

You can add your "URL scheme" in "URL types"

enter image description here

like image 171
Chirag Kothiya Avatar answered Nov 15 '22 02:11

Chirag Kothiya


Sorry to all, That was my mistake...There is an unwanted space I put there while declaring googleClienId in AppDelegate(GIDSignIn.sharedInstance().clientID = "241222885422-bquei744e1i8q3h0r82k7fm31fbuej7m.apps.googleusercontent.com ").The space after ".com" was my problem.It should be ( GIDSignIn.sharedInstance().clientID = "241222885422-bquei744e1i8q3h0r82k7fm31fbuej7m.apps.googleusercontent.com")like this. Please be sure that you entering the clientId in proper way.

like image 41
Angel F Syrus Avatar answered Nov 15 '22 02:11

Angel F Syrus


Just solved it, in the appDelegate you should add the right url scheme starting with the address and then the numbers ,and not the other way around.

Try this one,

AppDelegate(GIDSignIn.sharedInstance().clientID = "apps.googleusercontent.com.241222885422-bquei744e1i8q3h0r82k7fm31fbuej7m")
like image 21
Shy Attoun Avatar answered Nov 15 '22 03:11

Shy Attoun


Google Sign-In requires a custom URL Scheme to be added. CFBundleURLSchemes is missing from your info.plist.

I experienced the same issue with my Flutter app and solved it with these steps:

  1. From your project folder, go to ios > Runner > GoogleService-Info.plist, copy the REVERSED_CLIENT_ID starting with .com 2.Right click iOS folder > 'Open in Xcode'
  2. Runner (Top folder in the grey panel) -> Runner (In the white panel below Targets), Info -> URL Types.
  3. Click the + button and paste your reversed client ID as a URL scheme. For example com.googleusercontent.apps.1234567890-abcdefg

screenshot of the xcode Runner Info section

like image 43
Sharon Avatar answered Nov 15 '22 02:11

Sharon


Add the CFBundleURLTypes attributes below into the [my_project]/ios/Runner/Info.plist file.

<key>CFBundleURLTypes</key>
<array>
    <dict>
        <key>CFBundleTypeRole</key>
        <string>Editor</string>
        <key>CFBundleURLSchemes</key>
        <array>
            <!-- TODO Replace this value: -->
            <!-- Copied from GoogleService-Info.plist key REVERSED_CLIENT_ID -->
            <string>com.googleusercontent.apps.861823949799-vc35cprkp249096uujjn0vvnmcvjppkn</string>
        </array>
    </dict>
</array>

See: https://pub.dev/packages/google_sign_in#ios-integration

like image 40
Yndira Inciarte Avatar answered Nov 15 '22 02:11

Yndira Inciarte