How to customize the Customer Satisfaction email in JSM Data Center
Platform Notice: Data Center Only - This article only applies to Atlassian apps on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
The Customer Satisfaction feature of Jira Service Management (JSM) does not allow free customization of its email content.
For instance, you may wish to:
Change the graphics of the survey stars in the JSM Customer Satisfaction email.
or
Change the URL of the survey link in the JSM Customer Satisfaction email.
The solution below describes how to replace the default notification and customize the content using the Automation for Jira, which provides unlimited flexibility.
Solution
Disable the default
In your Jira Service Management project, go to Project Settings > Satisfaction settings
Set the option Collect customer satisfaction feedback to off
Create the Automation rule
Navigate to Project Settings > Automation Rules
Click on Create rule
Add the Trigger Issue transitioned with the details:
From status: Blank
To status: your resolved status (for example "Resolved")
Click on Save
Add the Action: Set entity property with the details
Entity Type: Issue
Property key: feedback.token.key
Property value:
{"token":"{{#=}}CEILING(RANDOM()*100000000){{/}}{{#=}}CEILING(RANDOM()*100000000){{/}}{{#=}}CEILING(RANDOM()*100000000){{/}}{{#=}}CEILING(RANDOM()*100000000){{/}}{{#=}}CEILING(RANDOM()*100000000){{/}}{{#=}}CEILING(RANDOM()*100000000){{/}}","issueID":{{issue.id}},"userKey":"{{reporter.key}}"}
Click on Save
Add the Action: Send email with the details:
To: Reporter
Subject:
{{issue.key}} has been marked as resolved
More options: Uncheck "Convert line breaks to HTML line breaks"
Content: Enter your customized email content here. The example below is the default Jira Service Management email HTML content
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <base href="https://YOUR_JIRA"> </head> <body> <div class="jsm-message-content" style="margin-bottom: 30px"> <div class="jsd-activity-item-content"> <p>admin changed the status to Resolved.</p> </div> <hr class="jsd-activity-item-separator" style="border: none; border-bottom: 1px solid #cccccc"> <p></p> <div class="jsd-activity-item-content"> <p>admin resolved this as Done.</p> </div> <div class="srf-section" style="min-width: 280px"> <br> <div class="jsd-satisfaction-survey-question srf-question" style="font-weight: 700"> How was our service for this request? </div> <div class="srf-line-break" style="min-height: 10px; max-height: 10px; font-size: 8px; line-height: 10px; display: block; width: 100%; overflow: hidden"> </div> <table class="srf-star-table srf-star-table-with-text" style="width: 200px; width: 400px" width="400"> <tbody> <tr> <td class="srf-star-row srf-star-with-text" style="vertical-align: top; text-align: center; width: 75px; border: none; display: table-cell" width="75"><a href="https://YOUR_JIRA/servicedesk/customer/portal/2/{{issue.key}}/feedback?token={{issue.properties."feedback.token.key".token}}&rating=1" class="jsd-satisfaction-survey-star srf-star" style="color: #666666; text-decoration: none; font-size: 40px; border: none; display: inline-block; vertical-align: top">☆</a><p class="srf-text" style="margin: 0; padding: 0; font-size: 13px; font-weight: 400; line-height: 20px; text-align: center">Very poor</p></td> <td class="srf-star-row srf-star-with-text" style="vertical-align: top; text-align: center; width: 75px; border: none; display: table-cell" width="75"><a href="https://YOUR_JIRA/servicedesk/customer/portal/2/{{issue.key}}/feedback?token={{issue.properties."feedback.token.key".token}}&rating=2" class="jsd-satisfaction-survey-star srf-star" style="color: #666666; text-decoration: none; font-size: 40px; border: none; display: inline-block; vertical-align: top">☆</a><p class="srf-text" style="margin: 0; padding: 0; font-size: 13px; font-weight: 400; line-height: 20px; text-align: center">Poor</p></td> <td class="srf-star-row srf-star-with-text" style="vertical-align: top; text-align: center; width: 75px; border: none; display: table-cell" width="75"><a href="https://YOUR_JIRA/servicedesk/customer/portal/2/{{issue.key}}/feedback?token={{issue.properties."feedback.token.key".token}}&rating=3" class="jsd-satisfaction-survey-star srf-star" style="color: #666666; text-decoration: none; font-size: 40px; border: none; display: inline-block; vertical-align: top">☆</a><p class="srf-text" style="margin: 0; padding: 0; font-size: 13px; font-weight: 400; line-height: 20px; text-align: center">Neither good nor poor</p></td> <td class="srf-star-row srf-star-with-text" style="vertical-align: top; text-align: center; width: 75px; border: none; display: table-cell" width="75"><a href="https://YOUR_JIRA/servicedesk/customer/portal/2/{{issue.key}}/feedback?token={{issue.properties."feedback.token.key".token}}&rating=4" class="jsd-satisfaction-survey-star srf-star" style="color: #666666; text-decoration: none; font-size: 40px; border: none; display: inline-block; vertical-align: top">☆</a><p class="srf-text" style="margin: 0; padding: 0; font-size: 13px; font-weight: 400; line-height: 20px; text-align: center">Good</p></td> <td class="srf-star-row srf-star-with-text" style="vertical-align: top; text-align: center; width: 75px; border: none; display: table-cell" width="75"><a href="https://YOUR_JIRA/servicedesk/customer/portal/2/{{issue.key}}/feedback?token={{issue.properties."feedback.token.key".token}}&rating=5" class="jsd-satisfaction-survey-star srf-star" style="color: #666666; text-decoration: none; font-size: 40px; border: none; display: inline-block; vertical-align: top">☆</a><p class="srf-text" style="margin: 0; padding: 0; font-size: 13px; font-weight: 400; line-height: 20px; text-align: center">Very good</p></td> </tr> </tbody> </table> <br> <br> </div> </div> <p> <a class="jsm-issue-link" href="https://YOUR_JIRA/servicedesk/customer/portal/2/{{issue.key}}?sda_source=notification-email" style="color: #0052cc; text-decoration: none">View request</a> <span class="jsm-link-separator" style="padding: 0 10px">·</span> </p> <p class="jsm-request-sharedwith" style="color: #7a869a; font-size: 12px"> This is shared with admin@atl-cd.net. </p> <p class="jsm-help-center-footer" style="color: #7a869a; font-size: 12px"> Help Center, powered by <a class="jsm-servicedesk-link" href="https://www.atlassian.com/software/jira/service-management?utm_medium=email&utm_source=service-desk_email-notification_server&utm_campaign=service-desk_email-notification_server" style="color: #0052cc; text-decoration: none">Jira Service Management</a>, sent you this message. </p> </body></html>
If you use the above HTML content, you will need to:
Replace YOUR_JIRA with your Jira's base url and context path
Replace /customer/portal/2/ with the customer portal URL for this project
Click on Save
Give your rule a name and turn it on
Result
This rule setup will replace the default configuration, and the customized email will go out to your customers.
Don't forget to test this!
Was this helpful?