:doc:`DeviceFarm <../../devicefarm>` / Client / list_test_grid_sessions

***********************
list_test_grid_sessions
***********************



.. py:method:: DeviceFarm.Client.list_test_grid_sessions(**kwargs)

  

  Retrieves a list of sessions for a  TestGridProject.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/devicefarm-2015-06-23/ListTestGridSessions>`_  


  **Request Syntax**
  ::

    response = client.list_test_grid_sessions(
        projectArn='string',
        status='ACTIVE'|'CLOSED'|'ERRORED',
        creationTimeAfter=datetime(2015, 1, 1),
        creationTimeBefore=datetime(2015, 1, 1),
        endTimeAfter=datetime(2015, 1, 1),
        endTimeBefore=datetime(2015, 1, 1),
        maxResult=123,
        nextToken='string'
    )
    
  :type projectArn: string
  :param projectArn: **[REQUIRED]** 

    ARN of a  TestGridProject.

    

  
  :type status: string
  :param status: 

    Return only sessions in this state.

    

  
  :type creationTimeAfter: datetime
  :param creationTimeAfter: 

    Return only sessions created after this time.

    

  
  :type creationTimeBefore: datetime
  :param creationTimeBefore: 

    Return only sessions created before this time.

    

  
  :type endTimeAfter: datetime
  :param endTimeAfter: 

    Return only sessions that ended after this time.

    

  
  :type endTimeBefore: datetime
  :param endTimeBefore: 

    Return only sessions that ended before this time.

    

  
  :type maxResult: integer
  :param maxResult: 

    Return only this many results at a time.

    

  
  :type nextToken: string
  :param nextToken: 

    Pagination token.

    

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

    
    ::

      {
          'testGridSessions': [
              {
                  'arn': 'string',
                  'status': 'ACTIVE'|'CLOSED'|'ERRORED',
                  'created': datetime(2015, 1, 1),
                  'ended': datetime(2015, 1, 1),
                  'billingMinutes': 123.0,
                  'seleniumProperties': 'string'
              },
          ],
          'nextToken': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **testGridSessions** *(list) --* 

        The sessions that match the criteria in a  ListTestGridSessionsRequest.

        
        

        - *(dict) --* 

          A  TestGridSession is a single instance of a browser launched from the URL provided by a call to  CreateTestGridUrl.

          
          

          - **arn** *(string) --* 

            The ARN of the session.

            
          

          - **status** *(string) --* 

            The state of the session.

            
          

          - **created** *(datetime) --* 

            The time that the session was started.

            
          

          - **ended** *(datetime) --* 

            The time the session ended.

            
          

          - **billingMinutes** *(float) --* 

            The number of billed minutes that were used for this session.

            
          

          - **seleniumProperties** *(string) --* 

            A JSON object of options and parameters passed to the Selenium WebDriver.

            
      
    
      

      - **nextToken** *(string) --* 

        Pagination token.

        
  
  **Exceptions**
  
  *   :py:class:`DeviceFarm.Client.exceptions.NotFoundException`

  
  *   :py:class:`DeviceFarm.Client.exceptions.ArgumentException`

  
  *   :py:class:`DeviceFarm.Client.exceptions.InternalServiceException`

  