:doc:`KendraRanking <../../kendra-ranking>` / Client / tag_resource

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



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

  

  Adds a specified tag to a specified rescore execution plan. A rescore execution plan is an Amazon Kendra Intelligent Ranking resource used for provisioning the ``Rescore`` API. If the tag already exists, the existing value is replaced with the new value.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/kendra-ranking-2022-10-19/TagResource>`_  


  **Request Syntax**
  ::

    response = client.tag_resource(
        ResourceARN='string',
        Tags=[
            {
                'Key': 'string',
                'Value': 'string'
            },
        ]
    )
    
  :type ResourceARN: string
  :param ResourceARN: **[REQUIRED]** 

    The Amazon Resource Name (ARN) of the rescore execution plan to tag.

    

  
  :type Tags: list
  :param Tags: **[REQUIRED]** 

    A list of tag keys to add to a rescore execution plan. If a tag already exists, the existing value is replaced with the new value.

    

  
    - *(dict) --* 

      A key-value pair that identifies or categorizes a rescore execution plan. A rescore execution plan is an Amazon Kendra Intelligent Ranking resource used for provisioning the ``Rescore`` API. You can also use a tag to help control access to a rescore execution plan. A tag key and value can consist of Unicode letters, digits, white space, and any of the following symbols: _ . : / = + - @.

      

    
      - **Key** *(string) --* **[REQUIRED]** 

        The key for the tag. Keys are not case sensitive and must be unique.

        

      
      - **Value** *(string) --* **[REQUIRED]** 

        The value associated with the tag. The value can be an empty string but it can't be null.

        

      
    

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

    
    ::

      {}
      
    **Response Structure**

    

    - *(dict) --* 

      If the action is successful, the service sends back an HTTP 200 response with an empty HTTP body.

      
  
  **Exceptions**
  
  *   :py:class:`KendraRanking.Client.exceptions.ValidationException`

  
  *   :py:class:`KendraRanking.Client.exceptions.ResourceUnavailableException`

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

  
  *   :py:class:`KendraRanking.Client.exceptions.AccessDeniedException`

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

  