Is there a way to access the user and form details when a Jira automation is triggered by a form submission?
I'm working with Jira Service Management (JSM) and I'm using the "Form Submitted" trigger in automation. What I'd like to achieve is to automatically add a comment to the ticket that includes:
Is there a smart value or method that would allow me to access this information and include it in an automation rule's comment action? If so, what smart values would I use?
Any help would be greatly appreciated! Thank you!
There is no way of getting the form name via a smart value. If you do not specify the form in the Form submitted trigger the only option would be to use the Forms REST API to get the name. {{initiator}} will get you the user that triggered the automation.
Thanks for the reply, but assuming there are multiple forms on the request how do we know which form was the form that was submitted to cause the triggering of the automation rule?
Would you call the Get form index endpoint sort to find the form that was most recently updated?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, the Get form index would get you the name of the form. If the issue has multiple forms then you just have to look at the updated property to figure out which form it was that was submitted.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This works; however, you need to be careful when submitting forms concurrently to give the automation some time to pull from the REST API the correct form that's been updated!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I agreed with what @Mikael Sandberg stated. For the FORM submitter, it should just be the issue reporter. Where you can just use {{issue.reporter.displayName}} assuming that you use your FORM setup to trigger issue creation.
Best, Joseph Chung Yin
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.