Introduction

A task refers to a single unit of work to be performed in a process.

The following tasks are supported:

  • Send task
  • Script task
  • Service task
  • User task

Creating send tasks

To create a send task:

  1. Go to Process Definitions and click + to create a process definition.
  2. Drag and drop the create task icon onto the canvas.
  3. Click the settings icon and select Send Task.
  4. Double-click on the task to open its Properties panel.
  5. Enter the following details to configure properties and click Save.
    • Provide a name for the task.
    • In the Input field,
      • Enter the $ symbol in the Input field and select the required element ID.
      • Enter dot (.) after the element ID and select the value from the the drop-down list.
    • Click Add/Modify to select the message recipients.
    • Select the notification template from the drop-down list.
      Note: The list displays only those templates that are added as a prerequisite.
    • Select the notification priority from the drop-down list.
      Note: The notification is sent to the user via the notification channel configured in the Notification Preferences.
      Send Task Properties

      Send Task Properties

      .

Creating script tasks

A script task provides output and status. Output is the result of the Ansible command. Status results either in Success or Failure. Using the gateway, Failure leads to a Send message task while Success leads to a Set alert priority task.

Before creating a script task, ensure the following prerequisites are met:

  • Ansible control node deployed in the client environment.
  • Ansible Playbook integration is installed. Add the Playbooks as events in the integration and then add the events to the Process workflow.
  • RBA Script created in OpsRamp.
  • Credentials configured in the client account.

To create a script task:

  1. Drag and drop the create task icon onto the canvas.
  2. Click the settings icon and select Script Task.
  3. Double-click on the task to open its Properties panel.
  4. Provide a name for the task.
  5. From the Configuration section, select one of the following options:
    • Agent: Select this option to run a script on Agent installed devices. The metrics are gathered by the Agent running on Windows or Linux devices.
    • Agentless: Select this option to run a script on standalone devices via Ansible control node.
  6. If you select Agent, configure the following fields:
    1. From the Script Name, select the RBA scripts created as a prerequisite.
    2. From the Resource ID field, enter the $ symbol, select the element ID that you want to use as input, enter a period symbol (.), select the values, and then enter UUID. Example: $StartEvent_1ddiudw.alert.resource.uuid
    3. Select either Default User or Other User as the authorization access for running the script.
      Script Task Agent Properties

      Script Task Agent Properties

  7. If you select Agentless, select the name of Ansible Integration and the Playbook from the drop-down list. The input configured for the selected Playbook appears. If required, modify the Input as required.
  8. Verify the Preview.
Script Task Agentless Properties

Script Task Agentless Properties

Creating service tasks

A service task is used to perform a service. The service is either provided by OpsRamp or an external service.

Prerequisite: Ensure an automation integration is created to call an external service via API or for performing an external integration. See Automation integration for more information.

To create a service task:

  1. Drag and drop the create task icon onto the canvas.
  2. Click the settings icon and select Service Task.
  3. Double-click on the task to open its Properties panel.
  4. Provide a name for the task.
  5. From the Service drop-down menu, select either Platform Service or REST Web Service.
  6. Configure the properties for the respective services.
Service Task REST Web Service Properties

Service Task REST Web Service Properties

Creating user task

Prerequisite

Ensure to turn ON the toggle button from the service desk Notifications List page to send/receive notifications when a user task is created.

To enable the notifications for Task created:

  1. Click All Clients and select a client.
  2. Go to Setup > Service Desk > Automation > Notifications.
  3. Turn ON the toggle button.
  4. Click Yes on the confirmation window.
  5. Click Customize > select the required clients > select the entities to be notified.
  6. Click Add.
Enable notification for Task

Enable notification for Task

To create a user task:

  1. Click All Clients and select a client.
  2. Go to Automation > Process Definitions.
  3. From the Process Definitions page, click + icon.
  4. Drag and drop the start event onto the canvas and configure the start event properties.
  5. Drag and drop the create task icon onto the canvas.
  6. Click the settings icon and select User Task.
  7. Click on the selected user task to open its Properties panel.
  8. Provide a Name for the task.
  9. Enter the Subject, Description, Priority, Due Date, Assigned To, Assignee Group, and values for custom fields (if added).
    Note: The custom fields appear only when added in the Task custom form.
  10. Click Save.
User task properties

User task properties

Viewing a task

When a user task in the process definition is executed, a new service desk entity Task is created and appears in the task list of the assignee/assignee group and on the Service Desk page.

To view a user task on the service desk:

  1. Click All Clients and select a client.
  2. Go to Command Center > Service Desk.
  3. Search for the task using the Task ID.
  4. Click the task ID to view detailed information.
View created task on service desk

View created task on service desk

Configuring multi-instance loop

A multi-instance loop is a process of defining the repetition of a certain task in a process definition. The multi-instance allows the execution of a task sequentially or in parallel.

The following are the tasks that can become multi-instance loops:

  • Send Task
  • Service Task
  • Script Task
  • User Task

To configure a task as a multi-instance loop:

  1. Click All Clients and select a client.
  2. Go to Automation > Process Definitions.
  3. From the Process Definitions page, click + icon.
  4. Drag and drop the start event onto the canvas and configure the start event properties.
  5. Drag and drop the create task icon onto the canvas.
  6. Click the settings icon and select the required task.
  7. Click the settings icon and select either sequential or parallel multi-instance loop.
    Apply multi-instance loop for a task

    Apply multi-instance loop for a task

  8. Click on the selected user task to open its Properties panel.
    1. Provide task details.
    2. From the Multi Instance section, provide the expressions for Collection and Element Variable.
      Enter multi-instance loop values

      Enter multi-instance loop values

  9. End the process flow with an end event and click Save.