I am attempting to make a simple automated message when a ticket is triaged in Jira Servicedesk.
I want the message to say something like
"Hi {{issue.reporter.displayName}},
Your issue has been read over and assigned a priority of {{issue.priority.name}}.
We currently have X outstanding tickets of that priority or higher and are already working on Y of them.
We will pick your issue up as soon as we have cleared these tickets ahead of you in the queue.
Regards, the support team"
I can get JQL queries for the X and Y values fairly easily but can't find a way to enter it into the automated email.
Has anyone come across a way to do something similar?
Hey Alexander,
I will share with you a simple example to guide the solution that you can implement.
X (All tickets that are not done) -> {{issue.priority.name}} AND statusCategory != Done
Y (In Progress) -> {{issue.priority.name}} AND status = 'In Progress'
Create an Automation.
Select the trigger according to when you want to calculate the number of issues and send an email.
Use branch rule (you can select current issue)
LookupIssues action.
And provide the JQL in there for X and Y.
{{lookupIssues.size}} smart value will give you the number of issues.
And you can add one more action which is Send email and use that smart value. Or you can put it into a customfield.
However, there might be a total limit for the JQL that gets the issues.
In that case, let's say the limit is 100.
You can say in the email like there are more than 100 issues that are in the queue currently.
The other but not the best way is counting the issues in a customfield. It will decrease the number -1 whenever and issue goes to the statusCategory = Done. It will increase the number whenever an issue is created.
I did see some similar comments but jira isn't happy with the {{lookupissues.size}} and is simply skipping over it.
Is there some specific licence or versioning that is required?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Strangely after trying again it worked, no change to any of the queries but it just seemed to work all of a sudden and since I have been able to test and it is working fine.
Thank you
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have just tried for you {{lookupIssues.size}} yeah it still works fine and it gave the result actually.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Yes, it now works for me as well? Weird.
I did add a log action inbetween but all is now good.
Email looks like:
Thanks @Alexander Steel that is a very useful idea.
Mark
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I was curious to see if this did work in my environment and it did not.
What did work (and I admit it's not ideal) is this:
{{#lookupIssues}}
* {{key}}
{{/}}
which lists ALL the issues that the JQL returned.
Try as I might, I can not get the .size to work??
Mark
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.