AWS使用刷新令牌Javascript

时间:2017-08-03 02:57:50

标签: amazon-web-services amazon-cognito refresh-token

是否有关于如何使用刷新令牌在aws cognito上获取新idtoken的示例?

我正在尝试使用http://docs.aws.amazon.com/cognito-user-identity-pools/latest/APIReference/API_AdminInitiateAuth.html

但是,它需要“开发人员凭据”。

我想我能够在http://docs.aws.amazon.com/cognito/latest/developerguide/developer-authenticated-identities.html#associate-developer-provider

之后在Cognito上设置它

现在我不知道我需要在代码上做些什么来处理这样的开发人员凭证?

这是我收到的消息:

  

“用户:   阿尔恩:AWS:STS :: 540029582710:假设角色/ Cognito_Skyline_User_Pool_ProdAuth_Role / CognitoIdentityCredentials   未被授权执行:cognito-idp:AdminInitiateAuth on   资源:   ARN:AWS:cognito-IDP:AP-东北-2:540029582710:了userpool / AP-东北-2_7wGKApTQV“

由于

1 个答案:

答案 0 :(得分:0)

最后,事实证明我需要调用InitiateAuth而不是AdminInitiateAuth

MSDN Flags Enum

相关问题