Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Create automation to retrieve ongoing sprints from all Jira projects.

Luisa Cruz March 10, 2025

Hello,
I need to create an automation that retrieves the ongoing sprint for each project in Jira.
With the sprint name and the respective project, I want to validate whether the sprint name follows the defined naming rule. If it does not comply, I want to send an email to the person who started the sprint, asking them to correct it.
I’m having serious difficulties in setting up this automation. I have already tried Lookup Issues, Create Variable to store the Sprints with the Project, and then using Distinct, but nothing seems to work.
Can anyone help or has anyone tried something similar?
Thank you very much!

3 answers

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 11, 2025

Hi @Luisa Cruz -- Welcome to the Atlassian Community!

Short answer: unless you have a small number of projects with active sprints and those sprints have a small number of issues, what you ask is not possible.  I recommend considering a root cause discussion with teams: why are they using other sprint naming conventions.  Solving that underlying problem may eliminate the need for any elaborate reporting / checking.

 

Until recently, the workaround for this scenario was to add a site / global webhook for "Sprint Started" and detect that with a global automation rule using the Incoming Webhook Trigger.  That approach no longer works, possibly after the recent webhook changes, and alternatives are limited...

When there are fewer than 100 total issues in active sprints for the entire site, a generic JQL statement for openSprints() could be used with the Lookup Issues action to find and filter the sprint list, as others have suggested.  This could be in a global rule with a scheduled trigger.

When there are more than 100 total issues, I do not believe there is a solution with built-in features.  The reason is the REST API issue search endpoint does not support returning more than 100 issues for a search with anything other than the issue ID or key.  It can return up to 5000 issues with either of those two fields, but then the sprint information is needed.  While the project key could be extracted from the keys, reduced with distinct, and the sprints found, this would be limited to 100 projects and need to test each one-by-one.

 

Kind regards,
Bill

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 24, 2025

Hi @Luisa Cruz 

Just following-up if one of the suggestions resolved your question.  If so, please consider marking the relevant ones as "answered" to help others with similar needs find solutions faster in the future.

If not, please respond with additional details so the community can help.  Thanks!

Kind regards,
Bill

Like Luisa Cruz likes this
Luisa Cruz March 25, 2025

Hi @Bill Sheboy ,

From your answer I realized that I wasn't going to be successful in what I wanted to do because before I asked the question I had already spent a lot of time trying to find a solution. I gave up on the idea.
Thank you all and if by chance someone has the solution in the meantime, please share it.

Kind regards,
Luisa

0 votes
David Friedrich
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 11, 2025

Hi @Luisa Cruz ,

I understand, that you'd like to "outsource" the checking of naming conventions and asking the sprint managers for a correction to your automation. I do not have the solution, but a start on how to at least get all the active sprints:

Create a rule with the "Scheduled" Trigger, configure as as you like. Scheduled trigger also allows to run the rule manually directly from the rules overview anytime you need it.

Activate "Run a JQL search..."

sprint in openSprints()

Then add "Create Variable" to your rule:

Name: sprintNames

Smart Value:

 {{#issues.sprint.name.distinct}} - {{.}} {{/}}

Now you could have the automation email you the list of all active sprints:

"Hi,
here's a list of all active sprints:
{{sprintNames}}

Cheers,
Jira Automation"

 or simply log it to the rule audit.

Luisa Cruz March 25, 2025

Hi @David Friedrich

thank you for your tip. I had already use it but  but i have several projects and i want to send an email for each who open/start the sprint.
I already abandoned the idea since Bill Sheboy aswered.

Thanks very much.

King regards,

Luisa

0 votes
Trudy Claspill
Community Champion
March 10, 2025

Hello @Luisa Cruz 

Welcome to the Atlassian community.

I would recommend the following implementation.

Consider creating a rule that uses the Sprint Started trigger. In that scenario you can get the identity of the person who started the sprint by accessing the {{initiator}} smart value.

The Sprint Started trigger requires you to specify the board in which the Sprint exists, so you would have to have a rule for each Scrum board.

Since you have to explicitly identify the board, you can also pre-determine the related project when you are constructing the rule.

You can access the name of the sprint with the smart value {{sprint.name}}

You can then apply the conditions you need to use to evaluate if the name follows your naming conventions.

 

 

Luisa Cruz March 11, 2025

Hello @Trudy Claspill 

Thank you very much for your response. As you mentioned,  Sprint Started trigger can only be applied to a single project, so I am not using it. I really wanted to know if there is another way to get the information I need for all projects within a single automation. This would avoid having to create 'n' rules, one per project. I have at least 30 projects.

Thanks again

 

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events