Solved

Workflows for tasks

  • 31 July 2023
  • 6 replies
  • 129 views

Userlevel 7
Badge +13

Hello everyone, 

I haven’t done that much of workflow automations(WFA) for tasks. 

I was helping a customer who wanted to create an asset from a Task WFA.
Thought it was going to be easy, just do a web request and API. But the task module don’t have that...

I hade to use the action node and do a web hook on the parent ticket. Downside is that I can’t see if it failed or do anything about the respons from the API. 
I hade to hard code the payload due I couldn’t use a custom object to control the flow, 

I added this, please vote if you think we need all standard nodes in the task modul as well, 

 

icon

Best answer by Daniel Söderlund 11 September 2023, 08:09

View original

6 replies

I have been investigating a similar use case. Completed tasks within the workflow would trigger additional actions within the workflow. Below is a semi step by step process for this

Using the powershell module with the following code will return Json data that can be used with the parser 

 

$APIKey = 'APIKEYHERE'
$EncodedCredentials = [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes(("{0}:{1}" -f $APIKey,$null)))
$Global:FSHTTPHeaders = @{}
$Global:FSHTTPHeaders.Add('Authorization', ("Basic {0}" -f $EncodedCredentials))
$Global:FSHTTPHeaders.Add('Content-Type', 'application/json')
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
$URL = ("https://DOMAINHERE.freshservice.com/api/v2/tickets/TICKETNUMBERHERE/tasks")
$curl = Invoke-RestMethod -Method Get -Uri $URL -Headers $FSHTTPHeaders -UseBasicParsing
echo $curl | ConvertTo-Json # Uncomment here if needed -> -depth 5

in the parser it should look something like this

$.tasks1.status should return the first value in the array

1 = open status

2 = pending satus

3 = closed status


Using a similar syntax within the conditions module would allow check for status
 

 

Userlevel 7
Badge +13

@mikew  but how do you use the PS node in a Task workflow? 

Hello,

I appreciate your input on the need for standard nodes in the task module for workflow automation. It sounds like you encountered some limitations in your recent task automation, and having more standard nodes could provide greater flexibility and control.

Your suggestion makes sense, and I agree that it would be beneficial. I'll certainly vote in favor of adding these standard nodes to the task module, as it could streamline and improve workflow automation for many users.

Thank you for sharing your feedback and contributing to the community's discussion.

Best regards,Farrukh

yeah, I understand your frustration with the limitations in the Task Workflow Automations (WFA) module. It's important to have a comprehensive set of standard nodes available to streamline processes effectively. Your proposal to include all standard nodes in the task module is a valid suggestion that could greatly improve workflow automation capabilities. I'll definitely support this idea by voting for it. It would enhance flexibility and control over automation processes for many users.

Userlevel 7
Badge +13

yeah, I understand your frustration with the limitations in the Task Workflow Automations (WFA) module. It's important to have a comprehensive set of standard nodes available to streamline processes effectively. Your proposal to include all standard nodes in the task module is a valid suggestion that could greatly improve workflow automation capabilities. I'll definitely support this idea by voting for it. It would enhance flexibility and control over automation processes for many users.

And they have been :) 

Userlevel 7
Badge +13

This topic is now solved, 

Reply