Utilise reporters email domain to create an Organisation if it does not exist
Asked by Anthony R:

Has anyone found a better solution then automation for **creating** Organisations.

We have a public facing Support desk portal and a couple of years ago when we implemented JSM we needed a way to identify and report on the organisations that interact with us so we implemented an automation that I found here to create the organisation based upon the reporters email domain.  
E.g.  
![Org Automation Edit component .png](/t5/image/serverpage/image-id/333614i25ED650C126389BE/image-size/large?v=v2&px=999 "Org Automation Edit component .png")  

This automation works very well. The problem is it works too well. We're on the standard plan and this automation is consuming a large percentage of our limit.  

I saw that Atlassian announced this afew months ago

[Automatically manage JSM customers and organizations at scale (atlassian.com)](https://community.atlassian.com/t5/Jira-Service-Management-articles/Managing-customers-and-organizations-on-Jira-Service-Management/ba-p/2677857#M4206)  

But it doesn't appear to resolve our problem because it appears at least in my testing to only work for existing Organisations not NEW organisations.  

Does any one have any suggestions on how we might fix this OR how we could fix the automation to reduce the number of times it successfully runs?  

And before anyone asks, yes we are looking at upgrading to Premium but that may take months.... looking for a solution for now.....


Answers:
author: John Funk
body: Hi Anthony,

I doubt you need this to happen immediately, so you should consider changing the trigger to be based on a Scheduled trigger instead of firing on every create. Then schedule it to run a couple of times a day.

comments: author: Anthony R
body: Hi John,

Thanks for your suggestion and the concept actually makes alot of sense,  
Unfortunately I've tried rewriting this automation using a straight flow and JSM tells me it is not not compatible (see image)

I've tried using a JQL to identify the issues and JSM tells me it is not not compatible (see image)

I've tried using an IF Else condition to identify the issues where the Organisations field is EMPTY and JSM tells me it is not not compatible (see image)

I've tried using a JQL for tickets created TODAY, I've tried using branching and I keep getting the same outcome. JSM telling me I am using incompatible components....  

What is aggravating me even more is that the "Help" Article that JSM links to provide very little help <https://support.atlassian.com/cloud-automation/resources/> it simply says:  

*In Jira, The **Edit issue action** requires an issue to be previously provided by the rule trigger or a related-issues branch.*

I've raised a ticket with Atlassian Support hoping they can offer some clearer direction.  

<br />


author: Anthony R
body: ![Automation Image 1.png](https://community.atlassian.com/t5/image/serverpage/image-id/333886i4A2578BC5E339B63/image-size/large?v=v2&px=999 "Automation Image 1.png")![Automation image 2.png](https://community.atlassian.com/t5/image/serverpage/image-id/333884iD712A4649AEFDC66/image-size/large?v=v2&px=999 "Automation image 2.png")![Automation image 3.png](https://community.atlassian.com/t5/image/serverpage/image-id/333885i91B73A2744904FAB/image-size/large?v=v2&px=999 "Automation image 3.png")


author: John Funk
body: This appears to be a Components issue and not a JSM issue. However, is this a Team-managed or Company-managed project? Are more than one project involved? Are these regular Components? Or Compass Components?


Tags: cloud

jira-service-management

jira-service-management-cloud