AWS Bedrock Error: 'User is not authorized to perform bedrock:InvokeModel'

 

AWS Bedrock Error: 'User is not authorized to perform bedrock:InvokeModel'

A diagnostic guide to fixing Bedrock invocation failures caused by missing data-plane permissions.





Problem

When invoking an AWS Bedrock foundation model, the request fails with:

User is not authorized to perform bedrock:InvokeModel

The call is rejected immediately.
No inference occurs.
No tokens are consumed.


Clarifying the Issue

This error means the caller does not have permission to invoke Bedrock models on the data plane.

In AWS Bedrock, listing models and invoking models are separate permission paths:

  • You may successfully see models in the console
  • You may pass general IAM validation
  • But without bedrock:InvokeModel, inference is blocked

This error is distinct from Bedrock Model Access denials in the console, which can produce a different AccessDeniedException even when IAM is correctly configured.

This is not a region issue.
This is not a model availability issue.
This is a missing IAM action.


Why It Matters

This error commonly appears:

  • When moving from console testing to SDK usage
  • When invoking Bedrock from Lambda, ECS, or EC2
  • When roles were cloned from non-AI workloads
  • When SCPs restrict new services by default

It stops production workloads cold.


Key Terms

  • bedrock:InvokeModel – IAM action required to perform model inference
  • Data plane – The Bedrock runtime path where inference occurs
  • Execution role – IAM role assumed by Lambda, ECS, or EC2
  • SCP (Service Control Policy) – Organization-level policy that can override IAM

Steps at a Glance

  1. Identify the IAM principal making the call
  2. Add bedrock:InvokeModel permission
  3. Verify no SCP is blocking Bedrock
  4. Confirm role propagation
  5. Retest via CLI or SDK

Detailed Steps

1. Identify the Calling Principal

Determine which IAM identity is invoking Bedrock:

  • Lambda execution role
  • ECS task role
  • EC2 instance profile
  • Local user or assumed role

Do not assume — confirm.


2. Add the Required IAM Permission

At minimum, the role or user must allow:

{
  "Version": "2012-10-17",
  "Statement": [
    {
      "Effect": "Allow",
      "Action": [
        "bedrock:InvokeModel",
        "bedrock:InvokeModelWithResponseStream"
      ],
      "Resource": "*"
    }
  ]
}

For Fix-It purposes, use "Resource": "*" to clear the failure first.
You can scope later.


3. Check for SCP Restrictions

If your account is under AWS Organizations:

  • SCPs may block Bedrock even when IAM allows it
  • The error message remains User is not authorized

Verify:

bedrock:InvokeModel

is not denied at the organization level.


4. Allow Time for Role Propagation

IAM changes are usually fast but not instant.

If you updated a role:

  • Wait a few minutes
  • Redeploy or restart compute if needed

Stale credentials will continue to fail.


5. Retest with AWS CLI

Validate outside your application:

aws bedrock-runtime invoke-model \
  --region us-east-1 \
  --model-id amazon.titan-text-express-v1 \
  --body '{"inputText":"Hello"}' \
  output.json

Ensure the region matches where the model is enabled in Bedrock.

If this works, your IAM issue is resolved.


Pro Tips

  • Seeing models in the console does not imply invoke permission
  • Lambda roles frequently miss Bedrock actions
  • SCP failures masquerade as IAM failures
  • This is a data-plane error, not a control-plane one

Conclusion

User is not authorized to perform bedrock:InvokeModel is a permission gap, not a platform failure.

Once the correct IAM action is granted and no SCP blocks it, AWS Bedrock inference works reliably inside Amazon Web Services.

Fix the permission.
Retry the call.
Move on.


Aaron Rose is a software engineer and technology writer at tech-reader.blog and the author of Think Like a Genius.

Comments

Popular posts from this blog

The New ChatGPT Reason Feature: What It Is and Why You Should Use It

Insight: The Great Minimal OS Showdown—DietPi vs Raspberry Pi OS Lite

Raspberry Pi Connect vs. RealVNC: A Comprehensive Comparison