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

How to create an automation for assigning a team to the tickets created in a certain project?

Diana Melkumyan March 24, 2022

Objective:

Get Advanced roadmaps to display all the items in a certain project with projected sprints.

Screen Shot 2022-03-24 at 1.55.35 PM.png

Actions taken:

I have created a project specific Advanced Roadmap. As far as I know, in order to see the sprints and projected sprints on top of the roadmap, I needed to group by Team. I have created a Team in Jira.

 

Problem:

When trying to set up automation to set the Team field to “Loyalty” for all the new issues, Jira only allows to select “Team[Dropdown]” and not “Team[Team]“. I’ve tried doing it via JSON too, but it doesn’t recognize the field any way I’m putting it and I don't have the field ID, as it's not a custom field.

What I see when selecting the Team field in the automation:

Screen Shot 2022-03-24 at 1.59.56 PM.png

What I want to see is the Shared Teams we have configured in Jira for the organization:

Screen Shot 2022-03-24 at 2.01.35 PM.png

 

Expected result:

Any issue that is created in the project updates the little progress bar on the sprint in Advanced Roadmaps.

2 answers

1 accepted

0 votes
Answer accepted
Diana Melkumyan December 6, 2022

You have to use the field ID. You can find it at [your_attlassian.url]/secure/admin/ViewCustomFields.jspa , find the field and click on "View information". The id will be available in the URL as in /secure/admin/ConfigureCustomField!default.jspa?customFieldId=11300

 

Then you need to configure the automation to use advanced options and configure it with the field ID and the team ID as follows

 


{

"fields": {
"customfield_10114": "56"
}
} 

 

Credits to @John Haworth ! I will also willingly accept your answer if you repost this, John!

2 votes
Rick Olson March 24, 2022

You have to set the team using the team number, like I show below. If you need to figure out how to get your team number for a team, take a look at my answer in this post: Locating your team number SetTeamNumber.PNG

Diana Melkumyan March 28, 2022

I really appreciate your response. Unfortunately, that was one of the variations I've tried before and it brings me this error.

Screen Shot 2022-03-28 at 8.49.28 AM.png

I've tried this with and without spaces, with and without quotes, lower case and uppercase and camel case. Any syntax I've tried brings the same error: Additional fields contains invalid field(s) in 'update' or 'fields' section: Team

 

The screenshot below confirms that the team number is correct. I'm getting the 228 issues as I should be.

Screen Shot 2022-03-28 at 8.52.11 AM.png

I'm probably missing something stupid, so I'd really appreciate your guidance.

Rick Olson April 4, 2022

Hello there!

I took some screen shots for you in hopes that these will guide you on assigning a specific team when an issue is created.

In my example, I automatically assign all new bugs to a specific team. The team is number 177 (a.k.a. POC Team A).

Here are the three screens:

1. The configuration screen for the automation showing the Team field being set to 177.

2. The Audit log showing a new bug being added.

3. The resulting issue screen showing that the new bug has the team set to 'POC Team A'.

Bug1.PNG

Bug2.PNG

 

Bug3.PNG

Rick Olson April 6, 2022

Diana - Did this work for you?

Diana Melkumyan May 30, 2022

Hi @Rick Olson, I appreciate the follow up. As per my 2nd comment, I have already tried that (and retried just now). The validation on this query fails.

{
"fields": {
"Team" : "14"
}
}

 Here's the screenshot.Screen Shot 2022-05-30 at 11.52.23 AM.png

In the comment above I have also attached a screenshot confirming the team number is correct.

I have tried to make the rule specific to an issue type. That doesn't work either. Same validation error.

Can you post your query here, so that I can try just by copy pasting? I really don't know what else to do :(

John Haworth September 13, 2022

Took me a while but I got this one sorted 

Team doesn't work you have to use treat it as a custom field ID which you can find in the custom field edit screen in the url 

i.e. 

secure/admin/EditCustomField!default.jspa?id=10114

convert that to referencing issue fields docs here Advanced field editing using JSON | Cloud automation Cloud | Atlassian Support

customfield_10114

my example is below (which works for me) your field ID and team will be different 

 

{
"fields": {
"customfield_10114": "56"
}
}

Like # people like this
Leo October 13, 2022

John's solution worked for me. Thanks, John!

It's surprising that we have to go thru all of this (e.g., getting custom-field ids from URLs) to be able to consistently show sprints in Jira Advanced roadmaps...

Diana Melkumyan December 6, 2022

Thank you, this works!

For others, you can find the custom fields in the UI here: https://[your_handle].atlassian.net/secure/admin/ViewCustomFields.jspa

Team field is not edittable, but you can still find the ID in the URL by clicking on "View information"

Like Leo likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events