Forums

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

Dynamically set Team based on Assignee in Automation Flow

Yoeri Van Nieuwerburg
May 19, 2026

So, I'm looking into updating the Team field based on the current Assignee in a dynamic and sustainable way (so if/else statements on a per assignee base is NOT an option ;) ).

Currently, I've had a look at the smart values and the REST API, but to no avail.

So, some of the smart values I've already tried (I've already checked with Rovo, but that did not go as planned):

{{issue.assignee.teams.first.name}}
{{issue.assignee.teams.first.id}}
{{assignee.teams.first.name}}
{{assignee.teams.first.id}}

Does anyone have experience with this? What am I missing?

Is there any REST resource that allows me to fetch the teams of a corresponding user and where is it documented if so? I'm not ruling out I overlooked it in the REST docs at https://developer.atlassian.com/cloud/jira/platform/rest/v3 or https://developer.atlassian.com/platform/teams/rest/v1/api-group-teams-public-api/ 

 

1 answer

0 votes
Marc -Devoteam-
Community Champion
May 19, 2026

Hi @Yoeri Van Nieuwerburg 

You could use, https://developer.atlassian.com/platform/teams/rest/v1/api-group-teams-members-public-api/#api-public-teams-v1-org-orgid-teams-teamid-members-post 

To get members of a team, but there is no endpoint based on a user that provides in which team a user is.

Also see https://jira.atlassian.com/browse/JRACLOUD-83728 

Yoeri Van Nieuwerburg
May 19, 2026

Hi @Marc -Devoteam- 

Thanks for the reply!

I did come across that specific endpoint, but unfortunately, it isn't quite dynamic or scalable for our needs. It requires one to know which teams are present in the organisation, loop over them, and figure out the team(s) of which the assignee is a member.

That's a pretty intens way of working:

  1. Fetch all teams.
  2. For each team:
    • Fetch the members (and probably handling pagination).
    • Check if the members list contains the assignee.
    • If yes: Set the field and break the loop.
    • If no: Move to the next team.

Given the overhead, this is something that ideally should be exposed as a property on the user/assignee object.
However, I've gone ahead and upvoted the Jira issue you linked.


Thanks again for confirming the current API limitations!

Marc -Devoteam-
Community Champion
May 19, 2026

Hi @Yoeri Van Nieuwerburg 

Please accept my answer as a solution, if my answer helped to solve or provide a workaround to your request.

This will help other community member trying to solve the same or provide them with a work around

P.S. If the answer is very valuable to you, please share some kudos.

Yoeri Van Nieuwerburg
May 19, 2026

No solution nor workaround I'm afraid ;)
As stated, the possible workaround using the REST endpoint is too intens.
However, I do appreciate your feedback :D

Like Marc -Devoteam- likes this

Suggest an answer

Log in or Sign up to answer