Hi Team,
I have created a custom Text Field (single line).
I want to show the custom field NAME in the Email send from JIRA automation when issue transitions from one status to another.
I tried multiple time to pass the below syntax, but failing to show the custom field name in outgoing email.
Failed ones:
1) {{issue.customField_XXXXX.value}}
2) {{issue.customField_XXXXX.name}}
3) {{customField_XXXXX.name}}
4) {{customField_XXXXX.displayName}}
5) {{issue.customField_XXXXX.displayName}}
Only this was successful but it is showing the value of custom field - I want to see the Display Name of the custom field:
{{customField_XXXXX}}
Please provide a correct syntax of how to show the Name of the custom field in jira automation.
Thank you
Based on what you've described, I'd say that Notification Assistant for Jira might be an alternative for you to reach out your goal:
It might help you even showing different field values on the notification if needed.
Hope it helps.
Cheers,
Victor
Hello @Digvijay Singh Gehlot
I found an older post that asked the same question but had no validated solution.
According to the documentation {{issue.[Custom field].name}} should work.
https://support.atlassian.com/cloud-automation/docs/jira-smart-values-issues/#--issue.
However when I tested this on my own system, no information was returned. I was testing with a Global custom field of a native custom field type (not a custom field in a Team Managed project, nor a custom field where the type was supplied by a third party app).
So far I have not found an issue in Atlassian's public backlog about this.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Digvijay Singh Gehlot and @Trudy Claspill
This smart value is documented as working for Jira Cloud and Server / Data Center, and here is the open defect for it not working for Cloud:
https://jira.atlassian.com/browse/AUTO-1069
Looking at the REST API for Cloud, it appears the names are only returned when the expand=names parameter is passed. And so a workaround would be to call the REST API to get the name.
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Bill Sheboy
Thank you for your message.
May you guide me on how I can use REST API to get the name of the custom field via Jira automation?
Any screenshots, help docs or step by step process will be a great help.
Thanks,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
First thing, as you are already referencing the custom field by its ID value, I recommend just hard-coding the field name. That will be much simpler and more efficient for an email action.
Regarding how to do this with the REST API instead...
https://<yourinstanceurl>/rest/api/2/issue/<issuekey>?expand=names
{{webhookResponse.body.names.customfield_12345}}
Here are some references to help...
How-to article for calling a REST API function with Send Web Request:
https://community.atlassian.com/t5/Jira-articles/Automation-for-Jira-Send-web-request-using-Jira-REST-API/ba-p/1443828
The specific function to call:
https://docs.atlassian.com/software/jira/docs/api/REST/9.13.0/#api/2/issue-getIssue
An example showing a call to that function:
https://confluence.atlassian.com/automation/find-the-smart-value-for-a-field-993924665.html
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.