:doc:`EC2 <../../ec2>` / Client / list_images_in_recycle_bin

**************************
list_images_in_recycle_bin
**************************



.. py:method:: EC2.Client.list_images_in_recycle_bin(**kwargs)

  

  Lists one or more AMIs that are currently in the Recycle Bin. For more information, see `Recycle Bin <https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/recycle-bin.html>`__ in the *Amazon EC2 User Guide*.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/ec2-2016-11-15/ListImagesInRecycleBin>`_  


  **Request Syntax**
  ::

    response = client.list_images_in_recycle_bin(
        ImageIds=[
            'string',
        ],
        NextToken='string',
        MaxResults=123,
        DryRun=True|False
    )
    
  :type ImageIds: list
  :param ImageIds: 

    The IDs of the AMIs to list. Omit this parameter to list all of the AMIs that are in the Recycle Bin. You can specify up to 20 IDs in a single request.

    

  
    - *(string) --* 

    

  :type NextToken: string
  :param NextToken: 

    The token returned from a previous paginated request. Pagination continues from the end of the items returned by the previous request.

    

  
  :type MaxResults: integer
  :param MaxResults: 

    The maximum number of items to return for this request. To get the next page of items, make another request with the token returned in the output. For more information, see `Pagination <https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Query-Requests.html#api-pagination>`__.

    

  
  :type DryRun: boolean
  :param DryRun: 

    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 is ``UnauthorizedOperation``.

    

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

    
    ::

      {
          'Images': [
              {
                  'ImageId': 'string',
                  'Name': 'string',
                  'Description': 'string',
                  'RecycleBinEnterTime': datetime(2015, 1, 1),
                  'RecycleBinExitTime': datetime(2015, 1, 1)
              },
          ],
          'NextToken': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **Images** *(list) --* 

        Information about the AMIs.

        
        

        - *(dict) --* 

          Information about an AMI that is currently in the Recycle Bin.

          
          

          - **ImageId** *(string) --* 

            The ID of the AMI.

            
          

          - **Name** *(string) --* 

            The name of the AMI.

            
          

          - **Description** *(string) --* 

            The description of the AMI.

            
          

          - **RecycleBinEnterTime** *(datetime) --* 

            The date and time when the AMI entered the Recycle Bin.

            
          

          - **RecycleBinExitTime** *(datetime) --* 

            The date and time when the AMI is to be permanently deleted from the Recycle Bin.

            
      
    
      

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

        The token to include in another request to get the next page of items. This value is ``null`` when there are no more items to return.

        
  