Hi team,
I would like to be able to see or generate an overview of the values for compare process like:
{{comment.Request participants.accountId}}
How can I know or find out the field and sub option inside each value for automations compare? For example, I need to know if one of the "Request participants" did enter a comment and then change status.
Regards,
Jonathan
Hi Jonathan,
the smart values are based on the information Jira exposes via REST.
So you should be able to see the structure of a smart value (or a customfield) using the corresponding REST endpoint.
Here's an official documentation on how to find the available options of a smart value/field:
https://support.atlassian.com/jira-software-cloud/docs/find-the-smart-value-for-a-field/
I hope that helps.
Regards,
Philipp
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
This one is very interesting but I found out some custom values like this format
names.customfield_15501
Is it just the way it is? I mean, I can only use {{customfield_10034.value}} and not like {{customfield_10034.value.first}} or stuff like that?
And usually, if I see a field like "Request participants" I can just use it as I can see it?
Sorry If this like very beginners
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Jonathan,
what I can generally always recommend (and do myself) is to add a "Log action" element into your automation.
This adds whatever value in the audit log entry of each run of your automation.
Within this element, you can try all the smart values you can think of or would like to use. Also, you can see what the value of a smart value is during runtime.
This is always the easiest way to figure out what works and what doesn't - already saved me a lot of hassle, especially with smart values containing email recipients who I don't want to spam with test mails. :-)
That being said: There are different ways you can refer to a customfield. Either of those should work:
{{issue.customfield_10034}}
{{issue.Name Of Customfield}} (yes, even with blanks between words) (That also answers your question regarding Request Participant with "yes". However, when referring to fields by name, you always need to make sure there is _always_ only one field with that name)
Whether {{customfield_10034.value.first}} works or not, depends on the type of customfield. If it's a list, I *think* it should work. But it's best to test it with the method above.
I know for instance, that the following works for user picker fields:
{{issue.Some User Picker.emailAddress}}
Which returns the email address of the user that is selected in the user picker.
So along with the infos you can pull from the REST endpoint mentioned in the docs above, you also have to somewhat guess what Java allows in terms of methods for each value.
I hope that helps you on your adventure trackling automations and smart values. :-)
Regards
Philipp
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.