:doc:`CloudWatchNetworkMonitor <../../networkmonitor>` / Client / tag_resource

************
tag_resource
************



.. py:method:: CloudWatchNetworkMonitor.Client.tag_resource(**kwargs)

  

  Adds key-value pairs to a monitor or probe.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/networkmonitor-2023-08-01/TagResource>`_  


  **Request Syntax**
  ::

    response = client.tag_resource(
        resourceArn='string',
        tags={
            'string': 'string'
        }
    )
    
  :type resourceArn: string
  :param resourceArn: **[REQUIRED]** 

    The ARN of the monitor or probe to tag.

    

  
  :type tags: dict
  :param tags: **[REQUIRED]** 

    The list of key-value pairs assigned to the monitor or probe.

    

  
    - *(string) --* 

    
      - *(string) --* 

      


  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {}
      
    **Response Structure**

    

    - *(dict) --* 
  
  **Exceptions**
  
  *   :py:class:`CloudWatchNetworkMonitor.Client.exceptions.AccessDeniedException`

  
  *   :py:class:`CloudWatchNetworkMonitor.Client.exceptions.ResourceNotFoundException`

  
  *   :py:class:`CloudWatchNetworkMonitor.Client.exceptions.ThrottlingException`

  
  *   :py:class:`CloudWatchNetworkMonitor.Client.exceptions.ValidationException`

  
  *   :py:class:`CloudWatchNetworkMonitor.Client.exceptions.InternalServerException`

  
  *   :py:class:`CloudWatchNetworkMonitor.Client.exceptions.ConflictException`

  