Add/Remove (Custom) field to Jira and Service Desk Create Notifications

JIRA and Service Desk system templates includes the most common fields (issue type, assignee, created date, etc) in the bodies of each issue create notification. The fields that are included can be changed without creating new custom templates. It can be done by updating the global custom macros.

Step-by-step guide

Change global custom macros

  1. Go to Notification -> Custom Macros -> Edit. 
  2. Add the following script updating the list as necessary. 
## Adding field customfield_10000 to Jira Themes
#set ($serviceJiraFields = ['issuetype','assignee','created','updated','priority','reporter', 'security','customfield_10000'])
## Adding field customfield_10000 to Service Desk Themes
#set ($serviceDeskDetailsFields = ['status','issuetype','summary','description','customfield_10000'])
## Adding field customfield_10000 and Sprint to HipChat themes
#set ($hipChatJiraFields = ['issuekey', 'issuetype','status','assignee','created','updated','priority','reporter', 'security','customfield_10000', 'Sprint'])
## Adding field customfield_10000 and Sprint to Slack themes
#set ($slackJiraFields = ['issuekey', 'issuetype','status','assignee','created','updated','priority','reporter', 'security','customfield_10000', 'Sprint'])

Screen should look

Once saved, it can be testing by using the Preview tool:

  1. Go to Notification -> Preview 
  2. Select either Issue Created JIRA or Issue Create Service Desk template
  3. Select a preview context
  4. Hit Preview

The email now includes the custom field customfield_10000

 

This change is a global and it will reflected in all system templates. It is the simplest way to add the field. If you need more customization, please visit How-to Create custom Theme and Template Sets.