DescribeInternetGateways
In this article:
DescribeInternetGateways#
Description#
Request for a list of internet gateways of all existing VPCs and their descriptions. Filtering by the specified criteria allows you to limit the output to only the necessary internet gateways.
Request Parameters#
Filter.N — One or more filters.
Type: List of Filter objects
Required: No
InternetGatewayId.N — The IDs of Internet gateways. If not set, information about all the Internet gateways will be displayed.
Type: Array of strings
Required: No
Supported Filters#
attachment.state — The state of attachment of the internet gateway to the VPC.
attachment.vpc-id — The ID of the VPC, to which the internet gateway is attached.
internet-gateway-id — The ID of the internet gateway.
tag-key — The tag key. Such a filter allows you to get resources with the specified key and any value.
tag:<tag-key> — The key/value a pair of a tag. The tag key is passed in the filter name, while the tag value is used as the filter value.
Response Elements#
internetGatewaySet — Information about internet gateways.
Type: List of InternetGateway objects
requestId — The request ID.
Type: String
Examples#
c2-ec2 DescribeInternetGateways
c2-ec2 DescribeInternetGateways InternetGatewayId.1 <igw_id>
c2-ec2 DescribeInternetGateways Filter.1.Name attachment.vpc-id Filter.1.Value <vpc_id>
c2-ec2 DescribeInternetGateways Filter.1.Name tag:<tag-key> Filter.1.Value "tag-value"