我创建了一个用户池&身份池.
我用过javascript sdk.
我可以注册,发送确认码&使用javascript sdk成功确认用户.
但是当我尝试使用身份验证方法登录用户时尝试使用以下代码传递idToken来获取“CognitoIdentityCredentials”凭据
logins[cognitoEndpoint + "/" + userPoolId] = jwtToken; AWS.config.credentials = new AWS.CognitoIdentityCredentials({ IdentityPoolId: identityPoolId,Logins: logins });
它给了我以下错误
Error: Invalid identity pool configuration. Check assigned IAM roles for this pool. at Request.extractError (aws-sdk.js:104063) at Request.callListeners (aws-sdk.js:106060) at Request.emit (aws-sdk.js:106034) at Request.emit (aws-sdk.js:105121) at Request.transition (aws-sdk.js:104843) at AcceptorStateMachine.runTo (aws-sdk.js:108480) at aws-sdk.js:108492 at Request.<anonymous> (aws-sdk.js:104859) at Request.<anonymous> (aws-sdk.js:105123) at Request.callListeners (aws-sdk.js:106070)
我已授权管理员访问“Unauthenticated role”&身份池的“未经身份验证的角色”以及我正在使用其凭据的用户.
我是新来的.谁能告诉我我错过了什么?
任何帮助,将不胜感激.