Skip to content

AmazonBedrockEndpoints

Namespace: Vercel.AI.AmazonBedrock

public static class AmazonBedrockEndpoints

Builds Bedrock service hosts. Partition prefixes select the DNS suffix.

Inheritance: object

View source

public const string AgentRuntimeEndpointEnvironmentVariable = "AWS_ENDPOINT_URL_BEDROCK_AGENT_RUNTIME"

Environment variable that overrides the Bedrock Agent Runtime endpoint.

Value: string

View source

public const string GlobalEndpointEnvironmentVariable = "AWS_ENDPOINT_URL"

Environment variable that overrides every AWS service endpoint.

Value: string

View source

public const string RegionEnvironmentVariable = "AWS_REGION"

Environment variable that supplies the AWS region.

Value: string

View source

public const string RuntimeEndpointEnvironmentVariable = "AWS_ENDPOINT_URL_BEDROCK_RUNTIME"

Environment variable that overrides the Bedrock Runtime endpoint.

Value: string

View source

public static string DnsSuffix(string region)

DNS suffix for an AWS partition. The first matching prefix wins, matching the upstream list order.

Parameters

Name Type Description
region string

Returns: string

View source

public static string Resolve(string? baseUrl, Func<string> getRegion, string service)

Same as String), but <code class=“paramref”>getRegion</code> only runs when no explicit endpoint is configured.

Parameters

Name Type Description
baseUrl string
getRegion Func<string>
service string

Returns: string

View source

public static string Resolve(string? baseUrl, string region, string service)

Returns <code class=“paramref”>baseUrl</code> when it is set, then the service endpoint environment variable, then AWS_ENDPOINT_URL. Otherwise returns https://{service}.{region}.{suffix}.

Parameters

Name Type Description
baseUrl string
region string
service string

Returns: string

View source

Apache-2.0 · Copyright 2023 Vercel, Inc. · unofficial community port, not an official Vercel product