Forums

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

How do I display a custom field value in an automation log?

Phil Bustin
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.
January 26, 2024

I'm seeing no values in automation logs for add a value to the log actions.

I want to avoid using numeric values in the actions because 1) I had to change the numeric values when I exported from one environment to the next, and 2) It's harder to understand the edit action using numeric values.

I tried variations such as quotes surrounding the field name, .displayName (with and without quotes around the field name), etc.

1 answer

1 accepted

2 votes
Answer accepted
Rudy Holtkamp
Community Champion
January 26, 2024

Hi @Phil Bustin ,

It depend what kind of fields you use.

But generally you can use: 

  • {{issue.fields.customfield_xxxxx}}
  • {{issue.fields.customfield_xxxxx.name}}
  • {{issue.fields.my custom field}}
  • {{issue.fields.my custom field.name}}

You can check it by filling in a Jira issue and then go to this URL in your browser:

https://[yoursite].atlassian.net/rest/api/latest/issue/ <issuekey>?expand=names

Then you can search for the custom field name, find the customfield id (e.g. customfield_10090) and see what the format and value is of that custom field. I recommend to use an extension in your browser which will pretty format the JSON. (I'm using JSON Formatter in Chrome).

And this will also help a lot:

https://support.atlassian.com/cloud-automation/docs/advanced-field-editing-using-json/

Phil Bustin
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.
January 29, 2024

After I posted the question, I changed {{issue.Business Analyst}} (as an example) to {{issue.Business Analyst.displayName}}, and that displayed the value.

Phil Bustin
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.
January 29, 2024

In one case, I needed a re-fetch data in order to display a single-user custom field after editing it.

Like Eshita Seelam likes this
Phil Bustin
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.
January 29, 2024

I added a reply for a different post here, by mistake.

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.
January 29, 2024

Hi @Phil Bustin 

Would you please post images of your complete automation rule and the audit log details showing the execution?  Those may help provide context for this symptom.  Thanks!

Kind regards,
Bill

Phil Bustin
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.
January 29, 2024

The question is resolved, using the solution {{issue.Business Analyst.displayName}} and a re-fetch data component. There may be better or other solutions, but I'm happy with this one.

Like Bill Sheboy likes this

Suggest an answer

Log in or Sign up to answer