:doc:`GreengrassV2 <../../greengrassv2>` / Paginator / ListDeployments

***************
ListDeployments
***************



.. py:class:: GreengrassV2.Paginator.ListDeployments

  ::

    
    paginator = client.get_paginator('list_deployments')

  
  

  .. py:method:: paginate(**kwargs)

    Creates an iterator that will paginate through responses from :py:meth:`GreengrassV2.Client.list_deployments`.

    See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/greengrassv2-2020-11-30/ListDeployments>`_    


    **Request Syntax**
    ::

      response_iterator = paginator.paginate(
          targetArn='string',
          historyFilter='ALL'|'LATEST_ONLY',
          parentTargetArn='string',
          PaginationConfig={
              'MaxItems': 123,
              'PageSize': 123,
              'StartingToken': 'string'
          }
      )
      
    :type targetArn: string
    :param targetArn: 

      The `ARN <https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html>`__ of the target IoT thing or thing group.

      

    
    :type historyFilter: string
    :param historyFilter: 

      The filter for the list of deployments. Choose one of the following options:

       

      
      * ``ALL`` – The list includes all deployments.
       
      * ``LATEST_ONLY`` – The list includes only the latest revision of each deployment.
      

       

      Default: ``LATEST_ONLY``

      

    
    :type parentTargetArn: string
    :param parentTargetArn: 

      The parent deployment's target `ARN <https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html>`__ within a subdeployment.

      

    
    :type PaginationConfig: dict
    :param PaginationConfig: 

      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.

        

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

      
      ::

        {
            'deployments': [
                {
                    'targetArn': 'string',
                    'revisionId': 'string',
                    'deploymentId': 'string',
                    'deploymentName': 'string',
                    'creationTimestamp': datetime(2015, 1, 1),
                    'deploymentStatus': 'ACTIVE'|'COMPLETED'|'CANCELED'|'FAILED'|'INACTIVE',
                    'isLatestForTarget': True|False,
                    'parentTargetArn': 'string'
                },
            ],
            'NextToken': 'string'
        }
        
      **Response Structure**

      

      - *(dict) --* 
        

        - **deployments** *(list) --* 

          A list that summarizes each deployment.

          
          

          - *(dict) --* 

            Contains information about a deployment.

            
            

            - **targetArn** *(string) --* 

              The `ARN <https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html>`__ of the target IoT thing or thing group. When creating a subdeployment, the targetARN can only be a thing group.

              
            

            - **revisionId** *(string) --* 

              The revision number of the deployment.

              
            

            - **deploymentId** *(string) --* 

              The ID of the deployment.

              
            

            - **deploymentName** *(string) --* 

              The name of the deployment.

              
            

            - **creationTimestamp** *(datetime) --* 

              The time at which the deployment was created, expressed in ISO 8601 format.

              
            

            - **deploymentStatus** *(string) --* 

              The status of the deployment.

              
            

            - **isLatestForTarget** *(boolean) --* 

              Whether or not the deployment is the latest revision for its target.

              
            

            - **parentTargetArn** *(string) --* 

              The parent deployment's target `ARN <https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html>`__ within a subdeployment.

              
        
      
        

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

          A token to resume pagination.

          
    