create_transit_gateway_metering_policy_entry
¶
create_transit_gateway_metering_policy_entry(
*,
config_overrides: Optional[EC2ClientConfig] = None,
transit_gateway_metering_policy_id: Optional[TransitGatewayMeteringPolicyId] = None,
policy_rule_number: Optional[Integer] = None,
source_transit_gateway_attachment_id: Optional[TransitGatewayAttachmentId] = None,
source_transit_gateway_attachment_type: Optional[
TransitGatewayAttachmentResourceType
] = None,
source_cidr_block: Optional[String] = None,
source_port_range: Optional[String] = None,
destination_transit_gateway_attachment_id: Optional[
TransitGatewayAttachmentId
] = None,
destination_transit_gateway_attachment_type: Optional[
TransitGatewayAttachmentResourceType
] = None,
destination_cidr_block: Optional[String] = None,
destination_port_range: Optional[String] = None,
protocol: Optional[String] = None,
metered_account: Optional[TransitGatewayMeteringPayerType] = None,
dry_run: Optional[Boolean] = None,
) -> CreateTransitGatewayMeteringPolicyEntryResult
Creates an entry in a transit gateway metering policy to define traffic measurement rules.
Parameters:
-
transit_gateway_metering_policy_id(Optional[TransitGatewayMeteringPolicyId], default:None) –The ID of the transit gateway metering policy to add the entry to.
-
policy_rule_number(Optional[Integer], default:None) –The rule number for the metering policy entry. Rules are processed in order from lowest to highest number.
-
source_transit_gateway_attachment_id(Optional[TransitGatewayAttachmentId], default:None) –The ID of the source transit gateway attachment for traffic matching.
-
source_transit_gateway_attachment_type(Optional[TransitGatewayAttachmentResourceType], default:None) –The type of the source transit gateway attachment for traffic matching. Note that the
tgw-peeringresource type has been deprecated. To configure metering policies for Connect, use the transport attachment type. -
source_cidr_block(Optional[String], default:None) –The source CIDR block for traffic matching.
-
source_port_range(Optional[String], default:None) –The source port range for traffic matching.
-
destination_transit_gateway_attachment_id(Optional[TransitGatewayAttachmentId], default:None) –The ID of the destination transit gateway attachment for traffic matching.
-
destination_transit_gateway_attachment_type(Optional[TransitGatewayAttachmentResourceType], default:None) –The type of the destination transit gateway attachment for traffic matching. Note that the
tgw-peeringresource type has been deprecated. To configure metering policies for Connect, use the transport attachment type. -
destination_cidr_block(Optional[String], default:None) –The destination CIDR block for traffic matching.
-
destination_port_range(Optional[String], default:None) –The destination port range for traffic matching.
-
protocol(Optional[String], default:None) –The protocol for traffic matching (1, 6, 17, etc.).
-
metered_account(Optional[TransitGatewayMeteringPayerType], default:None) –The Amazon Web Services account ID to which the metered traffic should be attributed.
-
dry_run(Optional[Boolean], default:None) –Checks 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 isUnauthorizedOperation.
Raises:
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_ec2/_services/ec2.py
13371 13372 13373 13374 13375 13376 13377 13378 13379 13380 13381 13382 13383 13384 13385 13386 13387 13388 13389 13390 13391 13392 13393 13394 13395 13396 13397 13398 13399 13400 13401 13402 13403 13404 13405 13406 13407 13408 13409 13410 13411 13412 13413 13414 13415 13416 13417 13418 13419 13420 13421 13422 13423 13424 13425 13426 13427 13428 13429 13430 13431 13432 13433 13434 13435 13436 13437 13438 13439 13440 13441 13442 13443 13444 13445 13446 13447 13448 13449 13450 13451 13452 13453 13454 13455 13456 13457 13458 13459 13460 13461 13462 13463 13464 13465 13466 13467 13468 13469 13470 13471 13472 13473 13474 13475 13476 13477 13478 13479 13480 13481 13482 13483 13484 | |