Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

How can I use Canned Response to Close Ticket?

Georgia Stangel June 4, 2024

I am attempting to set up an automation so that when a specific canned response is used, it updates the request type and closes the ticket (for simple tasks like password reset links, etc) but my rule will run and do nothing. I've looked at a few other similar issues in the community but so far I've had no luck with those suggestions. 

The comment from the canned response contains the exact phrase that I have the automation set to recognize so I am assuming I am missing something simple to get it to recognize it (change smart value condition, etc.)

I've tried {{comment.body}}, {{comment}}, {{issue.comment}} and also changing the rule to run for all comments added and not just the main action but no dice. I've also swapped my condition between contains, contains regular expression, and equals but that made no difference either. 

image.pngimage.png

1 answer

1 accepted

2 votes
Answer accepted
Mikael Sandberg
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 4, 2024

Hi @Georgia Stangel,

Welcome to Atlassian Community!

I would recommend that you add a log action at the beginning of your rule to make sure that {{comment.body}} has the value you are looking for and then go from there. 

Georgia Stangel June 4, 2024

Do I need to enable this somewhere in Jira Service Management? I've never used it before but and based on the Atlassian Documentation, Log Action is used with smart values but I only have the option to compare two values. 

My View

image.png

Log Action Example from Atlassian

image.png

 

I am very new to Jira so I'm sorry if it's a dumb question, I just keep running into things that should work in theory but won't work the way I want to set them up with Jira. 

Mikael Sandberg
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 4, 2024

No, you do not have to enable it on JSM, all you have to do is add it first in your rule after the trigger component and set to something like this:

Screenshot 2024-06-04 at 10.16.00 AM.png

Once your automation runs, this log action will add the data to the Audit log of the rule and you can then go a check to make sure that the {{comment.body}} has the value that you expect.

Georgia Stangel June 4, 2024

So I do see that now, my audit log shows the exact comment that I am expecting.

I copied it verbatim from the log and put that exact phrase into my rule and I still get the response that the issue does not match the condition, but it is the exact comment I am looking for: 

image.png

image.png

Mikael Sandberg
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 4, 2024

Okay, I would consider redoing your automation and see if that helps. I just tested in my sandbox using both the {{smart values}} condition that you are using and the If/Else condition and in both cases the automation worked as expected and passes the condition. Here is what those two looks like:

Smart value condition

Screenshot 2024-06-04 at 11.30.08 AM.png

If/Else condition

Screenshot 2024-06-04 at 11.28.36 AM.png

Georgia Stangel June 4, 2024

Thank you! The if/else option worked!!

image.pngimage.png

Like Mikael Sandberg likes this
Laurie Sciutti
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 5, 2024
Like Mikael Sandberg likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
PERMISSIONS LEVEL
Product Admin
TAGS
AUG Leaders

Atlassian Community Events