How can I automatically close issues?

I'm using JIRA service desk, cloud.

I notice a few small automation features, but nothing that would allow me to automatically close issues based on data like time spent, issue type, etc.

Is this possible?

4 answers

This widget could not be displayed.

Hi Tony,


Unfortunately it is not possible in a Cloud instance. sad



Henrique Freitas

This widget could not be displayed.

The only method of doing this sort of automation would be externally. JIRA Cloud instances can enable Remote API access, so you can write a script in just about any scripting language (such as Python..) that can perform the following – 

  • Remotely request issues that match a query such as "type=Request AND updated(-30d)"
  • Store the list of issues you receive
  • Remotely transition each issue to Closed, setting a Resolution and adding a comment if you wish

The point is you can do it but you have to maintain the 'service' yourself.

This widget could not be displayed.

If you can define a JQL statement that identifies your conditions for closure, then, using JIRA Command Line Interface (CLI), you can use something like the following in your favorite job scheduler:

jira --action runFromIssueList --jql "status = resolved AND resolutiondate < -1w" --common "--action transitionIssue --issue @issue@ --transition \"Close Issue\" "
This widget could not be displayed.

Hi Tony,

Here's how I achieved automation for closing an issue after timeout with JIRA Service Desk:

  1. Create an SLA, 'Waiting on Customer'
    1. All issues, 24/7, 336h
    2. 336 hours, or 2 weeks, in that state before it is breeched
  2. Create a custom automation rule, 'Close issue on timeout'
    1. When: SLA Time Remaining for 'Waiting on Customer' is breeched
    2. Then: Comment on the issue publicly to let the customer know, and transition to Done
    3. (I also comment internally for the assignee to let them know it is closing)

Does it sound like that approach would work in your scenario?

Thanks Tony, have a great day,
Nick Muldoon
Arijea, creators of Easy Agile User Story Maps and Easy Agile Roadmaps for JIRA


I just wrangled this out with a customer today, and we came to the same solution! So funny to see it right now on a question I'm watching. smile

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Tuesday in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

300 views 1 4
Join discussion

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you