:doc:`NeptuneGraph <../../neptune-graph>` / Client / list_queries

************
list_queries
************



.. py:method:: NeptuneGraph.Client.list_queries(**kwargs)

  

  Lists active openCypher queries.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/neptune-graph-2023-11-29/ListQueries>`_  


  **Request Syntax**
  ::

    response = client.list_queries(
        graphIdentifier='string',
        maxResults=123,
        state='ALL'|'RUNNING'|'WAITING'|'CANCELLING'
    )
    
  :type graphIdentifier: string
  :param graphIdentifier: **[REQUIRED]** 

    The unique identifier of the Neptune Analytics graph.

    

  
  :type maxResults: integer
  :param maxResults: **[REQUIRED]** 

    The maximum number of results to be fetched by the API.

    

  
  :type state: string
  :param state: 

    Filtered list of queries based on state.

    

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

    
    ::

      {
          'queries': [
              {
                  'id': 'string',
                  'queryString': 'string',
                  'waited': 123,
                  'elapsed': 123,
                  'state': 'RUNNING'|'WAITING'|'CANCELLING'
              },
          ]
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

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

        A list of current openCypher queries.

        
        

        - *(dict) --* 

          Details of the query listed.

          
          

          - **id** *(string) --* 

            A string representation of the id of the query.

            
          

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

            The actual query text. The ``queryString`` may be truncated if the actual query string is too long.

            
          

          - **waited** *(integer) --* 

            The amount of time, in milliseconds, the query has waited in the queue before being picked up by a worker thread.

            
          

          - **elapsed** *(integer) --* 

            The running time of the query, in milliseconds.

            
          

          - **state** *(string) --* 

            State of the query.

            
      
    
  
  **Exceptions**
  
  *   :py:class:`NeptuneGraph.Client.exceptions.ThrottlingException`

  
  *   :py:class:`NeptuneGraph.Client.exceptions.ValidationException`

  
  *   :py:class:`NeptuneGraph.Client.exceptions.AccessDeniedException`

  
  *   :py:class:`NeptuneGraph.Client.exceptions.InternalServerException`

  