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

How to get the current user who triggered the transition

Villarasan September 7, 2022

Hi, we are having a rule to create a new issue when a webhook triggered in an event, the initiator is returning as blank, how do we get the current user name?webhook rule.JPG

2 answers

0 votes
Curt Holley
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 7, 2022

Hi @Villarasan 
The {{initiator.displayname}} smart value is looking for the user in Jira. So if the initiator is a webhook, that smart value will not work as the initiator isn't a Jira user in this scenario.
Is the {{issue.summary}} working? if so, then perhaps {{reporter.Displayname}} might work??

Villarasan September 7, 2022

thanks Curt, {{issue.summary}} works fine. reporter doesn't work for us, because we are setting the initiator as reporter in additional field update section. Also this issue is created by rule, so reporter doesn't have the current user.

0 votes
Carlos Faddul
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 7, 2022

@Villarasan the Incoming webhook is sending the Atlassian Account Id of the initiator ?

Villarasan September 7, 2022

We have created a webhook like below and triggering this webhook in a post function. we are passing the issue key alone, how should i pass the account id and get that in the rule.

https://,jira url>/rest/cb-automation/latest/hooks/e9c2cef9d422290414c6303aeb26c196db849711?issue=${issue.key}

tempsnip.png

Carlos Faddul
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 7, 2022

@Villarasan 

But in the Incoming Webresquest, you have some options, like show bellow

Captura de tela 2022-09-07 213735.png

I believe that you use the first case "Issues provided in the webhoook HTTP Post body" to get the data correctly ?

In some automation that you use to trigger this automation, maybe you are using "Send Web Request", then in this automation you need only to set "Issue data (Automation format)

Captura de tela 2022-09-07 214656.png

This maybe help you, but I don't know if I managed to give you a direction to look for the information you need, but if you can share more both the Incoming and the Send web request, it would help to try to find the desired smart value.

 

If this post was helpful, mark it as "Accept Answer" , so you can help others who may have the same difficulties.

If your question has not been resolved, please post again with more details.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events