Auth0 Home Blog Docs

Lock "Sign Up with Google" option not working

lock
google
tier1

#1

Im usign Lock to log in to my Angular 2 application and have already tried Facebook and Twitter options to log in without problem, but when i add Google log in it never shows:

  lock = new Auth0Lock(
    AUTH_CONFIG.clientID,
    AUTH_CONFIG.domain, {
      autoclose: true,
      allowedConnections: 'Username-Password-Authentication', 'google-oauth2' ],
      language: 'es',
      theme: {
        logo: 'http://wolla.com.ar/files/brand/colored-03.png',
        primaryColor: '#31324F'
      },
      allowSignUp: false,
      languageDictionary: {'title': 'Wolla' },
      auth: {
        redirectUrl: CALLBACK_URL,
        responseType: 'token id_token',
        params: {
          scope: 'openid user_metadata'
        }
      }
    });

Also if i go to Codepen in your page : https://codepen.io/pen?&editors=001 it says there was an error and never shows the Lock pop up.

Thanks in advance!


#2

There are several places where you need to verify that Google social connection is enabled for the client you are using:

1- Go to dashboard, and click the Connections> Social and verify Google is enabled.

2- Click Clients, select the client you are currently using from the client list, then select the Connections tag and verify ‘google-oauth2’ is enabled for this client.

3- Lock initialization:

var options = {
languageDictionary: {
title: “My app”
},
allowedConnections: ‘twitter’, ‘google-oauth2’, ‘Username-Password-Authentication’]
};

If everything is configured properly, the expected output should be as follows:

![alt text][1]


#3

Thanks! I needed to Configure Client Connections!

Regards,


#4