:doc:`AppStream <../../appstream>` / Paginator / DescribeSessions

****************
DescribeSessions
****************



.. py:class:: AppStream.Paginator.DescribeSessions

  ::

    
    paginator = client.get_paginator('describe_sessions')

  
  

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

    Creates an iterator that will paginate through responses from :py:meth:`AppStream.Client.describe_sessions`.

    See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/appstream-2016-12-01/DescribeSessions>`_    


    **Request Syntax**
    ::

      response_iterator = paginator.paginate(
          StackName='string',
          FleetName='string',
          UserId='string',
          AuthenticationType='API'|'SAML'|'USERPOOL'|'AWS_AD',
          InstanceId='string',
          PaginationConfig={
              'MaxItems': 123,
              'PageSize': 123,
              'StartingToken': 'string'
          }
      )
      
    :type StackName: string
    :param StackName: **[REQUIRED]** 

      The name of the stack. This value is case-sensitive.

      

    
    :type FleetName: string
    :param FleetName: **[REQUIRED]** 

      The name of the fleet. This value is case-sensitive.

      

    
    :type UserId: string
    :param UserId: 

      The user identifier (ID). If you specify a user ID, you must also specify the authentication type.

      

    
    :type AuthenticationType: string
    :param AuthenticationType: 

      The authentication method. Specify ``API`` for a user authenticated using a streaming URL or ``SAML`` for a SAML federated user. The default is to authenticate users using a streaming URL.

      

    
    :type InstanceId: string
    :param InstanceId: 

      The identifier for the instance hosting the session.

      

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

      
      ::

        {
            'Sessions': [
                {
                    'Id': 'string',
                    'UserId': 'string',
                    'StackName': 'string',
                    'FleetName': 'string',
                    'State': 'ACTIVE'|'PENDING'|'EXPIRED',
                    'ConnectionState': 'CONNECTED'|'NOT_CONNECTED',
                    'StartTime': datetime(2015, 1, 1),
                    'MaxExpirationTime': datetime(2015, 1, 1),
                    'AuthenticationType': 'API'|'SAML'|'USERPOOL'|'AWS_AD',
                    'NetworkAccessConfiguration': {
                        'EniPrivateIpAddress': 'string',
                        'EniIpv6Addresses': [
                            'string',
                        ],
                        'EniId': 'string'
                    },
                    'InstanceId': 'string'
                },
            ],
            
        }
        
      **Response Structure**

      

      - *(dict) --* 
        

        - **Sessions** *(list) --* 

          Information about the streaming sessions.

          
          

          - *(dict) --* 

            Describes a streaming session.

            
            

            - **Id** *(string) --* 

              The identifier of the streaming session.

              
            

            - **UserId** *(string) --* 

              The identifier of the user for whom the session was created.

              
            

            - **StackName** *(string) --* 

              The name of the stack for the streaming session.

              
            

            - **FleetName** *(string) --* 

              The name of the fleet for the streaming session.

              
            

            - **State** *(string) --* 

              The current state of the streaming session.

              
            

            - **ConnectionState** *(string) --* 

              Specifies whether a user is connected to the streaming session.

              
            

            - **StartTime** *(datetime) --* 

              The time when a streaming instance is dedicated for the user.

              
            

            - **MaxExpirationTime** *(datetime) --* 

              The time when the streaming session is set to expire. This time is based on the ``MaxUserDurationinSeconds`` value, which determines the maximum length of time that a streaming session can run. A streaming session might end earlier than the time specified in ``SessionMaxExpirationTime``, when the ``DisconnectTimeOutInSeconds`` elapses or the user chooses to end his or her session. If the ``DisconnectTimeOutInSeconds`` elapses, or the user chooses to end his or her session, the streaming instance is terminated and the streaming session ends.

              
            

            - **AuthenticationType** *(string) --* 

              The authentication method. The user is authenticated using a streaming URL ( ``API``) or SAML 2.0 federation ( ``SAML``).

              
            

            - **NetworkAccessConfiguration** *(dict) --* 

              The network details for the streaming session.

              
              

              - **EniPrivateIpAddress** *(string) --* 

                The private IP address of the elastic network interface that is attached to instances in your VPC.

                
              

              - **EniIpv6Addresses** *(list) --* 

                The IPv6 addresses assigned to the elastic network interface. This field supports IPv6 connectivity for WorkSpaces Applications instances.

                
                

                - *(string) --* 
            
              

              - **EniId** *(string) --* 

                The resource identifier of the elastic network interface that is attached to instances in your VPC. All network interfaces have the eni-xxxxxxxx resource identifier.

                
          
            

            - **InstanceId** *(string) --* 

              The identifier for the instance hosting the session.

              
        
      
    