Is there a way to distinguish between IssueCommented, Issue Comment edited and Issue Comment deleted in scriptrunner.
Please find the attached image, I am exactly trying to do the same thing to distinguish between these 3 events.
Below image is from adaptavist, I am trying to do something similar.
Hi Sameer,
Thank you for your question.
Can I please check if you are using Jira Server or Jira Cloud as your screenshot which you have attached shows some Jira Server code configured as Jira Cloud is different to the server version as described here due to the fact that the Java API does not exist in Jira Cloud.
If you wish to ask this question for the server version then you will need to recreate your post here and tag it with the tag of: com.onresolve.confluence.groovy.groovyrunner
In the meantime, I can answer your question relating to Jira Cloud and can confirm that it is possible in ScriptRunner for Jira Cloud to know what event was fired for the Comment Created, Comment Deleted and Comment Updated events.
The reason for this is that we provided a variable called webhookEvent in the binding for Script Listeners in Jira cloud for these events and you can check what the value of this variable is in your script in order to see what event triggered the listener script to run.
If this response has answered your question can you please mark it as accepted so that other users can see it is correct when searching for similar answers.
Regards,
Kristian
Hi kristian,
I am using Jira server. I posted my question over here again -
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.