Freshservice Hack: Automatically Resolving Tickets When Tasks Are Complete
Freshservice makes task management on tickets easy, but what happens when you want a ticket to resolve itself automatically once all its tasks are complete? Sounds like a basic feature, right? Unfortunately, Freshservice doesn’t natively support this functionality without a little creativity.
But don’t worry—I’ve got you covered with a simple, scalable workflow solution that can handle varying numbers of tasks, bypassing Freshservice’s limitations.
The Problem
Let’s say you’re managing onboarding tickets, and each ticket automatically gets several tasks assigned. You want the ticket to resolve itself when all tasks are marked as complete.
However, Freshservice struggles with:
Looping through arrays of tasks to check their statuses.
Handling tickets with a variable number of tasks.
The Workaround
By combining workflow automations and a clever trick, you can bypass these challenges. Here’s how:
Trigger Task Creation:
Start with a workflow that assigns tasks to a ticket based on a condition (e.g., the subject contains “Onboarding”).Track Task Statuses:
Use a second workflow triggered when a task’s status changes. This workflow fetches the list of tasks linked to the ticket and stores their statuses as an array.Convert and Validate:
Convert the array into a string using adowncase
filter. Then, check if the string contains any incomplete statuses (like "open," "in progress," or "blocked").Resolve When Complete:
If all tasks are marked as complete, the workflow resolves the ticket, adds a note for visibility, and notifies stakeholders.
Why This Works
This solution eliminates the need for loops and works seamlessly with any number of tasks. It’s simple, scalable, and works with Freshservice’s built-in automation tools.
See It in Action
I’ve detailed the entire process in my video:
Setting up workflows for task creation and monitoring
Fetching task arrays and checking their statuses
Automatically resolving tickets when tasks are complete
📽️ Watch here: https://youtu.be/0gMN6UlbK3M