AccessDeniedException: User: arn:aws:sts::764717618004:assumed-role/cloudwatch_logs_events_putter/

0

Hello, I have observed that the Lambda functions are working correctly on my local machine with my NextJS application. However, when I deployed my NextJS application on the server, I encountered an error in the network tab.

{"message":"AccessDeniedException: User: arn:aws:sts::764717618004:assumed-role/cloudwatch_logs_events_putter/uZUu4Ca7Slsek0AGRJnQtenJ-5c0c2554740d00c0e47b39b0106000bb2d9b492 is not authorized to perform: cognito-idp:AdminInitiateAuth on resource: arn:aws:cognito-idp:us-east-2:764717618004:userpool/us-east-2_Y93BT0AII because no identity-based policy allows the cognito-idp:AdminInitiateAuth action"}

1 Answer
0

Hi Shyam,

This error comes from the AWS Lambda function from not having the ability to execute the API action cognito-idp:AdminInitiateAuth.

You can correct this by adding an going to your lambda function, going to configuration, and selecting permissions. Under Execution Role, click on the role name and then edit the inline policy to allow the action.

AWS
answered a year ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions