Creates a new location object in your Firebolt account for Amazon Bedrock. A Bedrock LOCATION securely stores AWS credentials that you can reuse when invoking Bedrock models with AWS_BEDROCK_AI_QUERY or AI_QUERY. Topics:

Syntax

CREATE LOCATION [ IF NOT EXISTS ] <location_name> WITH
  SOURCE = AMAZON_BEDROCK
  CREDENTIALS = {
    ( AWS_ACCESS_KEY_ID = '<aws_access_key_id>'
      AWS_SECRET_ACCESS_KEY = '<aws_secret_access_key>'
      [ AWS_SESSION_TOKEN = '<aws_session_token>' ] )
    |
    ( AWS_ROLE_ARN = '<aws_role_arn>'
      [ AWS_ROLE_EXTERNAL_ID = '<aws_role_external_id>' ] )
  }
  [ DESCRIPTION = '<description>' ]

Parameters

Common parameters

ParameterDescription
<location_name>A unique identifier for the location within your account.
SOURCEThe external source type. For Bedrock, set to AMAZON_BEDROCK.
DESCRIPTIONOptional comment describing the location’s purpose.

Amazon Bedrock parameters

ParameterDescription
CREDENTIALSAWS authentication credentials used when invoking Bedrock models.

AWS authentication parameters

ParameterDescription
AWS_ACCESS_KEY_IDYour AWS access key ID for key-based authentication.
AWS_SECRET_ACCESS_KEYYour AWS secret access key for key-based authentication.
AWS_SESSION_TOKENOptional temporary session token for temporary credentials.
AWS_ROLE_ARNThe ARN of the IAM role to assume for role-based authentication.
AWS_ROLE_EXTERNAL_IDOptional external ID for role assumption.

Examples

Authenticate using an access key

CREATE LOCATION my_bedrock_location WITH
  SOURCE = AMAZON_BEDROCK
  CREDENTIALS = (
    AWS_ACCESS_KEY_ID = '<aws_access_key_id>'
    AWS_SECRET_ACCESS_KEY = '<aws_secret_access_key>'
  );

Authenticate using a role

CREATE LOCATION my_bedrock_location WITH
  SOURCE = AMAZON_BEDROCK
  CREDENTIALS = (
    AWS_ROLE_ARN = 'arn:aws:iam::123456789012:role/BedrockAccess'
    -- Optional: AWS_ROLE_EXTERNAL_ID = '<external_id>'
  );

Create a Bedrock location with a description

CREATE LOCATION my_bedrock_location WITH
  SOURCE = AMAZON_BEDROCK
  CREDENTIALS = (
    AWS_ACCESS_KEY_ID = '<aws_access_key_id>'
    AWS_SECRET_ACCESS_KEY = '<aws_secret_access_key>'
  )
  DESCRIPTION = 'Credentials for invoking Bedrock models';
To use this location, pass its name as the <location> argument to AWS_BEDROCK_AI_QUERY or AI_QUERY.