Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

Automation: notify after every 20th task creation


Can I create an automation rule that notifies me after every 20th task is created?

Or if there is any plugin that can help?


Thank you

3 answers

Hi Ketevan,


This could be achieved also with Automation, I am sending an example to notify when the mark of issues is hit.

What I do in the script is: 

  • Extract the number from the Issue key that was just created and added into a smartvalue.
  • Divide the extracted issue key using the MOD function which returns the spare of a division, giving as a result 0 if the issue can be exactly divided by 5, in your case is 20.
  • If the result of the MOD division is 0, then send the notification.

Here are images of explaining the automation rule.

Indeed this problem could be solved with ScriptRunner as well, but that would require buying a plugin a probably more programming than it needs to be.

Hopefully this can help you and you can mark it is an answer.

If you have any questions, just let me know.




Hi @David Freitez ,

just a thing about your solution: in it the Task number is recovered from the issue key and not through a JQL but so, if some task has been deleted, this solution no longer works correctly.

Like Ketevan likes this

Hi @Andrea Pannitti ,

You are right, I'll update it.


Hi @Ketevan

As was pointed out, we cannot rely on extracting issue key number to check on how many issues has been created if there are issues that were deleted. So, in that particular case:

I have updated the rule so it uses the Lookup Issues feature that uses a JQL that gives as result all issues of the project, then we'll grab with the smartvalue the result amount of the query and that's the value we'll end up dividing using the MOD function, the rest of the rule is the same.

If you have any questions regarding the implementation, just let me know.




Like Ketevan likes this

Hi @David Freitez 

I think the correct JQL should be this:

project = PN1 and issuetype = Task

Hi @Andrea Pannitti

Actually, the JQL is an example in my sandbox,  the JQL needs to be updated according to the needs of the person that would apply this solution.

I see the ticket creator indicated task, but it could have meant a task-like issue type.

Anyway, thanks for pointing it out,  this is my first Atlassian community reply, so you are right, it's all about details.


Like Ketevan likes this

No problem @David Freitez  and thank you for your contribution!

Like David Freitez likes this

Hello guys,

Many thanks for helping.

@David Freitez I've tried everything according to your screens, but when I run the rule it fails, here is the log:

Screenshot 2022-06-07 at 15.52.55.png

Do you know how to solve this?

Hi @Ketevan

Are you using the rule with the JQL or extracting the number from the Issue key ?

Can you share the screenshot of the % operator being used ?


Hi @Ketevan ,

this surely can be done with ScriptRunner!
With a post-function on Task create, a JQL get the number of Task and if this is divisible by 20, a notification is send.

Hi @Ketevan 

What problem are you trying to solve by doing this?  Knowing that may help the community to offer suggestions.  Thanks!

Kind regards,

Suggest an answer

Log in or Sign up to answer
Site Admin
Community showcase
Published in Jira Software

Upcoming changes to epic fields in company-managed projects

👋 Hi there Jira Community! A few months ago we shared with you plans around renaming epics in your company-managed projects. As part of these changes, we highlighted upcoming changes to epics on...

14,759 views 37 47
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you