Here is an AWS Support Knowledge Center article that may give you pointers on how to debug this - https://aws.amazon.com/premiumsupport/knowledge-center/iam-assume-role-error/
Just to add a bit more detail to Indranil's answer: Your IAM User does not have permission to call the
sts:AssumeRole action to assume the role.
Adding that permission to the user (for the role resource that you're attempting to assume) will fix the error.
not authorized to perform: sts:AssumeRoleasked a month ago
Error creating CodeBuild project - CodeBuild is not authorized to perform...Accepted Answerasked 2 months ago
Setting up Own MQTT broker (using Mosquitto) - not authorized to perform: iot:CreatePolicyasked 3 months ago
Lambda is not authorized to perform: secretsmanager:GetSecretValueasked 3 years ago
Issue uploading C# function to AWS Lambda - not authorized to perform: iam:PassRole"asked 5 months ago
StartCallAnalyticsJob : User is not authorized to access this resourceasked a month ago
CodeBuild is not authorized to perform: sts:AssumeRoleasked 4 years ago
Not authorized to start new instancesAccepted Answerasked 3 years ago
Codepipeline: "root is not authorized to perform: iam:PassRole"Accepted Answerasked 3 years ago
User: batch.amazonaws.com is not authorized to perform: sts:AssumeRole on rasked a year ago