Ramsai
Ramsai•11mo ago

Display the IDP accounts linked to the users

If a user has two different IDPs with the same email (Say Google and Microsoft) and the user logs in to the application using either of them, we want to display the IDPs that are linked to the user's email in the application. Is there any endpoint to check all the IDPs linked to an user? We were able to know if the user has IDP linked to his/her account using https://$CUSTOM-DOMAIN/v2/users/:userId/authentication_methods, but how can I know if the user has Google and Microsoft linked to his/her account. Thanks
7 Replies
fabienne
fabienne•11mo ago
If you want to get it for the currently authenticated user you can user the following query: https://zitadel.com/docs/apis/resources/auth/auth-service-list-my-linked-id-ps
ZITADEL Docs
Returns a list of all linked identity providers/social logins of the user. (e. Google, Microsoft, AzureAD, etc.)
fabienne
fabienne•11mo ago
If you want to query it as an administrator for a user you can use the following: https://zitadel.com/docs/apis/resources/mgmt/management-service-list-human-linked-id-ps
ZITADEL Docs
Returns a list of all linked identity providers/social logins of the user. (e. Google, Microsoft, AzureAD, etc.).
Ramsai
RamsaiOP•11mo ago
For both the endpoints I am only getting the idpID in the response but there is no idpName as mentioned in the document.
No description
Ramsai
RamsaiOP•11mo ago
Could you please check this out @fabienne 🙂
fabienne
fabienne•11mo ago
It looks like this is bug, can you open a bug report in the zitadel repository?
Ramsai
RamsaiOP•11mo ago
Ok sure, will do that
fabienne
fabienne•11mo ago
thanks

Did you find this page helpful?