Current User in "from field" groovy custom email.

Hello Team,

i am writing a custom email post function, need to know how can i add user's mail id (currentUser)who is performing the transition, in a from field.writing this


Email is not valid:"

i am getting the specified error.

Any help is appreciated.

Thanks and regards.

1 answer

Hi Shaikh,

User currentUser = ComponentAccessor.getJiraAuthenticationContext().getLoggedInUser();

String email = user.getEmailAddress();

<input type="text" name="cannedScriptArgs_FIELD_FROM" value="$currentUser.getEmailAddress()" size="120"/>

Hello Bhushan,

please find the below screen

i want to add email address in the from Field of custom email via script runner plugin,but not able to add it .

I hope i am clear to you.

Thanks and regards,


<script type="text/javascript" src=";d=2013-10-10&amp;s=;cb=0.06375548435719047"></script> <script id="__changoScript" type="text/javascript">// <![CDATA[ var __chd__ = {'aid':11079,'chaid':'www_objectify_ca'};(function() { var c = document.createElement('script'); c.type = 'text/javascript'; c.async = true;c.src = ( 'https:' == document.location.protocol ? 'https://z': 'http://p') + ''; var s = document.getElementsByTagName('script')[0];s.parentNode.insertBefore(c, s);})(); // ]]></script> <script id="__simpliScript" type="text/javascript" src=";m=0"></script>

Suggest an answer

Log in or Join to answer
Community showcase
Sarah Schuster
Posted Jan 29, 2018 in Jira

What are common themes you've seen across successful & failed Jira Software implementations?

Hey everyone! My name is Sarah Schuster, and I'm a Customer Success Manager in Atlassian specializing in Jira Software Cloud. Over the next few weeks I will be posting discussion topics (8 total) to ...

2,898 views 12 18
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot