-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integrate facebook/google login to userpool #565
Comments
You can integrate facebook/google login to an identity pool through the federated options in the Amplify Auth API. I don't think Amplify supports connecting it to a user pool yet. |
You should check https://github.com/aws/amazon-cognito-auth-js/. But it's not perfect too, achieving this with Cognito is either poorly documented / undocumented or currently broken. Looking for a solution as well |
I think that I'm struggling with this still too though. I see in the docs here that |
Did you find a solution? |
I think item 1 is a commonly needed feature for a web app (though Item may be a bit advance and not necessarily needed by every web app), has it been supported by Amplify?
|
It seems that using the 'hosted web UI' we can enable federated social logins with just a userpool, no identity pool required. Though as best I can dig my way through the Amplify documentation, the built in UI components only allow federated login against an identity pool. It would be nice if AmplifyJS could support this same method (or if it already can, updated documentation on how to) The following links speak more generally to how to link a Social (federated) login with a user in the user pool (assuming they haven't logged in with that social login before)
|
Any update about this? My final goal is to know who call my Lambda (with API GW) to adapt rules please |
Hello ? it is true that react components only work with identity pool ? I need the users registered when login from social media,. |
I have the same requirement as @mickadoua which is to use the cognito integration on API gateway and know who is calling the API, but allow users to sign in with Facebook. I don't see a way to do this through the SDK. |
Can anyone give an update on this thread? |
@anuradhawick Did you find any solution for the |
@hakimio actually No. I made a workaround my self by handling the error from front end. You can have a look at this. https://github.com/anuradhawick/vinly-search/blob/master/viny-site/src/app/shared-modules/auth/auth.service.ts If it fails with Google, we can force signup with Facebook and vice versa. (You can give a custom message and proceed). For me this is the best way as I deal with senior users. However. from back-end I make the record in DB and Userpools that they have both FB and Google accounts so in future there won't be an error. Did you have anything else in mind? The way to go could be failing first followed by user logging in with original account and later link the new social account. |
@anuradhawick Thanks for sharing your solution. In our case we have admin added users to Cognito user pool, then in It seems to be well known Cognito issue, but it doesn't seem like it's a high priority issue for AWS devs. I think for now we'll just retry on error as well, since there is not much else to do. |
Did anyone resolve this issue? |
@Amaanuddin The only "solution" is to just retry when you get |
@hakimio do you mean by retrying to retry the complete auth flow? Because this means the end user will see the Social Provider authentication popup/window twice on the first attempt. Kinda sucks and is bad UX. |
@tvb The second time the user won't have to confirm or select anything unless he is using incognito mode. He will only see the browser page reloading. |
Hmm, I need to look into it again I guess, as I thought a reload wasn’t enough to get it working |
It's still not working and I can't see how it can be handled without promoting the login screen again. |
@mrgoos redirectToGoogleLogin(): void;
getTokens(): Observable<AuthenticationTokens | null>; Should be possible to do something similar for Facebook as well. |
Thanks @hakimio but Im using SAML so the IDP could be anything for me. |
I'm struggling with this too still. I think we should ask the Cognito team to look into this, however I have no paid AWS Support subscription yet. |
@tvb They've known about this issue at lease since 2017 but they haven't done anything about it. They just don't seem to care. |
Uhh
But they do allow, just only for one IDP. If you link multiple it will break.. |
Turns out the the hot fix by presenting the social login screen again only works with Google 😭 |
This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs. Looking for a help forum? We recommend joining the Amplify Community Discord server |
Hi guys,
Anybody out there know how to integrate facebook/google login to userpool ? Can you provide a detailed instruction? I've been struggled with this issue for the past few months now. I can't find any documentation on how to merge it properly.
Below are some of the use case scenario that i want to happen in my app.
If this plugin doesn't support the integration of social media account provider to userpool, is there any other way or workaround to make it happen to my app? I did a research about this one, and still some developer still got no luck.
The text was updated successfully, but these errors were encountered: