Forums

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

Automate task based on reporter company name

Julien Béchade
Contributor
June 8, 2023

Hi,

I was wondering how one would go about automating tasks on ticket creation based on the reporter's company name? Company name is not accessible via smart values or API (https://your-domain.atlassian.net/rest/api/3/user?accountId=5b10ac8d82e05b22cc7d4ef5).

The company name is the one of the Atlassian's account. We are provisioning users via Atlassian Access and that's one of the value you can sync.

Cheers.

Julien.

3 answers

1 accepted

0 votes
Answer accepted
Julien Béchade
Contributor
June 13, 2023

It turns out that there's an API for that! This can used together with a Send Web Request automation action.

ee1f28de-0675-493c-9c85-1f197a7bc7a0.png

c383a704-bea6-4998-b6c9-4d11276aaef3.png

0 votes
Sayed Bares _ServiceRocket_
Community Champion
June 8, 2023

Hi @Julien Béchade ,

You could use the following smart value to get the domain/company name from the reporter object:

{{reporter.emailAddress.substringAfterLast("@").substringBefore(".")}}

I hope it helps!

Julien Béchade
Contributor
June 8, 2023

Hi Sayed,

Unfortunately, this is not possible. Those company names are set internally in our AD so the domain name is the same for everyone. I failed to mention that we are provisioning users via Atlassian Access.

Cheers.

Julien.

0 votes
Dan Breyen
Community Champion
June 8, 2023

Hi Julien, I'm guessing you mean Organization.  I worked extensively with support to help out with an API call to grab the organization of the reporter and update it on the Organization of my ticket.  You can put your site in the request.  

Here was the Web request URL: https://<your_site_here>.atlassian.net/rest/servicedeskapi/servicedesk/{{issue.Request Type.requestType.serviceDeskId}}/organization?accountId={{issue.reporter.accountId}}

If no one else has any suggestions, and that isn't what you're looking for, I would suggest working with support.  This got complicated for what I thought was a simple request.

I would hope in the future that more organization information would be available in the standard product w/o having to use an API.

Julien Béchade
Contributor
June 8, 2023

Hi Dan,

That's not what it is. I failed to mention that we are provisioning users via Atlassian Access. So the company name is the one of the Atlassian's account.
But thanks for the tip, I'll turn to support if I don't get a solution from the community.

Cheers.

Julien.

Suggest an answer

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

Atlassian Community Events