Identity functions (login | signup | validate ) are NOT run when using Google Provider

When the users sign-in using Google, none of the Identity Functions are run.

I want to update roles for the users based on the email they are using to sign in.

Netlify site name - https://sso-redirects.netlify.app/

If the Identity Functions are not supposed to run when signing in via an external provider, can someone please guide me on how to add roles to the JWT I can get via react-netlify-identity ?

It looks like you’ve either deleted or renamed your site. Could you tell me which site you’re having this issue on?

That said, one thing to note is that event-triggered functions does not show any logs in case that is where you are checking for invocation.

Hey Dennis,

The site was never deleted or renamed.

I had also raised a bug with the support and got a reply from Chris Mccraw.

It’s true - there is a bug in that we do not fire those functions when used with 3rd party authentication services.

You can instead use this workflow to work around the bug:

  1. rename each of the functions to something different than our event-triggered naming scheme
  2. redeploy them with this rename
  3. change your identity settings (here: Netlify App) to those functions you just renamed: Netlify App
  4. I think they will work for all auth providers

I just tried the workaround and it is working alright.

1 Like

I’ve confirmed this as well in another thread with Raymond Camden but could you link to where Chris posted that, @chinmay.chaudhary?


Jon

Hello Jon,

I had received an email from Chris. It looks like the ticket is already closed but if it is of any help, the support ticket number was #35260.