Skip to content

Resource: awsApigatewayv2VpcLink

Manages an Amazon API Gateway Version 2 VPC Link.

-> Note: Amazon API Gateway Version 2 VPC Links enable private integrations that connect HTTP APIs to private resources in a VPC. To enable private integration for REST APIs, use the Amazon API Gateway Version 1 VPC Link resource.

Example Usage

/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
new aws.apigatewayv2VpcLink.Apigatewayv2VpcLink(this, "example", {
  name: "example",
  securityGroupIds: ["${data.aws_security_group.example.id}"],
  subnetIds: "${data.aws_subnet_ids.example.ids}",
  tags: {
    Usage: "example",
  },
});

Argument Reference

The following arguments are supported:

  • name - (Required) Name of the VPC Link. Must be between 1 and 128 characters in length.
  • securityGroupIds - (Required) Security group IDs for the VPC Link.
  • subnetIds - (Required) Subnet IDs for the VPC Link.
  • tags - (Optional) Map of tags to assign to the VPC Link. If configured with a provider defaultTags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Attributes Reference

In addition to all arguments above, the following attributes are exported:

  • id - VPC Link identifier.
  • arn - VPC Link ARN.
  • tagsAll - Map of tags assigned to the resource, including those inherited from the provider defaultTags configuration block.

Import

awsApigatewayv2VpcLink can be imported by using the VPC Link identifier, e.g.,

$ terraform import aws_apigatewayv2_vpc_link.example aabbccddee