Missed Team ’24? Catch up on announcements here.

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

Set Organization by automation

Aaron Geister
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
October 12, 2022

Looking for some guidance on setting organization for JSM customers by location and or department using Automation for Jira. 

I was thinking I could modify the JSON to get the outcome but its not working. We don't have Scriptrunner in our environment which we are trying to get but we have a long process to get add-ons as they all have to go through security & finance request. 

Anyone have any ideas the best way to do this? Maybe IDP groups automate to Orgs?

1 answer

0 votes
Kerli Loopman
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 6, 2022

I don't know a good solution for this because Automation doesn't have trigger for "User added". 

There is an open suggestion for adding users by email domain https://jira.atlassian.com/browse/JSDCLOUD-4519, you can vote for that if this would help you although your question was about adding users by their location/department so if all of the users have the same email domain, this would not help.  

At some point we used a workaround for this, this might not work for you but I will share it anyway, maybe it gives some thoughts.

The only action I find related to it, is "Add service project customer" so I started to work out a solution with it. 

We had ticket for each new user, basically "New employee form" what the HR department fills in with details needed to create an account to our domain. When we created the account and it was synced to Atlassian, we filled in "Pick user" field in this issue. 

Now this is where the automation comes in.

Trigger: When value changes for "Pick user" 

Condition: Issue Type equals "New employee form" 

For current issue (branches for each department)

- Condition: User condition:

- - User: "Pick user"

- - Check to perform: "is in group"

- - Criteria: Choose your Department group  

- Action: Add Service project customer

- - E-mail: {{issue.fields.customfield_10140.emailAddress}} - the custom field number should be relevant for your "pick user" field

- - Name: {{issue.fields.customfield_10140.displayName}} - the custom field number should be relevant for your "pick user" field

- - Organization: Your organization based on department

 

This automation kind of works but it says "User already exists" beacuse we sync newly created users to Customers anyway, but the second part which is what you were asking, still was a success and the new user was added to Organization based on the group they belong to (synced from Active Directory). 

 user_to_organization.png

We don't use the "Organizations" function anymore actually, because I didn't like this thing that users can share their tickets with whole "organization" and there were some issues with reports with organization field, so now instead of dividing users to Organzations I fill in one custom field with similar automation based on reporters department group. 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
PERMISSIONS LEVEL
Site Admin
TAGS
AUG Leaders

Atlassian Community Events