CloudWatchNetworkMonitor ************************ Client ====== class CloudWatchNetworkMonitor.Client A low-level client representing Amazon CloudWatch Network Monitor Amazon CloudWatch Network Monitor is an Amazon Web Services active network monitoring service that identifies if a network issues exists within the Amazon Web Services network or your own company network. Within Network Monitor you'll choose the source VPCs and subnets from the Amazon Web Services network in which you operate and then you'll choose the destination IP addresses from your on- premises network. From these sources and destinations, Network Monitor creates a monitor containing all the possible source and destination combinations, each of which is called a probe, within a single monitor. These probes then monitor network traffic to help you identify where network issues might be affecting your traffic. Before you begin, ensure the Amazon Web Services CLI is configured in the Amazon Web Services Account where you will create the Network Monitor resource. Network Monitor doesn’t support creation on cross-account resources, but you can create a Network Monitor in any subnet belonging to a VPC owned by your Account. For more information, see Using Amazon CloudWatch Network Monitor in the *Amazon CloudWatch User Guide*. import boto3 client = boto3.client('networkmonitor') These are the available methods: * can_paginate * close * create_monitor * create_probe * delete_monitor * delete_probe * get_monitor * get_paginator * get_probe * get_waiter * list_monitors * list_tags_for_resource * tag_resource * untag_resource * update_monitor * update_probe Paginators ========== Paginators are available on a client instance via the "get_paginator" method. For more detailed instructions and examples on the usage of paginators, see the paginators user guide. The available paginators are: * ListMonitors CloudWatchNetworkMonitor / Paginator / ListMonitors ListMonitors ************ class CloudWatchNetworkMonitor.Paginator.ListMonitors paginator = client.get_paginator('list_monitors') paginate(**kwargs) Creates an iterator that will paginate through responses from "CloudWatchNetworkMonitor.Client.list_monitors()". See also: AWS API Documentation **Request Syntax** response_iterator = paginator.paginate( state='string', PaginationConfig={ 'MaxItems': 123, 'PageSize': 123, 'StartingToken': 'string' } ) Parameters: * **state** (*string*) -- The list of all monitors and their states. * **PaginationConfig** (*dict*) -- A dictionary that provides parameters to control pagination. * **MaxItems** *(integer) --* The total number of items to return. If the total number of items available is more than the value specified in max-items then a "NextToken" will be provided in the output that you can use to resume pagination. * **PageSize** *(integer) --* The size of each page. * **StartingToken** *(string) --* A token to specify where to start paginating. This is the "NextToken" from a previous response. Return type: dict Returns: **Response Syntax** { 'monitors': [ { 'monitorArn': 'string', 'monitorName': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING', 'aggregationPeriod': 123, 'tags': { 'string': 'string' } }, ], 'NextToken': 'string' } **Response Structure** * *(dict) --* * **monitors** *(list) --* Lists individual details about each of your monitors. * *(dict) --* Displays summary information about a monitor. * **monitorArn** *(string) --* The ARN of the monitor. * **monitorName** *(string) --* The name of the monitor. * **state** *(string) --* The state of the monitor. * **aggregationPeriod** *(integer) --* The time, in seconds, that metrics are collected and sent to Amazon CloudWatch. Valid values are either "30" or "60". * **tags** *(dict) --* The list of key-value pairs assigned to the monitor. * *(string) --* * *(string) --* * **NextToken** *(string) --* A token to resume pagination. CloudWatchNetworkMonitor / Client / get_paginator get_paginator ************* CloudWatchNetworkMonitor.Client.get_paginator(operation_name) Create a paginator for an operation. Parameters: **operation_name** (*string*) -- The operation name. This is the same name as the method name on the client. For example, if the method name is "create_foo", and you'd normally invoke the operation as "client.create_foo(**kwargs)", if the "create_foo" operation can be paginated, you can use the call "client.get_paginator("create_foo")". Raises: **OperationNotPageableError** -- Raised if the operation is not pageable. You can use the "client.can_paginate" method to check if an operation is pageable. Return type: "botocore.paginate.Paginator" Returns: A paginator object. CloudWatchNetworkMonitor / Client / create_probe create_probe ************ CloudWatchNetworkMonitor.Client.create_probe(**kwargs) Create a probe within a monitor. Once you create a probe, and it begins monitoring your network traffic, you'll incur billing charges for that probe. This action requires the "monitorName" parameter. Run "ListMonitors" to get a list of monitor names. Note the name of the "monitorName" you want to create the probe for. See also: AWS API Documentation **Request Syntax** response = client.create_probe( monitorName='string', probe={ 'sourceArn': 'string', 'destination': 'string', 'destinationPort': 123, 'protocol': 'TCP'|'ICMP', 'packetSize': 123, 'tags': { 'string': 'string' } }, clientToken='string', tags={ 'string': 'string' } ) Parameters: * **monitorName** (*string*) -- **[REQUIRED]** The name of the monitor to associated with the probe. * **probe** (*dict*) -- **[REQUIRED]** Describes the details of an individual probe for a monitor. * **sourceArn** *(string) --* **[REQUIRED]** The ARN of the subnet. * **destination** *(string) --* **[REQUIRED]** The destination IP address. This must be either "IPV4" or "IPV6". * **destinationPort** *(integer) --* The port associated with the "destination". This is required only if the "protocol" is "TCP" and must be a number between "1" and "65536". * **protocol** *(string) --* **[REQUIRED]** The protocol used for the network traffic between the "source" and "destination". This must be either "TCP" or "ICMP". * **packetSize** *(integer) --* The size of the packets sent between the source and destination. This must be a number between "56" and "8500". * **tags** *(dict) --* The list of key-value pairs created and assigned to the monitor. * *(string) --* * *(string) --* * **clientToken** (*string*) -- Unique, case-sensitive identifier to ensure the idempotency of the request. Only returned if a client token was provided in the request. This field is autopopulated if not provided. * **tags** (*dict*) -- The list of key-value pairs created and assigned to the probe. * *(string) --* * *(string) --* Return type: dict Returns: **Response Syntax** { 'probeId': 'string', 'probeArn': 'string', 'sourceArn': 'string', 'destination': 'string', 'destinationPort': 123, 'protocol': 'TCP'|'ICMP', 'packetSize': 123, 'addressFamily': 'IPV4'|'IPV6', 'vpcId': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING'|'DELETED', 'createdAt': datetime(2015, 1, 1), 'modifiedAt': datetime(2015, 1, 1), 'tags': { 'string': 'string' } } **Response Structure** * *(dict) --* * **probeId** *(string) --* The ID of the probe for which details are returned. * **probeArn** *(string) --* The ARN of the probe. * **sourceArn** *(string) --* The ARN of the probe. * **destination** *(string) --* The destination IP address for the monitor. This must be either an IPv4 or IPv6 address. * **destinationPort** *(integer) --* The port associated with the "destination". This is required only if the "protocol" is "TCP" and must be a number between "1" and "65536". * **protocol** *(string) --* The protocol used for the network traffic between the "source" and "destination". This must be either "TCP" or "ICMP". * **packetSize** *(integer) --* The size of the packets sent between the source and destination. This must be a number between "56" and "8500". * **addressFamily** *(string) --* Indicates whether the IP address is "IPV4" or "IPV6". * **vpcId** *(string) --* The ID of the source VPC or subnet. * **state** *(string) --* The state of the probe. * **createdAt** *(datetime) --* The time and date that the probe was created. * **modifiedAt** *(datetime) --* The time and date when the probe was last modified. * **tags** *(dict) --* The list of key-value pairs assigned to the probe. * *(string) --* * *(string) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" * "CloudWatchNetworkMonitor.Client.exceptions.ServiceQuotaExceeded Exception" CloudWatchNetworkMonitor / Client / can_paginate can_paginate ************ CloudWatchNetworkMonitor.Client.can_paginate(operation_name) Check if an operation can be paginated. Parameters: **operation_name** (*string*) -- The operation name. This is the same name as the method name on the client. For example, if the method name is "create_foo", and you'd normally invoke the operation as "client.create_foo(**kwargs)", if the "create_foo" operation can be paginated, you can use the call "client.get_paginator("create_foo")". Returns: "True" if the operation can be paginated, "False" otherwise. CloudWatchNetworkMonitor / Client / get_probe get_probe ********* CloudWatchNetworkMonitor.Client.get_probe(**kwargs) Returns the details about a probe. This action requires both the "monitorName" and "probeId" parameters. Run "ListMonitors" to get a list of monitor names. Run "GetMonitor" to get a list of probes and probe IDs. See also: AWS API Documentation **Request Syntax** response = client.get_probe( monitorName='string', probeId='string' ) Parameters: * **monitorName** (*string*) -- **[REQUIRED]** The name of the monitor associated with the probe. Run "ListMonitors" to get a list of monitor names. * **probeId** (*string*) -- **[REQUIRED]** The ID of the probe to get information about. Run "GetMonitor" action to get a list of probes and probe IDs for the monitor. Return type: dict Returns: **Response Syntax** { 'probeId': 'string', 'probeArn': 'string', 'sourceArn': 'string', 'destination': 'string', 'destinationPort': 123, 'protocol': 'TCP'|'ICMP', 'packetSize': 123, 'addressFamily': 'IPV4'|'IPV6', 'vpcId': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING'|'DELETED', 'createdAt': datetime(2015, 1, 1), 'modifiedAt': datetime(2015, 1, 1), 'tags': { 'string': 'string' } } **Response Structure** * *(dict) --* * **probeId** *(string) --* The ID of the probe for which details are returned. * **probeArn** *(string) --* The ARN of the probe. * **sourceArn** *(string) --* The ARN of the probe. * **destination** *(string) --* The destination IP address for the monitor. This must be either an IPv4 or IPv6 address. * **destinationPort** *(integer) --* The port associated with the "destination". This is required only if the "protocol" is "TCP" and must be a number between "1" and "65536". * **protocol** *(string) --* The protocol used for the network traffic between the "source" and "destination". This must be either "TCP" or "ICMP". * **packetSize** *(integer) --* The size of the packets sent between the source and destination. This must be a number between "56" and "8500". * **addressFamily** *(string) --* Indicates whether the IP address is "IPV4" or "IPV6". * **vpcId** *(string) --* The ID of the source VPC or subnet. * **state** *(string) --* The state of the probe. * **createdAt** *(datetime) --* The time and date that the probe was created. * **modifiedAt** *(datetime) --* The time and date that the probe was last modified. * **tags** *(dict) --* The list of key-value pairs assigned to the probe. * *(string) --* * *(string) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" CloudWatchNetworkMonitor / Client / list_monitors list_monitors ************* CloudWatchNetworkMonitor.Client.list_monitors(**kwargs) Returns a list of all of your monitors. See also: AWS API Documentation **Request Syntax** response = client.list_monitors( nextToken='string', maxResults=123, state='string' ) Parameters: * **nextToken** (*string*) -- The token for the next page of results. * **maxResults** (*integer*) -- The maximum number of results to return with a single call. To retrieve the remaining results, make another call with the returned "nextToken" value. If "MaxResults" is given a value larger than 100, only 100 results are returned. * **state** (*string*) -- The list of all monitors and their states. Return type: dict Returns: **Response Syntax** { 'monitors': [ { 'monitorArn': 'string', 'monitorName': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING', 'aggregationPeriod': 123, 'tags': { 'string': 'string' } }, ], 'nextToken': 'string' } **Response Structure** * *(dict) --* * **monitors** *(list) --* Lists individual details about each of your monitors. * *(dict) --* Displays summary information about a monitor. * **monitorArn** *(string) --* The ARN of the monitor. * **monitorName** *(string) --* The name of the monitor. * **state** *(string) --* The state of the monitor. * **aggregationPeriod** *(integer) --* The time, in seconds, that metrics are collected and sent to Amazon CloudWatch. Valid values are either "30" or "60". * **tags** *(dict) --* The list of key-value pairs assigned to the monitor. * *(string) --* * *(string) --* * **nextToken** *(string) --* The token for the next page of results. **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" CloudWatchNetworkMonitor / Client / list_tags_for_resource list_tags_for_resource ********************** CloudWatchNetworkMonitor.Client.list_tags_for_resource(**kwargs) Lists the tags assigned to this resource. See also: AWS API Documentation **Request Syntax** response = client.list_tags_for_resource( resourceArn='string' ) Parameters: **resourceArn** (*string*) -- **[REQUIRED]** The Return type: dict Returns: **Response Syntax** { 'tags': { 'string': 'string' } } **Response Structure** * *(dict) --* * **tags** *(dict) --* Lists the tags assigned to the resource. * *(string) --* * *(string) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" * "CloudWatchNetworkMonitor.Client.exceptions.ConflictException" CloudWatchNetworkMonitor / Client / get_monitor get_monitor *********** CloudWatchNetworkMonitor.Client.get_monitor(**kwargs) Returns details about a specific monitor. This action requires the "monitorName" parameter. Run "ListMonitors" to get a list of monitor names. See also: AWS API Documentation **Request Syntax** response = client.get_monitor( monitorName='string' ) Parameters: **monitorName** (*string*) -- **[REQUIRED]** The name of the monitor that details are returned for. Return type: dict Returns: **Response Syntax** { 'monitorArn': 'string', 'monitorName': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING', 'aggregationPeriod': 123, 'tags': { 'string': 'string' }, 'probes': [ { 'probeId': 'string', 'probeArn': 'string', 'sourceArn': 'string', 'destination': 'string', 'destinationPort': 123, 'protocol': 'TCP'|'ICMP', 'packetSize': 123, 'addressFamily': 'IPV4'|'IPV6', 'vpcId': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING'|'DELETED', 'createdAt': datetime(2015, 1, 1), 'modifiedAt': datetime(2015, 1, 1), 'tags': { 'string': 'string' } }, ], 'createdAt': datetime(2015, 1, 1), 'modifiedAt': datetime(2015, 1, 1) } **Response Structure** * *(dict) --* * **monitorArn** *(string) --* The ARN of the selected monitor. * **monitorName** *(string) --* The name of the monitor. * **state** *(string) --* Lists the status of the "state" of each monitor. * **aggregationPeriod** *(integer) --* The aggregation period for the specified monitor. * **tags** *(dict) --* The list of key-value pairs assigned to the monitor. * *(string) --* * *(string) --* * **probes** *(list) --* The details about each probe associated with that monitor. * *(dict) --* Describes information about a network monitor probe. * **probeId** *(string) --* The ID of the probe. * **probeArn** *(string) --* The ARN of the probe. * **sourceArn** *(string) --* The ARN of the probe source subnet. * **destination** *(string) --* The destination for the probe. This should be either an "IPV4" or "IPV6". * **destinationPort** *(integer) --* The destination port for the probe. This is required only if the "protocol" is "TCP" and must be a number between "1" and "65536". * **protocol** *(string) --* The network protocol for the destination. This can be either "TCP" or "ICMP". If the protocol is "TCP", then "port" is also required. * **packetSize** *(integer) --* The size of the packets traveling between the "source" and "destination". This must be a number between "56" and * **addressFamily** *(string) --* The IPv4 or IPv6 address for the probe. * **vpcId** *(string) --* The ID of the source VPC subnet. * **state** *(string) --* The state of the probe. * **createdAt** *(datetime) --* The time and date the probe was created. * **modifiedAt** *(datetime) --* The time and date that the probe was last modified. * **tags** *(dict) --* The list of key-value pairs created and assigned to the probe. * *(string) --* * *(string) --* * **createdAt** *(datetime) --* The time and date when the monitor was created. * **modifiedAt** *(datetime) --* The time and date when the monitor was last modified. **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" CloudWatchNetworkMonitor / Client / untag_resource untag_resource ************** CloudWatchNetworkMonitor.Client.untag_resource(**kwargs) Removes a key-value pair from a monitor or probe. See also: AWS API Documentation **Request Syntax** response = client.untag_resource( resourceArn='string', tagKeys=[ 'string', ] ) Parameters: * **resourceArn** (*string*) -- **[REQUIRED]** The ARN of the monitor or probe that the tag should be removed from. * **tagKeys** (*list*) -- **[REQUIRED]** The key-value pa * *(string) --* Return type: dict Returns: **Response Syntax** {} **Response Structure** * *(dict) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" * "CloudWatchNetworkMonitor.Client.exceptions.ConflictException" CloudWatchNetworkMonitor / Client / update_probe update_probe ************ CloudWatchNetworkMonitor.Client.update_probe(**kwargs) Updates a monitor probe. This action requires both the "monitorName" and "probeId" parameters. Run "ListMonitors" to get a list of monitor names. Run "GetMonitor" to get a list of probes and probe IDs. You can update the following para create a monitor with probes using this command. For each probe, you define the following: * "state"—The state of the probe. * "destination"— The target destination IP address for the probe. * "destinationPort"—Required only if the protocol is "TCP". * "protocol"—The communication protocol between the source and destination. This will be either "TCP" or "ICMP". * "packetSize"—The size of the packets. This must be a number between "56" and "8500". * (Optional) "tags" —Key-value pairs created and assigned to the probe. See also: AWS API Documentation **Request Syntax** response = client.update_probe( monitorName='string', probeId='string', state='PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING'|'DELETED', destination='string', destinationPort=123, protocol='TCP'|'ICMP', packetSize=123 ) Parameters: * **monitorName** (*string*) -- **[REQUIRED]** The name of the monitor that the probe was updated for. * **probeId** (*string*) -- **[REQUIRED]** The ID of the probe to update. * **state** (*string*) -- The state of the probe update. * **destination** (*string*) -- The updated IP address for the probe destination. This must be either an IPv4 or IPv6 address. * **destinationPort** (*integer*) -- The updated port for the probe destination. This is required only if the "protocol" is "TCP" and must be a number between "1" and "65536". * **protocol** (*string*) -- The updated network protocol for the destination. This can be either "TCP" or "ICMP". If the protocol is "TCP", then "port" is also required. * **packetSize** (*integer*) -- he updated packets size for network traffic between the source and destination. This must be a number between "56" and "8500". Return type: dict Returns: **Response Syntax** { 'probeId': 'string', 'probeArn': 'string', 'sourceArn': 'string', 'destination': 'string', 'destinationPort': 123, 'protocol': 'TCP'|'ICMP', 'packetSize': 123, 'addressFamily': 'IPV4'|'IPV6', 'vpcId': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING'|'DELETED', 'createdAt': datetime(2015, 1, 1), 'modifiedAt': datetime(2015, 1, 1), 'tags': { 'string': 'string' } } **Response Structure** * *(dict) --* * **probeId** *(string) --* The updated ID of the probe. * **probeArn** *(string) --* The updated ARN of the probe. * **sourceArn** *(string) --* The updated ARN of the source subnet. * **destination** *(string) --* The updated destination IP address for the probe. * **destinationPort** *(integer) --* The updated destination port. This must be a number between "1" and "65536". * **protocol** *(string) --* The updated protocol for the probe. * **packetSize** *(integer) --* The updated packet size for the probe. * **addressFamily** *(string) --* The updated IP address family. This must be either "IPV4" or "IPV6". * **vpcId** *(string) --* The updated ID of the source VPC subnet ID. * **state** *(string) --* The state of the updated probe. * **createdAt** *(datetime) --* The time and date that the probe was created. * **modifiedAt** *(datetime) --* The time and date that the probe was last updated. * **tags** *(dict) --* Update tags for a probe. * *(string) --* * *(string) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" * "CloudWatchNetworkMonitor.Client.exceptions.ServiceQuotaExceeded Exception" CloudWatchNetworkMonitor / Client / get_waiter get_waiter ********** CloudWatchNetworkMonitor.Client.get_waiter(waiter_name) Returns an object that can wait for some condition. Parameters: **waiter_name** (*str*) -- The name of the waiter to get. See the waiters section of the service docs for a list of available waiters. Returns: The specified waiter object. Return type: "botocore.waiter.Waiter" CloudWatchNetworkMonitor / Client / delete_monitor delete_monitor ************** CloudWatchNetworkMonitor.Client.delete_monitor(**kwargs) Deletes a specified monitor. This action requires the "monitorName" parameter. Run "ListMonitors" to get a list of monitor names. See also: AWS API Documentation **Request Syntax** response = client.delete_monitor( monitorName='string' ) Parameters: **monitorName** (*string*) -- **[REQUIRED]** The name of the monitor to delete. Return type: dict Returns: **Response Syntax** {} **Response Structure** * *(dict) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" CloudWatchNetworkMonitor / Client / create_monitor create_monitor ************** CloudWatchNetworkMonitor.Client.create_monitor(**kwargs) Creates a monitor between a source subnet and destination IP address. Within a monitor you'll create one or more probes that monitor network traffic between your source Amazon Web Services VPC subnets and your destination IP addresses. Each probe then aggregates and sends metrics to Amazon CloudWatch. You can also create a monitor with probes using this command. For each probe, you define the following: * "source"—The subnet IDs where the probes will be created. * "destination"— The target destination IP address for the probe. * "destinationPort"—Required only if the protocol is "TCP". * "protocol"—The communication protocol between the source and destination. This will be either "TCP" or "ICMP". * "packetSize"—The size of the packets. This must be a number between "56" and "8500". * (Optional) "tags" —Key-value pairs created and assigned to the probe. See also: AWS API Documentation **Request Syntax** response = client.create_monitor( monitorName='string', probes=[ { 'sourceArn': 'string', 'destination': 'string', 'destinationPort': 123, 'protocol': 'TCP'|'ICMP', 'packetSize': 123, 'probeTags': { 'string': 'string' } }, ], aggregationPeriod=123, clientToken='string', tags={ 'string': 'string' } ) Parameters: * **monitorName** (*string*) -- **[REQUIRED]** The name identifying the monitor. It can contain only letters, underscores (_), or dashes (-), and can be up to 200 characters. * **probes** (*list*) -- Displays a list of all of the probes created for a monitor. * *(dict) --* Creates a monitor probe. * **sourceArn** *(string) --* **[REQUIRED]** The ARN of the subnet. * **destination** *(string) --* **[REQUIRED]** The destination IP address. This must be either "IPV4" or "IPV6". * **destinationPort** *(integer) --* The port associated with the "destination". This is required only if the "protocol" is "TCP" and must be a number between "1" and "65536". * **protocol** *(string) --* **[REQUIRED]** The protocol used for the network traffic between the "source" and "destination". This must be either "TCP" or "ICMP". * **packetSize** *(integer) --* The size of the packets sent between the source and destination. This must be a number between "56" and "8500". * **probeTags** *(dict) --* The list of key-value pairs created and assigned to the monitor. * *(string) --* * *(string) --* * **aggregationPeriod** (*integer*) -- The time, in seconds, that metrics are aggregated and sent to Amazon CloudWatch. Valid values are either "30" or "60". "60" is the default if no period is chosen. * **clientToken** (*string*) -- Unique, case-sensitive identifier to ensure the idempotency of the request. Only returned if a client token was provided in the request. This field is autopopulated if not provided. * **tags** (*dict*) -- The list of key-value pairs created and assigned to the monitor. * *(string) --* * *(string) --* Return type: dict Returns: **Response Syntax** { 'monitorArn': 'string', 'monitorName': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING', 'aggregationPeriod': 123, 'tags': { 'string': 'string' } } **Response Structure** * *(dict) --* * **monitorArn** *(string) --* The ARN of the monitor. * **monitorName** *(string) --* The name of the monitor. * **state** *(string) --* The state of the monitor. * **aggregationPeriod** *(integer) --* The number of seconds that metrics are aggregated by and sent to Amazon CloudWatch. This will be either "30" or "60". * **tags** *(dict) --* The list of key-value pairs assigned to the monitor. * *(string) --* * *(string) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" * "CloudWatchNetworkMonitor.Client.exceptions.ConflictException" * "CloudWatchNetworkMonitor.Client.exceptions.ServiceQuotaExceeded Exception" CloudWatchNetworkMonitor / Client / close close ***** CloudWatchNetworkMonitor.Client.close() Closes underlying endpoint connections. CloudWatchNetworkMonitor / Client / tag_resource tag_resource ************ CloudWatchNetworkMonitor.Client.tag_resource(**kwargs) Adds key-value pairs to a monitor or probe. See also: AWS API Documentation **Request Syntax** response = client.tag_resource( resourceArn='string', tags={ 'string': 'string' } ) Parameters: * **resourceArn** (*string*) -- **[REQUIRED]** The ARN of the monitor or probe to tag. * **tags** (*dict*) -- **[REQUIRED]** The list of key-value pairs assigned to the monitor or probe. * *(string) --* * *(string) --* Return type: dict Returns: **Response Syntax** {} **Response Structure** * *(dict) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" * "CloudWatchNetworkMonitor.Client.exceptions.ConflictException" CloudWatchNetworkMonitor / Client / delete_probe delete_probe ************ CloudWatchNetworkMonitor.Client.delete_probe(**kwargs) Deletes the specified probe. Once a probe is deleted you'll no longer incur any billing fees for that probe. This action requires both the "monitorName" and "probeId" parameters. Run "ListMonitors" to get a list of monitor names. Run "GetMonitor" to get a list of probes and probe IDs. You can only delete a single probe at a time using this action. See also: AWS API Documentation **Request Syntax** response = client.delete_probe( monitorName='string', probeId='string' ) Parameters: * **monitorName** (*string*) -- **[REQUIRED]** The name of the monitor to delete. * **probeId** (*string*) -- **[REQUIRED]** The ID of the probe to delete. Return type: dict Returns: **Response Syntax** {} **Response Structure** * *(dict) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" * "CloudWatchNetworkMonitor.Client.exceptions.ServiceQuotaExceeded Exception" CloudWatchNetworkMonitor / Client / update_monitor update_monitor ************** CloudWatchNetworkMonitor.Client.update_monitor(**kwargs) Updates the "aggregationPeriod" for a monitor. Monitors support an "aggregationPeriod" of either "30" or "60" seconds. This action requires the "monitorName" and "probeId" parameter. Run "ListMonitors" to get a list of monitor names. See also: AWS API Documentation **Request Syntax** response = client.update_monitor( monitorName='string', aggregationPeriod=123 ) Parameters: * **monitorName** (*string*) -- **[REQUIRED]** The name of the monitor to update. * **aggregationPeriod** (*integer*) -- **[REQUIRED]** The aggregation time, in seconds, to change to. This must be either "30" or "60". Return type: dict Returns: **Response Syntax** { 'monitorArn': 'string', 'monitorName': 'string', 'state': 'PENDING'|'ACTIVE'|'INACTIVE'|'ERROR'|'DELETING', 'aggregationPeriod': 123, 'tags': { 'string': 'string' } } **Response Structure** * *(dict) --* * **monitorArn** *(string) --* The ARN of the monitor that was updated. * **monitorName** *(string) --* The name of the monitor that was updated. * **state** *(string) --* The state of the updated monitor. * **aggregationPeriod** *(integer) --* The changed aggregation period. * **tags** *(dict) --* The list of key-value pairs associated with the monitor. * *(string) --* * *(string) --* **Exceptions** * "CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedExceptio n" * "CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundExce ption" * "CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException" * "CloudWatchNetworkMonitor.Client.exceptions.ValidationException" * "CloudWatchNetworkMonitor.Client.exceptions.InternalServerExcept ion" * "CloudWatchNetworkMonitor.Client.exceptions.ServiceQuotaExceeded Exception"