:doc:`Backup <../../backup>` / Client / list_tags

*********
list_tags
*********



.. py:method:: Backup.Client.list_tags(**kwargs)

  

  Returns the tags assigned to the resource, such as a target recovery point, backup plan, or backup vault.

   

  This operation returns results depending on the resource type used in the value for ``resourceArn``. For example, recovery points of Amazon DynamoDB with Advanced Settings have an ARN (Amazon Resource Name) that begins with ``arn:aws:backup``. Recovery points (backups) of DynamoDB without Advanced Settings enabled have an ARN that begins with ``arn:aws:dynamodb``.

   

  When this operation is called and when you include values of ``resourceArn`` that have an ARN other than ``arn:aws:backup``, it may return one of the exceptions listed below. To prevent this exception, include only values representing resource types that are fully managed by Backup. These have an ARN that begins ``arn:aws:backup`` and they are noted in the `Feature availability by resource <https://docs.aws.amazon.com/aws-backup/latest/devguide/backup-feature-availability.html#features-by-resource>`__ table.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/backup-2018-11-15/ListTags>`_  


  **Request Syntax**
  ::

    response = client.list_tags(
        ResourceArn='string',
        NextToken='string',
        MaxResults=123
    )
    
  :type ResourceArn: string
  :param ResourceArn: **[REQUIRED]** 

    An Amazon Resource Name (ARN) that uniquely identifies a resource. The format of the ARN depends on the type of resource. Valid targets for ``ListTags`` are recovery points, backup plans, and backup vaults.

    

  
  :type NextToken: string
  :param NextToken: 

    The next item following a partial list of returned items. For example, if a request is made to return ``MaxResults`` number of items, ``NextToken`` allows you to return more items in your list starting at the location pointed to by the next token.

    

  
  :type MaxResults: integer
  :param MaxResults: 

    The maximum number of items to be returned.

    

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

    
    ::

      {
          'NextToken': 'string',
          'Tags': {
              'string': 'string'
          }
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **NextToken** *(string) --* 

        The next item following a partial list of returned items. For example, if a request is made to return ``MaxResults`` number of items, ``NextToken`` allows you to return more items in your list starting at the location pointed to by the next token.

        
      

      - **Tags** *(dict) --* 

        Information about the tags.

        
        

        - *(string) --* 
          

          - *(string) --* 
    
  
  
  **Exceptions**
  
  *   :py:class:`Backup.Client.exceptions.ResourceNotFoundException`

  
  *   :py:class:`Backup.Client.exceptions.InvalidParameterValueException`

  
  *   :py:class:`Backup.Client.exceptions.MissingParameterValueException`

  
  *   :py:class:`Backup.Client.exceptions.ServiceUnavailableException`

  