Hi,
Is there a way in Jira Automation to capture the "Comment Edited" event? I have created an automation to handle the "Comment Added" event. However, I want to capture a comment-edited scenario and send a notification with "--EDITED COMMENTS--" in the header. The goal is to create two Jira automations: one for when a comment is added and another for when a comment is edited, each with slightly different messaging.
Thank you for your response.
Regards,
Kent
Hi @Kent Chiu
What problem are you trying to solve? That is, "why do this?" Knowing that may help the community to offer better suggestions.
Until we know that...
There is built-in notification where people can watch work items for updates of various types.
And if you are encountering situations where the built-in rule trigger for comment edited is not working as expected, I recommend investigating that to learn why it is not triggering. I do not see any open defects in the public backlog for that symptom with automation rules.
Kind regards,
Bill
Hi @Bill Sheboy ,
Thank you for responding to my inquiry. When I refer to "Automation," I am referring to JIRA Cloud Automation, not the JIRA API call for automation.
I have written a JIRA Automation rule to track comments in JIRA, detect a specific keyword in the comment, and post the comment to Slack. So far, all new comments are working correctly. However, if I edit an existing comment, the automation fails to detect the change.
I don’t see a trigger to capture edited comments.
Thanks,
Kent
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
As noted, there is a trigger to detect editing a comment. Are you observing that does not start the rule?
How are you changing the comments: a person edits it, a rule edits it, etc.?
Please post an image of your complete rule, in a single image for continuity, and an image of the audit log details showing the rule execution. Those may provide context to help explain what you are observing.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Kent Chiu,
Unfortunately, Jira Cloud automation doesn't have a dedicated "Comment edited" trigger. The available comment-related triggers are:
Workaround options:
Option 1: Single rule with smart values Instead of separate rules, use one "Issue commented" trigger and detect edits using:
{{#if comment.updated}}
--EDITED COMMENT--
{{else}}
--NEW COMMENT--
{{/if}}
Option 2: Advanced fields approach
{{comment.created}}
vs {{comment.updated}}
Option 3: Scriptrunner (if available) If you have Scriptrunner, you can create more sophisticated comment event handlers.
Limitation note: Jira's comment editing detection has been a long-standing community request. The platform treats edits as updates rather than distinct events, making differentiation challenging.
Alternative approach: Consider whether you actually need separate automations. Users might prefer a single notification that clearly indicates if it's new/edited rather than multiple notifications for the same comment thread.
Have you tested if the "Comment updated" trigger works consistently in your instance? Results can vary.
If you need help setting up the smart value approach, feel free to DM me!
Best,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Vitalii Rybka ,
Thank you for your response. I tried implementing your suggestion, but I'm encountering an issue with capturing edited comments using the smart value {{issue.comment.updated}}. I used a condition to check if {{issue.comment.updated}} equals 1, but it doesn't seem to work. For some reason, editing an existing comment doesn't trigger the automation. I want to implement this using the smart value approach.
The automation works for the comment added, but it does not work at all for the comment edited.
Could you kindly provide further assistance? I appreciate your help.
Here is the JIRA automation:
Thank you,
--Kent
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.