This function returns the name of the user in a given project role (in the current issue's project) with the lowest number of unresolved issues.

An empty text "" will be returned if there is no user in the project role.

Multiple project roles can be specified in a comma-separated list of project role names, returning the least busy users among the project roles.

Syntax
leastBusyUserInRole(projectRole) #Output: Text
Examples
Parser expressionDescription
leastBusyUserInRole("Developers")

This example returns the user among all users of the Developers project role in the current project with the lowest number of unresolved issues across all Jira projects, e.g.:

admin.istrator

Additional information

Parameters used in this function

ParameterInput (data type)Description
projectRole

TEXT

Text containing a valid project role name. Multiple project roles can be specified in a comma-separated list of project role names.
Output

This function returns a TEXT

Variant where you can additionally define a specific project key.

Syntax
leastBusyUserInRole(projectRole, projectKey) #Output: Text
Examples
Parser expressionDescription
leastBusyUserInRole("Developers", "CRM")

This example returns the user among all users of the Developers project role in the CRM project with the lowest number of unresolved issues across all Jira projects, e.g.:

admin.istrator


Additional information

Parameters used in this function

ParameterInput (data type)Description
projectRole

TEXT

Text containing a valid project role name. Multiple project roles can be specified in a comma-separated list of project role names.
projectKey

TEXT

Text containing a valid project key.
Output

This function returns a TEXT


Variant where you can additionally define a specific JQL query to limit the scope of unresolved issues.

Syntax
leastBusyUserInRole(projectRole, projectKey, jqlQuery) #Output: Text
Examples
Parser expressionDescription
leastBusyUserInRole("Developers", %{issue.project.key}, "type = Bug"})

This example returns the name of the user, who is a member of the current issues' project role Developers and has the lowest number of unresolved Bugs assigned across all Jira projects, e.g.:

admin.istrator

leastBusyUserInRole("Projektmitarbeiter (intern)", %{issue.project.key}, "project =" + %{issue.project.key})
This example returns the name of the user, who is a member of the current issues' project role Developers and has the lowest number of unresolved issue assigned in the current Jira projecte.g.:

admin.istrator

Additional information

Parameters used in this function

ParameterInput (data type)Description
projectRole

TEXT

Text containing a valid project role name. Multiple project roles can be specified in a comma-separated list of project role names.
projectKey

TEXT

Text containing a valid project key.
jqlQuery

TEXT

Text containing a valid JQL query. 
Output

This function returns a TEXT

This function is useful if you want to automatically assign issues to the least busy user using a post function or automation rule, e.g.:


Use cases and examples