:doc:`CloudWatchLogs <../../logs>` / Paginator / DescribeQueries

***************
DescribeQueries
***************



.. py:class:: CloudWatchLogs.Paginator.DescribeQueries

  ::

    
    paginator = client.get_paginator('describe_queries')

  
  

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

    Creates an iterator that will paginate through responses from :py:meth:`CloudWatchLogs.Client.describe_queries`.

    See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/logs-2014-03-28/DescribeQueries>`_    


    **Request Syntax**
    ::

      response_iterator = paginator.paginate(
          logGroupName='string',
          status='Scheduled'|'Running'|'Complete'|'Failed'|'Cancelled'|'Timeout'|'Unknown',
          queryLanguage='CWLI'|'SQL'|'PPL',
          PaginationConfig={
              'MaxItems': 123,
              'PageSize': 123,
              'StartingToken': 'string'
          }
      )
      
    :type logGroupName: string
    :param logGroupName: 

      Limits the returned queries to only those for the specified log group.

      

    
    :type status: string
    :param status: 

      Limits the returned queries to only those that have the specified status. Valid values are ``Cancelled``, ``Complete``, ``Failed``, ``Running``, and ``Scheduled``.

      

    
    :type queryLanguage: string
    :param queryLanguage: 

      Limits the returned queries to only the queries that use the specified query language.

      

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

      
      ::

        {
            'queries': [
                {
                    'queryLanguage': 'CWLI'|'SQL'|'PPL',
                    'queryId': 'string',
                    'queryString': 'string',
                    'status': 'Scheduled'|'Running'|'Complete'|'Failed'|'Cancelled'|'Timeout'|'Unknown',
                    'createTime': 123,
                    'logGroupName': 'string'
                },
            ],
            'NextToken': 'string'
        }
        
      **Response Structure**

      

      - *(dict) --* 
        

        - **queries** *(list) --* 

          The list of queries that match the request.

          
          

          - *(dict) --* 

            Information about one CloudWatch Logs Insights query that matches the request in a ``DescribeQueries`` operation.

            
            

            - **queryLanguage** *(string) --* 

              The query language used for this query. For more information about the query languages that CloudWatch Logs supports, see `Supported query languages <https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/CWL_AnalyzeLogData_Languages.html>`__.

              
            

            - **queryId** *(string) --* 

              The unique ID number of this query.

              
            

            - **queryString** *(string) --* 

              The query string used in this query.

              
            

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

              The status of this query. Possible values are ``Cancelled``, ``Complete``, ``Failed``, ``Running``, ``Scheduled``, and ``Unknown``.

              
            

            - **createTime** *(integer) --* 

              The date and time that this query was created.

              
            

            - **logGroupName** *(string) --* 

              The name of the log group scanned by this query.

              
        
      
        

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

          A token to resume pagination.

          
    