:doc:`SnowDeviceManagement <../../snow-device-management>` / Client / list_tasks

**********
list_tasks
**********



.. py:method:: SnowDeviceManagement.Client.list_tasks(**kwargs)

  

  Returns a list of tasks that can be filtered by state.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/snow-device-management-2021-08-04/ListTasks>`_  


  **Request Syntax**
  ::

    response = client.list_tasks(
        maxResults=123,
        nextToken='string',
        state='IN_PROGRESS'|'CANCELED'|'COMPLETED'
    )
    
  :type maxResults: integer
  :param maxResults: 

    The maximum number of tasks per page.

    

  
  :type nextToken: string
  :param nextToken: 

    A pagination token to continue to the next page of tasks.

    

  
  :type state: string
  :param state: 

    A structure used to filter the list of tasks.

    

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

    
    ::

      {
          'nextToken': 'string',
          'tasks': [
              {
                  'state': 'IN_PROGRESS'|'CANCELED'|'COMPLETED',
                  'tags': {
                      'string': 'string'
                  },
                  'taskArn': 'string',
                  'taskId': 'string'
              },
          ]
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

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

        A pagination token to continue to the next page of tasks.

        
      

      - **tasks** *(list) --* 

        A list of task structures containing details about each task.

        
        

        - *(dict) --* 

          Information about the task assigned to one or many devices.

          
          

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

            The state of the task assigned to one or many devices.

            
          

          - **tags** *(dict) --* 

            Optional metadata that you assign to a resource. You can use tags to categorize a resource in different ways, such as by purpose, owner, or environment.

            
            

            - *(string) --* 
              

              - *(string) --* 
        
      
          

          - **taskArn** *(string) --* 

            The Amazon Resource Name (ARN) of the task.

            
          

          - **taskId** *(string) --* 

            The task ID.

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

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

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

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

  