:doc:`SageMaker <../../sagemaker>` / Paginator / ListClusters

************
ListClusters
************



.. py:class:: SageMaker.Paginator.ListClusters

  ::

    
    paginator = client.get_paginator('list_clusters')

  
  

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

    Creates an iterator that will paginate through responses from :py:meth:`SageMaker.Client.list_clusters`.

    See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/sagemaker-2017-07-24/ListClusters>`_    


    **Request Syntax**
    ::

      response_iterator = paginator.paginate(
          CreationTimeAfter=datetime(2015, 1, 1),
          CreationTimeBefore=datetime(2015, 1, 1),
          NameContains='string',
          SortBy='CREATION_TIME'|'NAME',
          SortOrder='Ascending'|'Descending',
          TrainingPlanArn='string',
          PaginationConfig={
              'MaxItems': 123,
              'PageSize': 123,
              'StartingToken': 'string'
          }
      )
      
    :type CreationTimeAfter: datetime
    :param CreationTimeAfter: 

      Set a start time for the time range during which you want to list SageMaker HyperPod clusters. Timestamps are formatted according to the ISO 8601 standard.

       

      Acceptable formats include:

       

      
      * ``YYYY-MM-DDThh:mm:ss.sssTZD`` (UTC), for example, ``2014-10-01T20:30:00.000Z``
       
      * ``YYYY-MM-DDThh:mm:ss.sssTZD`` (with offset), for example, ``2014-10-01T12:30:00.000-08:00``
       
      * ``YYYY-MM-DD``, for example, ``2014-10-01``
       
      * Unix time in seconds, for example, ``1412195400``. This is also referred to as Unix Epoch time and represents the number of seconds since midnight, January 1, 1970 UTC.
      

       

      For more information about the timestamp format, see `Timestamp <https://docs.aws.amazon.com/cli/latest/userguide/cli-usage-parameters-types.html#parameter-type-timestamp>`__ in the *Amazon Web Services Command Line Interface User Guide*.

      

    
    :type CreationTimeBefore: datetime
    :param CreationTimeBefore: 

      Set an end time for the time range during which you want to list SageMaker HyperPod clusters. A filter that returns nodes in a SageMaker HyperPod cluster created before the specified time. The acceptable formats are the same as the timestamp formats for ``CreationTimeAfter``. For more information about the timestamp format, see `Timestamp <https://docs.aws.amazon.com/cli/latest/userguide/cli-usage-parameters-types.html#parameter-type-timestamp>`__ in the *Amazon Web Services Command Line Interface User Guide*.

      

    
    :type NameContains: string
    :param NameContains: 

      Set the maximum number of instances to print in the list.

      

    
    :type SortBy: string
    :param SortBy: 

      The field by which to sort results. The default value is ``CREATION_TIME``.

      

    
    :type SortOrder: string
    :param SortOrder: 

      The sort order for results. The default value is ``Ascending``.

      

    
    :type TrainingPlanArn: string
    :param TrainingPlanArn: 

      The Amazon Resource Name (ARN); of the training plan to filter clusters by. For more information about reserving GPU capacity for your SageMaker HyperPod clusters using Amazon SageMaker Training Plan, see ``CreateTrainingPlan ``.

      

    
    :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**

      
      ::

        {
            'ClusterSummaries': [
                {
                    'ClusterArn': 'string',
                    'ClusterName': 'string',
                    'CreationTime': datetime(2015, 1, 1),
                    'ClusterStatus': 'Creating'|'Deleting'|'Failed'|'InService'|'RollingBack'|'SystemUpdating'|'Updating',
                    'TrainingPlanArns': [
                        'string',
                    ]
                },
            ]
        }
        
      **Response Structure**

      

      - *(dict) --* 
        

        - **ClusterSummaries** *(list) --* 

          The summaries of listed SageMaker HyperPod clusters.

          
          

          - *(dict) --* 

            Lists a summary of the properties of a SageMaker HyperPod cluster.

            
            

            - **ClusterArn** *(string) --* 

              The Amazon Resource Name (ARN) of the SageMaker HyperPod cluster.

              
            

            - **ClusterName** *(string) --* 

              The name of the SageMaker HyperPod cluster.

              
            

            - **CreationTime** *(datetime) --* 

              The time when the SageMaker HyperPod cluster is created.

              
            

            - **ClusterStatus** *(string) --* 

              The status of the SageMaker HyperPod cluster.

              
            

            - **TrainingPlanArns** *(list) --* 

              A list of Amazon Resource Names (ARNs) of the training plans associated with this cluster.

               

              For more information about how to reserve GPU capacity for your SageMaker HyperPod clusters using Amazon SageMaker Training Plan, see ``CreateTrainingPlan ``.

              
              

              - *(string) --* 
          
        
      
    