You've landed on our support article. If you are looking to learn about automations in Freshservice, check out our IT Automations page.



Workflow Automator allows you to automate all the repetitive tasks and manual processes that you perform on a daily basis. This includes processes like assigning tickets to the right agent or team, following up on approval, and so on. With the Workflow Automator, you can create a workflow using simple drag and drop actions. 



Components of a workflow


A workflow is made up of three components: 

  • Event - defines when a workflow has to be triggered
  • Condition - defines the parameter(s) that needs to be validated during the execution of a workflow
  • Action - The outcome of the workflow
  • Reader Node - The reader nodes are used to read and reference information from the custom objects into the workflows


It is not necessary that a workflow should have only one condition or an action. You can add multiple conditions and actions to a workflow. (We’ll be seeing this later with a detailed example). 



To create a workflow:

  1. Head to Admin > Helpdesk Productivity > Workflow Automator
  2. Click on the New Automator button on the top right corner and choose the module for which you wish to create a workflow. For example, if you wish to create a new ticket workflow, click on the New Automator drop down and click on Ticket
  3. Provide a name and description for your workflow. A description would be helpful for other admins to understand why the workflow was created. 
  4. The next step is to set up an event. This is where you set up when the workflow has to be triggered. 
  5. Choose the conditions to trigger the workflow and click Done
  6. The next step is to add a condition. This is where you provide a set of parameters to the workflow. The workflow, after being triggered, will check for the parameters. Upon the validation of the parameters, the workflow will perform the defined action.
  7. To add a condition, click on the condition icon, drag and place it next to the event. 
  8. Choose the parameters for validation and click Done. If you wish to add additional parameters, click on Add New condition present at the bottom of the dialog box. 
  9. The next and final step in creating a workflow is to add an action. Click on the Action icon, drag and place it next to the condition. 
  10. Choose the action that you want your workflow to perform and click Done
  11. Now, the workflow is complete. As you keep adding conditions and actions, the Automator will automatically save the workflow as a draft. If you wish to activate the workflow, you can click on Activate.


The above-mentioned steps will help you in creating a workflow. But, in order to understand the level of flexibility offered by the Workflow Automator, let’s take a look at a few examples. 


To gain more clarity on how to set up a workflow, watch the video. 




Scenario 1: Routing tickets to a specific team


Let’s take a scenario where you wish to route all hardware related tickets to a dedicated hardware team. To convert this into a workflow, 


  • Head to Admin > Helpdesk Productivity > Workflow Automator > New Workflow > Ticket 
  • Provide a name and description for the workflow.



  • Choose the options in such a way the workflow is triggered whenever a ticket is created. Select the options Ticket is and Raised. 



  • Provide a label to the event and click Done
  • Now, your screen will look like this



  • Drag a condition icon and place it next to the event. 
  • Select the parameter if Category is and choose the value Hardware



  • Provide a label for the condition and click Done.


 


  • Drag an action and place it next to the condition. 
  • Select the option Assign to group and choose Hardware Team




  • Provide a label and click Done



Now, the workflow to assign all hardware related tickets to the hardware team is ready. The workflow will be triggered when a ticket is created and it will check whether the category is ‘hardware’. If yes, then the ticket will be assigned to the hardware to the hardware team. 


Now, in the next scenario, we’ll go a little further and see how this workflow can be used to assign tickets of different categories to different teams. 


Scenario 2: Routing tickets to different teams


Let’s take a scenario where you want to assign hardware, software, and network-related tickets to hardware, software, and network teams. Let’s take the workflow discussed in the previous scenario and see how we can customize it assign tickets to multiple teams. 


Follow the below-mentioned steps to expand the previous workflow to accomplish more. 

  • Drag a condition and place it at the bottom of the previously existing condition. 
  • Set the parameter if Category is and choose the value Software



  • Provide a label and click Done
  • Drag an action and place it next to the condition. 
  • Select the option Assign to group and choose Software Team.



  • You can follow the same step to assign network related issues to the network team. 



Scenario 3: Setting up Multi-stage approval


Consider a scenario where you want to set up a multi-stage approval process. Whenever an employee requests a laptop priced higher than $1500 dollars, the request needs approval from the employee’s reporting manager and the company’s IT head. 


To set up this workflow:

  1. Set the workflow to be triggered when a ticket is created. 
  2. Add a condition and set the parameter when Type is Service Request
  3. Add another condition and choose the parameters When a service request includes any Apple Macbook
  4. Choose Cost under sub condition and enter the value 1500.

  5. Add an action and choose the options Send approval email to and Reporting Manager. Provide a label and click Done. 
  6. This completes setting up the first stage of approval. 
  7. To add the second stage of approval, add another condition and choose the parameters when Request Approval is Approved. 
  8. Add another action next to the newly added condition and choose the option Send approval email to and IT head. 
  9. In the event of notifying the requester through email, you can add another action and choose the option Send email to Requester. Enter the subject and add the content for the email and include placeholders wherever necessary. 
  10. Provide a label and click Done



Saving a workflow


As you keep adding conditions and actions, the automator will automatically save the workflow as a draft. If you wish to activate the workflow, you can click on Activate.


Editing a workflow


You can click any part of a workflow: an event, a condition, or an action and make changes to the selected conditions and parameters. 


Deleting a workflow


 You can now choose to delete either a YES/ NO condition branch (or) delete an action in a workflow.



Cloning a workflow


You can clone an existing workflow and make necessary changes to it. To clone a workflow, 


  1. Go to Settings > Workflow Automator
  2. Select the workflow which you would like to clone and click on Clone



  3. Provide a name for the new workflow and enter a description. 
  4. Now, the workflow will be cloned under a new name.
  5. Make necessary changes to the event, condition, or action and save your workflow. 


Cloning a Node


Configuring workflows for different business use cases might require multiple nodes with almost the same values and manually creating these nodes repeatedly is a tedious process. 

You can now Copy/Clone a Node and configure automations faster by being able to copy multiple nodes with the same value in a click. The provision is applicable to all event, condition, action, app and reader nodes.


To clone a node:

  1. Hover on a node or even after opening the side model you will notice a 'Clone’ button. 
  2. Click the button to copy the entire node data & drop it wherever you want it within the same workflow. 
  3. Once copied it will act as a normal node.

 


Enabling/Disabling a workflow


A workflow, when created, will be saved as a draft. If you wish to activate the workflow, click on the Save and Activate button on the top right corner. The workflow will now be activated. You can then use the toggle switch to enable/disable the workflow. 



Reader Nodes 


Before Using Reader Node

Click on the image to zoom in

After Using Reader Nodes
Click on the image to zoom in





What are Reader Nodes?


Let’s say you want to route your service request based on the service item requested. 



The reader nodes are used to read and reference information from the custom objects into the workflows. You can create conditions based on which a record is read into workflows from the custom objects. 


For example, if a service request was raised requesting for a Macbook, the reader node can read the record from the business object by matching the service item information, and returns the right agent groups and approvers to route the request to.



Note: 

  • The reader node returns only one record. If multiple records match your conditions the reader node returns only the first record. You can choose a sorting order to ensure that the first record is picked right in such conditions.
  • You can set up only up to 10 filter by conditions in the reader node. Please note that, if you are using dependent fields like category, every dependent field is considered as a unique condition. 


To learn more about custom objects and reader nodes, you can refer to the articles here.


JSON Parser Node



The JSON Parser node enables you to parse any JSON payload within the context of the workflow and use the outputs with subsequent conditions and actions.
You can use the JSON Parser node right away to work with JSON outputs from app actions that get custom attributes from GSuite, Okta and JIRA... Looking ahead you will also be able to use this to parse rest API responses within the workflow automation. Learn More

Image: Left side: The source of the payload and a sample JSON payload is configured
Right side: Outputs can be generated automatically or configured manually using JSON path expressions.
 



Image: The outputs configured in the JSON parser node can be referenced and used in the subsequent nodes