Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2

This page details the steps to create a new Automation workflow.

Note

If you are just updating an out-of-the-box workflow, then go to Step 2 directly.

Step 1: Create a new Automation Workflow

  1. As an Administrator, click the  Automation icon.
    The Automation page appears.
  2. Click the Workflows tab.
  3. Click New Workflow.
  4. Provide a Name and Description to your workflow and click Save
    The new Automation workflow appears in the Workflows list.
  5. Click the workflow Name to start designing the workflow.

Note

When you click on any workflow, the Automation Workflow Designer opens in a new tab. If that does not happen, please open a Support Ticket or send an email to support@serviceaide.com.

Workflow Name must be unique

Ensure that the Workflow Name is unique, the system does not allow creating a duplicate Workflow Name. If a Workflow is deleted, even then a new Workflow with the same name cannot be created. The name is cached and hence a duplicate is not allowed.

Step 2 : Design the Workflow by adding Operations

  1. On the Workflows tab, click the Name link to open your workflow in the Automation Workflow Designer.
    basic workflow with a Start and Stop point appears on the canvas.
  2. Click Call Service + on the left pane to add an Operation to the canvas.
  3. Double-click the Call Service entity just added, to open the Call Service Activity Configuration window and configure it.



  4. Configure the Activity Details:
    1. Specify the name of the Operation under Activity Name field.
    2. The Activity Id is set automatically.
    3. Add a description under Activity Purpose field.
    4. Select an OOTB Operation from the 'Select a Service' list. A complete list of OOTB Operations is available at Out-of-the-box Automation Operations and Workflows.



    5. Click Next to go to the next tab.
  5. Configure the Service Input for the Operation in the Workflow.
    1. Define the Service Inputs that the Operation will receive from an external system, which it will then use to execute the task. For example, to Reset AD User password, the inputs the Operation will need is sAMAccountName of AD User, which will be passed from the skill attribute to the workflow. Input is an object that consists of all input fields and you can use it by typing input.field_name.



    2. Click Save Draft on the Workflow Designer to save the changes.
  6. In the above step you configured one operation. Similarly, you can create multiple operations within the same workflow.
  7. Define the sequence of your automation workflow by connecting the Start, Stop points and the Operations.



  8. Defining the Start Activity Data

    This is a requirement only when you are creating a new Automation Workflow. (For OOTB workflows this is already completed.)
    1. Go to the Start step and double-click to open Start. It consists of the JSON Schema and Input tabs. The JSON Schema tab contains the details of all the inputs that the workflow will need. It defines which input parameters are required (mandatory), which parameters are optional and what are the data-types (string, number etc) of each input parameter. The Input tab should contain a super set list of all the input parameters that the workflow will need.



    2. First go to the Input tab and add all Input Parameters that are required for the various operations in your workflow.
    3. For example in the sample workflow below there are two operations. Operation 1 has input parameters requestor and login_name. Operation 2 has input parameters requestor, and to. In that case a super set of all the input parameters must be defined under the Input tab of Start step as shown in the following screenshot. Manually enter the input parameters under the Service Input tab. Remember to write the parameters inside curly brackets {}. Multiple parameters are separated by a comma.



    4. After this click the i button on the top right corner. 

    5. This will open a website in a new browser tab, to generate the JSON Schema. Under the Sample JSON Document area, copy and paste all your input parameters and click Generate Schema.

    6. The JSON data is generated in the section below, as seen below.



    7. Copy this Infered JSON Schema and paste it into the Workflow Designer - Start step >> JSON Schema tab.


    8. Click Next, then click Submit. This saves the Start Activity data. For a custom or newly created workflow, if this step is not completed, then the input parameters defined in Automation Workflow will not be mapped with parameters of the automation workflow. 
  9. Click Publish to publish your Automation workflow.

Define the Inputs or Outputs for an Operation

  1. Pass inputs to the operation from the user or an earlier branch:

@{input.field_name}: defines that input object holds the user input fields

Example: @{input.login_name} indicates login_name is a user input

      2. Use the output from an operation as input for another operation:

You can use the output from an operation as inputs for another operation. 

Some of the output fields that can be used in the next activity are:

  • exit-code   
  • user_message
  • error (in case of failure of operation)

The syntax to use is: 

@{activity_id.output['exit-code']}: will print the exit code from the operation.

@{activity_id.output['user_message']}: will print the user message from the operation.

@{activity_id.output['error']}: will print the error from the operation where activity_id is the ID of the step whose output will be used.

Example:

 Hence the syntax used for output will be:  

@{disable_ad_user.output['exit-code']}

@{disable_ad_user.output['user_message']}

@{disable_ad_user.output['error']}

Step 3: Update the Service Configurations

In order to execute a workflow, the system will need some configurations such as how to connect to the system where the automated task will be executed. You can store these configurations under the Service Configurations.

  1. Click the  Automation icon.
    The Automation page appears.
  2. Click the Service Configurations tab.
  3. Identify the appropriate Service Configuration you need to update. Refer to the table listed in Annexure I to understand which Service Configuration is related to which Operation.
  4. Click the Edit icon to edit the records.


  5.  If you want to input an encrypted value in the configurations, use the Encryption Utility provided. Add the data in Text to Encrypt field and click Encrypt.


    The Encrypted text appears in the field below.
  6. Click Copy to copy the encrypted text to the clipboard.


  7. Paste it under appropriate tag on the left pane.
  8. Click Save to save your Service Configuration.

    Note

    Note that the Service Configuration is internally linked to the appropriate Operation. Administrator does not need to relate or link them.

Step 4 : Publish Automation workflow as a Service

In order to consume the Workflow, you need to publish the workflow as a Service. Following are the steps to do that:

  1. On the Automation page, click the Workflow Services tab.
  2. Click New Workflow Service as shown below.

    The Workflow Services page appears as shown below.
  3. Select your Workflow from the list.
  4. Provide the Name to your workflow service.
  5. Provide the workflow Description.
  6. Select the Orchestration Server as default. The Orchestration server should be set to 'default' if you are using the SaaS version of Automation. If you have deployed the Automation server on-premise, then the details have to be specified here.
  7. Click Save & Next.
    The Attributes tab appears.
  8. Click Add Text Attribute to add the attribute information.
    The Add Text Attribute pop-up window appears as shown below.

  9. Specify the attribute Field ID.
  10. System automatically populates the Field ID as the attribute Name.
  11. You can choose whether a Placeholder is required for the attribute.
  12. Click Save to save the changes.

Step 5 : Add the Automation Service into Ticket Workflow

You can link your Automation Workflow Service to a skill so that the automation task gets executed.

Refer to the steps listed at Execute an Automation Service from a Ticket Workflow.

Annexure I: OOTB Operations and their corresponding Service Configurations


Operation NameInput NameService Configurations
1Disable AD UserLogin Namesa_default_configurations
active_directory_configuration
2Add AD User to GroupLogin Namesa_default_configurations
Group Nameactive_directory_configuration
3Create AD User


Login Namesa_default_configurations
First Name
Last Nameactive_directory_configuration
Employee ID
4 Unlock AD UserLogin Namesa_default_configurations
active_directory_configuration
5Delete AD UserLogin Namesa_default_configurations
active_directory_configuration
6Reset AD User PasswordLogin Namesa_default_configurations
Mobile Numberactive_directory_configuration
7Create AD Group

Group Namesa_default_configurations
Group Descriptionactive_directory_configuration
New Sam Account Name for Group
8Enable AD UserLogin Namesa_default_configurations
active_directory_configuration
9Check Linux file existsFile Namesa_default_configurations
Directory pathlinux_configuration
10Execute Shell ScriptShell script file absolute pathsa_default_configurations
linux_configuration
11Compare two files in LinuxAbsolute path of file onesa_default_configurations
Absolute path of file twolinux_configuration
12 Stop Windows ServiceWindows Service Namesa_default_configurations
active_directory_configuration
13Windows Service StatusWindows Service Namesa_default_configurations
active_directory_configuration
14Start Windows ServiceWindows Service Namesa_default_configurations
active_directory_configuration
15Execute Power ShellPower Shell script absolute pathsa_default_configurations
active_directory_configuration
16Create VMware Snapshot 

VM Namesa_default_configurations
New Snapshot Namevmware_configuration
New Snapshot Description
17Clone VMware InstanceNew VM Namesa_default_configurations
Existing VM Namevmware_configuration
18Delete VM Single SnapshotVM Namesa_default_configurations
VM Snapshot Namevmware_configuration
19Revert Snapshot of VM InstanceVM Namesa_default_configurations
VM Snapshot Namevmware_configuration
20Delete VM InstanceExisting VM Namesa_default_configurations
vmware_configuration
21Stop VMware InstanceExisting VM Namesa_default_configurations
vmware_configuration
22Start VMware InstanceExisting VM Namesa_default_configurations
vmware_configuration
23ISM Service request update statusTicket Status (Ex: Resolved)sa_default_configurations
24ISM Create Service Request





Requestor For Namesa_default_configurations





Parent Request ID
Request Details
Request Description
Request Category
Request Class
Requestor Name
25ISM add worklogWorklog Descriptionsa_default_configurations
26Send Twilio SMSMobile Numbersms_and_email_configuration
Messagesa_default_configurations
Note: Below two inputs field/s are common for all Operations
ticket_idticket_type
  • No labels