Cakedc users social login with google gmail

Hi,

I want to use cakedc users with something like google imap. I need to start a new request oauth with scope https://mail.google.com but when return to /auth/google it seems the accestoken is not saved to the database. Anyone have any idea how is best to handle this? I want to launch the request from a separate controller then login.eg MailController. Then the user can authorize access to gmail,… anyone have an example of how to do it?

greets

Hello
I could see that you are trying to implement social login with Google using CakeDC Users and Google IMAP. If the access token isn’t being saved to the database after returning to /auth/google, there might be an issue with how the token is handled or stored.

One approach you could try is to launch the OAuth request from a separate controller, such as MailController, and then handle the login process separately. You might need to store the access token in a session variable or pass it as a parameter to the login process.

For examples or further guidance, you might want to check the CakeDC Users documentation or community forums for code samples or discussions on similar implementations.

hi thanks I ended up using the google api client, saving the tokens to the session…