Skip to main content

transit_gateway_prefix_list_references

Creates, updates, deletes, gets or lists a transit_gateway_prefix_list_references resource.

Overview

Nametransit_gateway_prefix_list_references
TypeResource
Idaws.ec2.transit_gateway_prefix_list_references

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
blackholebooleanIndicates whether traffic that matches this route is dropped.
prefix_list_idstringThe ID of the prefix list.
prefix_list_owner_idstringThe ID of the prefix list owner.
statestringThe state of the prefix list reference.
transit_gateway_attachmentstringInformation about the transit gateway attachment.
transit_gateway_route_table_idstringThe ID of the transit gateway route table.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_transit_gateway_prefix_list_referencesselectTransitGatewayRouteTableId, regionFilter, MaxResults, NextToken, DryRunGets information about the prefix list references in a specified transit gateway route table.
create_transit_gateway_prefix_list_referenceinsertTransitGatewayRouteTableId, PrefixListId, regionTransitGatewayAttachmentId, Blackhole, DryRunCreates a reference (route) to a prefix list in a specified transit gateway route table.
modify_transit_gateway_prefix_list_referenceupdateTransitGatewayRouteTableId, PrefixListId, regionTransitGatewayAttachmentId, Blackhole, DryRunModifies a reference (route) to a prefix list in a specified transit gateway route table.
delete_transit_gateway_prefix_list_referencedeleteTransitGatewayRouteTableId, PrefixListId, regionDryRunDeletes a reference (route) to a prefix list in a specified transit gateway route table.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
PrefixListIdstringThe ID of the prefix list.
TransitGatewayRouteTableIdstringThe ID of the route table.
regionstringAWS region (default: us-east-1)
BlackholebooleanIndicates whether to drop traffic that matches this route.
DryRunbooleanChecks whether you have the required permissions for the action, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.
FilterarrayOne or more filters. The possible values are: attachment.resource-id - The ID of the resource for the attachment. attachment.resource-type - The type of resource for the attachment. Valid values are vpc | vpn | direct-connect-gateway | peering. attachment.transit-gateway-attachment-id - The ID of the attachment. is-blackhole - Whether traffic matching the route is blocked (true | false). prefix-list-id - The ID of the prefix list. prefix-list-owner-id - The ID of the owner of the prefix list. state - The state of the prefix list reference (pending | available | modifying | deleting).
MaxResultsintegerThe maximum number of results to return with a single call. To retrieve the remaining results, make another call with the returned nextToken value.
NextTokenstringThe token for the next page of results.
TransitGatewayAttachmentIdstringThe ID of the attachment to which traffic is routed.

SELECT examples

Gets information about the prefix list references in a specified transit gateway route table.

SELECT
blackhole,
prefix_list_id,
prefix_list_owner_id,
state,
transit_gateway_attachment,
transit_gateway_route_table_id
FROM aws.ec2.transit_gateway_prefix_list_references
WHERE TransitGatewayRouteTableId = '{{ TransitGatewayRouteTableId }}' -- required
AND region = '{{ region }}' -- required
AND Filter = '{{ Filter }}'
AND MaxResults = '{{ MaxResults }}'
AND NextToken = '{{ NextToken }}'
AND DryRun = '{{ DryRun }}'
;

INSERT examples

Creates a reference (route) to a prefix list in a specified transit gateway route table.

INSERT INTO aws.ec2.transit_gateway_prefix_list_references (
TransitGatewayRouteTableId,
PrefixListId,
region,
TransitGatewayAttachmentId,
Blackhole,
DryRun
)
SELECT
'{{ TransitGatewayRouteTableId }}',
'{{ PrefixListId }}',
'{{ region }}',
'{{ TransitGatewayAttachmentId }}',
'{{ Blackhole }}',
'{{ DryRun }}'
RETURNING
blackhole,
prefix_list_id,
prefix_list_owner_id,
state,
transit_gateway_attachment,
transit_gateway_route_table_id
;

UPDATE examples

Modifies a reference (route) to a prefix list in a specified transit gateway route table.

UPDATE aws.ec2.transit_gateway_prefix_list_references
SET
-- No updatable properties
WHERE
TransitGatewayRouteTableId = '{{ TransitGatewayRouteTableId }}' --required
AND PrefixListId = '{{ PrefixListId }}' --required
AND region = '{{ region }}' --required
AND TransitGatewayAttachmentId = '{{ TransitGatewayAttachmentId}}'
AND Blackhole = {{ Blackhole}}
AND DryRun = {{ DryRun}}
RETURNING
blackhole,
prefix_list_id,
prefix_list_owner_id,
state,
transit_gateway_attachment,
transit_gateway_route_table_id;

DELETE examples

Deletes a reference (route) to a prefix list in a specified transit gateway route table.

DELETE FROM aws.ec2.transit_gateway_prefix_list_references
WHERE TransitGatewayRouteTableId = '{{ TransitGatewayRouteTableId }}' --required
AND PrefixListId = '{{ PrefixListId }}' --required
AND region = '{{ region }}' --required
AND DryRun = '{{ DryRun }}'
;