Question

Workflow action after Alert is set to resolved

  • 1 December 2022
  • 8 replies
  • 126 views

Userlevel 3
Badge +6

I need some brains to help me figuring out a workaround for a limitation in Freshservice (or lack of feature 😀)  


We’ve integrated a webhook with FS. This works all fine. When an alert is raised in the external app a call is made to FS and an alert is created. Followed by an incident ticket. Then we have a workflow configured that gets triggered once an incident is created. It extracts data from the information that is passed on by the webhook and uses that to send an email to the customer. So far so good.

Now we getting to the point where I need help with. 

At the moment the alert gets cleared by the external app (system is back online). The app informs FS through the webhook. The Alert status in FS is set to resolved and “SYSTEM” sets the incident ticket status to resolved. 

When this happens I want to add a note to the ticket and send a custom mail to the customer that the alert is cleared. I created a workflow for this with a event “when status is changed to resolved” but it is not working. FS Support told as this update is done by “SYSTEM” and not through API or GUI the workflow gets not triggered. 

So where I need your help with is a solution to trigger the workflow when the system changes the status of a ticket to resolved. I was looking for a way to have the external app sending an API call to update the ticket so it can trigger the workflow but since the external app is not aware of the ticket ID I cannot get it to work. 

 

Thanks for thinking along

 

 

 

 

 


8 replies

Userlevel 3
Badge +4

Hi Richard,

If the event for when alert is resolved is not triggering, could you possibly add a custom field that is hidden by business rules in the ticket?

Then when the external monitoring app resolves the ticket it also updates this custom field. Then you can create an event based on the custom field changing value or being set to something specific etc…

Cheers

 

Userlevel 3
Badge +6

Hey Michael, 

Thanks for this option but I don’t think there is an option to update a field on a ticket when the alert is resolved. Or do you have an example that you can share that shows it is possible. 

Userlevel 7
Badge +16

Hello @RichardR

Unfortunately I am not sure of an easy way to do this. As the support team mentioned, SYSTEM executed activities don’t trigger workflows as it would basically fall under the same category of one workflow triggering another workflow, which doesn’t happen currently (is suppose to be coming I hear). The best solution would be to find a way to get the Ticket ID of the associated incident to the alert and then use your external app webhook to update the ticket via the Freshservice API.

Sorry I don’t have better news. Hopefully they add “Alerts” to workflow automators soon with a list of triggers that might solve your problem. Take care!

Userlevel 3
Badge +6

@zachary.king  - Lets hope it is in the coming release notes 🤞🤞🤞

On your suggestion. I’m trying to retrieve the alert status and incident # from the FS API so when the alert is set to resolved I can use that information to update the incident through API and trigger the workflow. 

Only issue now - In the API documentation there is nothing about the alert section. Does anyone know if this information is available through the API? 

Userlevel 7
Badge +16

Hey @RichardR , I don’t believe they have added “Alerts” endpoints to the public API yet. I would suggest taking this suggestion over to the Developer Community where they are closer to the product team responsible for the API.

Badge +1

Hello everyone!

We have modified this behavior in a recent release. You can now trigger workflows when an OK alert marks an incident as resolved. 
 

As Zachary correctly pointed out, we usually don’t allow system triggered actions to trigger another workflow but we have made an exception for this particular case.

I hope this helps!

Userlevel 3
Badge +6

Hey @vidhisharma 

Great news and thank you for having this added. 

I do not see it back as an event trigger in the workflow. Is the release still being rolled out? 

Badge +1

@RichardR 
This will not be an explicit trigger in workflow. In your case, for instance, if you create a workflow automator to execute on the trigger “ticket is updated”, it will execute when the alert marks the incident as resolved.
eg: The following automator sends out an email when an alert marks an incident as resolved. I don’t have to put any explicit triggers or conditions to capture instances where alert is marking the incident as resolved.

I hope this helps.

 

Reply