首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >认知PreAuthentication_Authentication误差

认知PreAuthentication_Authentication误差
EN

Stack Overflow用户
提问于 2022-07-27 07:08:20
回答 1查看 155关注 0票数 0

我想使用adminInitiateAuth来触发用户迁移lambda函数,但是我的代码给出了以下错误:

代码语言:javascript
复制
"errorType": "UserLambdaValidationException",

"errorMessage": "PreAuthentication failed with error Bad triggerSource PreAuthentication_Authentication.",
  "trace": [
    "UserLambdaValidationException: PreAuthentication failed with error Bad triggerSource PreAuthentication_Authentication.",

代码如下:

代码语言:javascript
复制
const AWS = require('aws-sdk')

const cognito = new AWS.CognitoIdentityServiceProvider()
const params = {
      AuthFlow: "ADMIN_NO_SRP_AUTH",
      UserPoolId: 'eu-west-2_1111111',
      ClientId: '722222222222',
      AuthParameters: {
          USERNAME: email,
          PASSWORD: password
      }
}
const response = await cognito.adminInitiateAuth(params).promise();

此代码可用于同一帐户中的另一个用户池。

EN

回答 1

Stack Overflow用户

发布于 2022-10-03 22:48:08

似乎在池上设置了一个lambda触发器,该触发器失败并以某种方式不正确地操作。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/73133620

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档