Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Service desk automation not working to add comment on incoming webhook

Mahdi Alikhani April 20, 2025

Hi, I want to add a comment when an incoming request is called.

I created this automation:

Screenshot 2025-04-21 at 00.13.54.png

And this is my Audit Log:
Screenshot 2025-04-21 at 00.15.48.png

The issue was found successfully, but the comment on the issue action is not working.
I tried the branch rule for JQL, but neither is working ..Does 
anybody know how to create an automation for this?

I'd appreciate your help!

1 answer

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 20, 2025

Hi @Mahdi Alikhani -- Welcome to the Atlassian Community!

Is the issue to which you want to add the comment the IT-69 one (from the webhook data)?

If so, please replace your Lookup Issues action with a branch using the same JQL as from the lookup, moving your Add Comment to Issue action inside the branch.  That will make that issue in scope for the rule to comment upon it.

Kind regards,
Bill

Mahdi Alikhani April 21, 2025

Yes, exactly.

I created the branch and the same JQL, but no comment has been made. 

I don't know why, but I also added an action log inside the branch, and it was not created.

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 21, 2025

Please post images of the version of the rule where you use the Branch on JQL and the audit log details showing the rule execution.  Those may help to explain why it did not work.  Thanks!

Mahdi Alikhani April 22, 2025

Screenshot 2025-04-22 at 21.53.21.png

 

This is my automation, and I'm sending this body to the API:

{
"comment": "test comment",
"serviceDeskKey": "IT-83"
}

But nothing happens.
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 22, 2025

Thanks for that information, and...

Where is your rule located and what is its scope (in the details at the top)?  That is, can the rule access the "IT" project's issues? 

If not, that would explain this behavior, and the rule must be moved or the scope changed to include that project.

Mahdi Alikhani April 23, 2025

Screenshot from 2025-04-23 10-49-58.pngScreenshot from 2025-04-23 10-50-32.png

This is the rule details 

Mahdi Alikhani April 23, 2025

Screenshot from 2025-04-23 11-17-33.png

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
April 23, 2025

Based on above, the calling rule is not sending the issue keys in the correct format for the trigger to use with the option "Gather issues from request".  Please see this documentation for the correct format:

https://confluence.atlassian.com/automation/jira-automation-triggers-993924804.html#Jiraautomationtriggers-incomingwebhookIncomingwebhook

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
10.5.1
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events