RegionInfo

class aws_cdk.region_info.RegionInfo(*args: Any, **kwargs)

Bases: object

Information pertaining to an AWS region.

ExampleMetadata:

infused

Example:

# Get the information for "eu-west-1":
region = region_info.RegionInfo.get("eu-west-1")

# Access attributes:
region.s3_static_website_endpoint # s3-website-eu-west-1.amazonaws.com
region.service_principal("logs.amazonaws.com")

Methods

cloudwatch_lambda_insights_arn(insights_version, architecture=None)

The ARN of the CloudWatch Lambda Insights extension, for the given version.

Parameters:
  • insights_version (str) – the version (e.g. 1.0.98.0).

  • architecture (Optional[str]) – the Lambda Function architecture (e.g. ‘x86_64’ or ‘arm64’).

Return type:

Optional[str]

service_principal(service)

The name of the service principal for a given service in this region.

Parameters:

service (str) – the service name (e.g: s3.amazonaws.com).

Return type:

Optional[str]

Attributes

app_mesh_repository_account

The ID of the AWS account that owns the public ECR repository that contains the AWS App Mesh Envoy Proxy images in a given region.

cdk_metadata_resource_available

Whether the AWS::CDK::Metadata CloudFormation Resource is available in this region or not.

dlc_repository_account

The ID of the AWS account that owns the public ECR repository containing the AWS Deep Learning Containers images in this region.

domain_suffix

amazonaws.com) for this region.

Type:

The domain name suffix (e.g

ebs_env_endpoint_hosted_zone_id

Z2O1EMRO9K5GLX).

Type:

The hosted zone ID used by Route 53 to alias a EBS environment endpoint in this region (e.g

elbv2_account

The account ID for ELBv2 in this region.

firehose_cidr_block

The CIDR block used by Kinesis Data Firehose servers.

name
partition

aws).

Type:

The name of the ARN partition for this region (e.g

regions = [<aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>, <aws_cdk.region_info.RegionInfo object>]
s3_static_website_endpoint

s3-static-website-us-east-1.amazonaws.com).

Type:

The endpoint used by S3 static website hosting in this region (e.g

s3_static_website_hosted_zone_id

Z2O1EMRO9K5GLX).

Type:

The hosted zone ID used by Route 53 to alias a S3 static website in this region (e.g

vpc_endpoint_service_name_prefix

The prefix for VPC Endpoint Service names, cn.com.amazonaws.vpce for China regions, com.amazonaws.vpce otherwise.

Static Methods

classmethod get(name)

Obtain region info for a given region name.

Parameters:

name (str) – the name of the region (e.g: us-east-1).

Return type:

RegionInfo

classmethod limited_region_map(fact_name, partitions)

Retrieves a collection of all fact values for all regions, limited to some partitions.

Parameters:
  • fact_name (str) – the name of the fact to retrieve values for. For a list of common fact names, see the FactName class

  • partitions (Sequence[str]) – list of partitions to retrieve facts for. Defaults to ['aws', 'aws-cn'].

Return type:

Mapping[str, str]

Returns:

a mapping with AWS region codes as the keys, and the fact in the given region as the value for that key

classmethod region_map(fact_name)

Retrieves a collection of all fact values for all regions that fact is defined in.

Parameters:

fact_name (str) – the name of the fact to retrieve values for. For a list of common fact names, see the FactName class

Return type:

Mapping[str, str]

Returns:

a mapping with AWS region codes as the keys, and the fact in the given region as the value for that key