The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

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

Find user who created Jira issue link

Archana Bellamkonda
February 4, 2021

Hi,

I am trying to find the user who created / deleted an issue link via custom code in script runner. For an IssueEvent object, I can use getUser() method. Similarly, for IssueLinkCreatedEvent or IssueLinkDeletedEvent, I am trying to figure out the best way to identify the user who created/deleted the link. Based on the user, I must do some custom handling. 

Can you please let me know if there is a way to accomplish this?

Thanks,

Archana

1 answer

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

0 votes
Elifcan Cakmak
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Champions.
February 5, 2021

Hello,

Best way to do this is to get the change history of the issue.

https://docs.atlassian.com/software/jira/docs/api/latest/com/atlassian/jira/issue/changehistory/ChangeHistoryManager.html#getChangeItemsForField-com.atlassian.jira.issue.Issue-java.lang.String-

Iterate through the change history and search for the field "Link". From there you need to parse the "from" field, "to" field and get the user who performed the change:

https://docs.atlassian.com/software/jira/docs/api/latest/com/atlassian/jira/issue/changehistory/ChangeHistoryItem.html

Regards,

Elifcan

DEPLOYMENT TYPE
SERVER
VERSION
8.13.1
TAGS
AUG Leaders

Atlassian Community Events