You need to sign in to do that
Don't have an account?
Pedro H
Linking Third party social account with Auth.RegistrationHandler
Hello all,
we would like to link an existing Salesforce account to a social account (Google, Facebook,...) the first time the user uses this authentication provider. We don't want to use the "Existing User Linking URL" because it requires the user to be already looged in Salesforce.
I have seen in the documentation of the Auth.RegistrationHandler that the createUser method should return the User object that corresponds to the third party’s user information and may be a new user that hasn’t been inserted in the database or may represent an existing user record in the database.
To link the account we should use any attribute in the "Auth.UserData" to try to locate an existing user and return it in the createUser function. Is that correct?
Best regards.
we would like to link an existing Salesforce account to a social account (Google, Facebook,...) the first time the user uses this authentication provider. We don't want to use the "Existing User Linking URL" because it requires the user to be already looged in Salesforce.
I have seen in the documentation of the Auth.RegistrationHandler that the createUser method should return the User object that corresponds to the third party’s user information and may be a new user that hasn’t been inserted in the database or may represent an existing user record in the database.
To link the account we should use any attribute in the "Auth.UserData" to try to locate an existing user and return it in the createUser function. Is that correct?
Best regards.
Returns a User object using the specified portal ID and user information from the third party, such as the username and email address. The User object corresponds to the third party’s user information and may be a new user that hasn’t been inserted in the database or may represent an existing user record in the database.
Yes, that is what you want to use. You need to know the UserId beforehand.
Did you find any solution ? Let me know.
I am working on the same POC.