Customer notification failures for scripted internal comments in Jira Service Management DC
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
Customers and request participants do not receive email notifications when a ScriptRunner for Jira job adds an internal comment to a Jira Service Management issue.
Diagnosis
Verify user roles and permissions
If some users receive notifications while others do not, verify their project roles:
Users receiving notifications for internal comments likely have a Jira Service Management license and Agent permissions.
Users not receiving notifications are likely Customers without a license.
If a comment must remain internal but you still need to notify customers, you must use a custom Automation for Jira rule with a Send email action rather than relying on standard Jira Service Management customer notifications.
Cause
Jira Service Management suppresses notifications for internal comments to protect agent privacy. When a script creates a comment with the internal property set to true, the notification engine identifies it as a private note. Consequently, users with only customer access (Reporters and Request Participants) are excluded from notifications, while licensed Agents may still receive them.
Solution
To ensure all customers and participants receive notifications, you must modify your script to create a public comment instead of an internal one. This is achieved by setting the internal property to false within the comment properties.
Update the ScriptRunner code
Locate the section of your ScriptRunner script where the comment properties are defined.
Identify the line that sets the internal property to true. It typically looks like this:
def properties = [(SD_PUBLIC_COMMENT): new JSONObject().put("internal", true)]Update the boolean value from true to false:
def properties = [(SD_PUBLIC_COMMENT): new JSONObject().put("internal", false)]Save the script and run the scheduled job or trigger to verify that notifications are now sent to all participants.
Was this helpful?