Anthropic Bedrock
What is Anthropic Bedrock?
Amazon Bedrock is a fully managed service that provides access to foundation models from leading AI companies, including Anthropic’s Claude models. With Bedrock, you can use Claude models through AWS infrastructure, benefiting from enterprise-grade security, regional data residency, and seamless integration with your existing AWS environment.
Custom Anthropic Bedrock Integration with Vapi:
Vapi’s Anthropic Bedrock integration allows you to connect your own AWS Bedrock resources to power voice assistants with Claude models. This enables you to maintain full control over your AWS billing, use your own rate limits, and ensure data stays within your AWS environment.
Prerequisites
Before configuring Anthropic Bedrock with Vapi, ensure you have:
- An active AWS account with Bedrock access enabled
- Model access granted for Anthropic Claude models in your Bedrock console
- IAM permissions to create roles and policies
Configuration steps
Create an IAM Role in AWS
Create a new IAM role that Vapi will assume to access your Bedrock resources.
- Go to the IAM Console in AWS
- Navigate to Roles and click Create role
- Select Custom trust policy as the trusted entity type
- Add the trust policy from the next step
Choose a descriptive name for your role, such as VapiBedrockRole, so you can easily identify its purpose.
Attach the Trust Policy
Configure the trust policy to allow Vapi’s AWS account to assume this role.
Without External ID
With External ID
Use this simpler policy if you don’t need the additional security of an External ID:
About External ID: The External ID is an optional security feature that provides an additional layer of protection for cross-account access. If you choose to use one, specify the same value in both your IAM trust policy and the Vapi credential configuration.
Attach the Permissions Policy
Create and attach a permissions policy that grants access to Bedrock model invocation.
Broad Access
Restrictive Access
Use this policy to grant access to all Anthropic models across all regions:
To attach the policy:
- In the IAM Console, go to Policies and click Create policy
- Select JSON and paste your chosen policy
- Name the policy (e.g.,
VapiBedrockInvokePolicy) - Attach the policy to your IAM role
Example credential configuration
Here is a complete example of a Vapi credential configuration for Anthropic Bedrock:
Benefits of using Anthropic Bedrock
Enterprise security:
- Data residency control with regional deployments
- Enterprise-grade security and compliance (SOC 2, HIPAA eligible, etc.)
- Private VPC connectivity options through AWS
Custom rate limits:
- Use your own AWS Bedrock quotas and rate limits
- Avoid shared resource constraints
- Predictable costs and billing through AWS
AWS ecosystem integration:
- Seamless integration with existing AWS infrastructure
- Use AWS CloudWatch for monitoring and logging
- Leverage AWS IAM for fine-grained access control
Troubleshooting
Common error: “Access Denied”
- Cause: The IAM role trust policy doesn’t allow Vapi to assume the role
- Solution: Verify the trust policy includes Vapi’s AWS account ID (
533267069243) and the correct External ID
Common error: “Invalid External ID”
- Cause: The External ID in your trust policy doesn’t match the one in your Vapi credential
- Solution: Ensure the
externalIdvalue in your Vapi credential exactly matches thests:ExternalIdin your IAM trust policy. If you’re not using an External ID, remove theConditionblock from your trust policy
Common error: “Model access denied”
- Cause: The IAM permissions policy doesn’t grant access to the requested model, or model access isn’t enabled in Bedrock
- Solution:
- Verify the permissions policy includes the correct model ARNs
- Ensure you’ve enabled access to the model in the AWS Bedrock console
Common error: “Region not supported”
- Cause: The specified region doesn’t have Bedrock or the requested model available
- Solution: Use a supported region such as
us-east-1,us-west-2, oreu-west-1