Chat route with Amazon Bedrockv3.6+

Configure a chat route using Amazon Bedrock with the Meta Llama 3 70B Instruct model and the US East 1 AWS region.

The following configuration shows how to set up the AI Proxy plugin using AWS Access Key and AWS Secret Key credentials. Note that Kong AI Gateway can automatically fetch IAM role credentials based on your AWS environment, observing the following precedence order:

  • Fetch from credentials defined in environment variables AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY.
  • Fetch from profile and credential file, defined by AWS_PROFILE and AWS_SHARED_CREDENTIALS_FILE.
  • Fetch from an ECS container credential provider.
  • Fetch from an EKS IAM roles for service account.
  • Fetch from EC2 IMDS metadata. Both v1 and v2 are supported

Prerequisites

  • AWS account with access to Bedrock

Environment variables

  • AWS_ACCESS_KEY_ID: The AWS access key ID to use to connect to Bedrock.

  • AWS_SECRET_ACCESS_KEY: The AWS secret access key to use to connect to Bedrock.

Set up the plugin

Something wrong?

Help us make these docs great!

Kong Developer docs are open source. If you find these useful and want to make them better, contribute today!