简体   繁体   English

AWS Cognito链接用户帐户

[英]AWS Cognito linking user accounts

When user bob@example.com logs in via. 当用户bob@example.com登录时。 user-pool (where email is username alias) he get's cognito-id-a, if he logs in via. user-pool(其中email是用户名别名)如果他登录via,他会获得cognito-id-a。 google he gets cognito-id-b 谷歌他得到了cognito-id-b

But to link these 2 ids I understand from the document that the api has to be invoked by supplying both the login token as part of the request. 但是为了链接这两个ID我从文档中理解,必须通过提供登录令牌作为请求的一部分来调用api。 But for both the logins to co-exists the user should log-in on both the providers at the same time (ie one after the other in the same session). 但是对于要共存的登录,用户应该同时登录两个提供者(即在同一会话中一个接一个地登录)。 Could someone explain the step-by-step flow of how this could be achieved. 有人可以解释如何实现这一目标的逐步流程。

Thanks in advance, 提前致谢,

You're correct, at one point they do have to be used together for some identity. 你是对的,有一点他们必须一起使用才能获得一些身份。 After that first call with both tokens, using any one token linked to that identity is sufficient. 在使用两个令牌进行第一次调用之后,使用链接到该身份的任何一个令牌就足够了。 The Cognito developer guide has more details on the flow, if needed. 如果需要,Cognito 开发人员指南可提供有关流程的更多详细信息。

As far as examples, the Cognito sample apps on GitHub would be a useful starting point. 就例子而言,GitHub上的Cognito 示例应用程序将是一个有用的起点。 Each sample supports logging in with multiple providers. 每个示例都支持使用多个提供程序登录。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM