Automation Example

Luma Virtual Agent provides a variety of automation workflows. In this article, you will learn how to configure an Automation Workflow related to Powershell Service Configuration as an example. 

Below are the ready-to-use, Out-of-the-box (OOTB) Powershell workflows. You can add these Workflow Services to your Skill as Conversation Item and execute the workflow. 

No.CategoryWorkflow ServiceDescriptionInput ParametersExample
1PowershellLdap DeleteUserDeletes the AD user from LDAPUpdate Message On successMessage to be displayed on deleting the user 
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP SAM Account Name
2PowershellLdap DeleteGroupDeletes the Group from LDAPUpdate Message On successMessage to be displayed on deleting the group
Update Message On FailureMessage to be displayed if an error occurred.
Group SAM Account NameLDAP Group SAM Account Name
3PowershellLdap SearchUserSearch for the user in LDAPUpdate Message On successMessage to be displayed on success
Update Message On FailureMessage to be displayed if an error occurred.
FilterFilter criteria for the search
4PowershellLdap ExistsUserFind if the user already exists in LDAPUpdate Message On successMessage to be displayed on success
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP SAM Account Name
5PowershellLdap Change PasswordResets AD user password for a given login namePasswordNew Password
Update Message On successMessage to be displayed on successful password change
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP SAM Account Name
SMS TOPhone number to which the Self Service Password Reset service sends SMS.
SMS BodySpecify the SMS message to be sent when changing the password
6PowershellLdap enable UserEnables the AD userUpdate Message On successMessage to be displayed on enabling the user
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP SAM Account Name
7PowershellLdap disable UserDisables the AD userUpdate Message On successMessage to be displayed on disabling the user
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP SAM Account Name
8PowershellLdap change password at logon 



Resets AD user password for a given login name at logonPasswordNew Password
Update Message On successMessage to be displayed on successful password change
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP SAM Account Name
SMS TOPhone number to which the Self Service Password Reset service sends SMS.
SMS BodySpecify the SMS message to be sent when changing the password
9PowershellLdap create UserCreates a new user in Active DirectoryPasswordPassword for the new user account
Update Message On successMessage to be displayed on successful creation of user in LDAP
Update Message On FailureMessage to be displayed if an error occurred.
First NameUser's first name
Last NameUser's last name
Login NameUser's login name
User Principal Name
Employee idUser's Employee id
Path
10PowershellLdap Unlock User Unlocks Active Directory (AD) userUpdate Message On successMessage to be displayed on success
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP Account Name to unlock
11PowershellLdap create GroupCreates New Group in Active directory for that AD domainUpdate Message On successMessage to be displayed on success
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP SAM Account Name for Group
Path
Group NameNew Group name
Group CategoryGroup Category
Group ScopeGroup scope
DescriptionGroup Description
12PowershellLdap add User To GroupAdds a user to a groupUpdate Message On successMessage to be displayed on success
Update Message On FailureMessage to be displayed if an error occurred.
Group SAM Account NameLDAP Group SAM Account Name 
User SAM Account NameLDAP User SAM Account Name 
13PowershellAzure execute Powershell ScriptExecutes the Powershell script in the fileUpdate Message On SuccessMessage to be displayed on the successful execution of Powershell script.
Update Message On FailureMessage to be displayed if an error occurred.
File PathPowerShell script file absolute path.

Note: To use the operation, the PowerShell script must be available on the PowerShell machine.
File ParamsParameters required to execute the shell script.

Using Service Workflow in a Skill

Let us look at an example using the Automation workflow service 'Ldap enable User'.

The 'LDAP enable User' Workflow Service enables an end user in LDAP using a PowerShell script. Follow the below steps to configure and use the workflow service:

 

Step 1: Setup Service Configurations

Service Configurations store the information used to connect to the system for automation workflows. Using the Automation Service Configurations page in Luma Bot Builder, you can specify the required login credentials for the specific service to which you want to connect.

Click on  Automation icon and navigate to Automation →  Service Configurations tab.

Following is the list of service configurations:

For any 'Ldap enable User' Workflow, you need to update the following Service Configurations.

  1. Powershell Configuration- The configuration is used to execute powershell script to enable user in LDAP. To use Powershell, following configurations are required: 

    config.powershell.passwordRefers to the machine or environment password where you can execute PowerShell or winrm service is running.
    config.powershell.domainRefers to the machine or environment windows domain name where you can execute PowerShell or winrm service is running.
    config.powershell.usernameRefers to the machine or environment username where you can execute PowerShell or winrm service is running.
    config.powershell.addressRefers to the machine or environment address where you can execute PowerShell or winrm service is running.
  2. Luma 2.x Configurations- To use the workflow service in Luma Virtual Agent. To use Luma 2.x, following configurations are required: 

    config.luma2x.urlThis is the URL to the Luma VSA environment you want to connect to.
    config.luma2x.luma.tenant.externalidRefers to your Luma VSA Tenant External ID
    config.luma2x.luma.api.access.keyRefers to the API access key created in Luma VSA to allow a third party system to connect to your tenant.

For more information refer to Out-of-the-box Automation Operations and Workflows.

Step 2: Using the Workflow Service in SKill

Next step is to create a skill in LumaBot builder to enable a user in LDAP. The skill executes 'Ldap enable User' Workflow. The Workflow requires the following parameters

Ldap enable UserPowershellEnables the AD userUpdate Message On successMessage to be displayed on enabling the user
Update Message On FailureMessage to be displayed if an error occurred.
SAM Account NameLDAP SAM Account Name

When the skill is executed, Luma VA prompts the user to enter the user name to be enabled in LDAP, and the user input is saved in the 'ad_username' attribute. The attribute is linked to the input field 'SAM Account Name' while associating the Automation Workflow to the Skill.

 

During skill execution, the information in the 'ad_username' attribute is passed to the Automation Workflow, which in turn enables the account in AD.


© 2019 Serviceaide 1-650-206-8988 http://www.serviceaide.com info@serviceaide.com