Forums

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

How to create an issue in Jira automation with inherited Goal

Rees_ Ian
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 4, 2025

Hi, I want to create an automation that create another issue and inherits the Goals from its parent.. My first attempts was just to copy the field Goal from the parent but that fails with "We excluded the configured field from this action as it couldn't be found:".

So I then I tried setting Additional fields as follows  

{ "fields": { "Goals":"{{triggerissue.Goals}}" } }

 

The rule executes ok but the created issue's Goals field is not set.  

Prior to creating the issue, I log {{triggerissue.Goals}} which logs as 

{id=ari:cloud:townsquare:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx::goal/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}  are some hex numberexample 1.PNGexample 2.PNG

2 answers

1 accepted

2 votes
Answer accepted
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 6, 2025

Hi @Rees_ Ian 

There are several fields named "Goal" or "Goals" in Jira, depending upon the product and project type.  What type of product and project are you using with the field: a custom field you added, a Jira Product Discovery (JPD) field, an Atlas goal, etc.?  Thus, they also may have different field types.

And, because of the multiple fields with similar names, it may help to set the field using the custom field ID and JSON (paying attention to the field type for the syntax).  I recommend identifying an example work item with your field, and then using the how-to article below to determine if the field is supported by automation rules and its custom field ID:

https://support.atlassian.com/cloud-automation/docs/find-the-smart-value-for-a-field/

Kind regards,
Bill

Rees_ Ian
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 7, 2025

Thanks Bill - it is an Atlassian Home 'Goals' (was Atlas).

When I list all the fields, I see Goals mentioned twice.

Once in the names section

 "customfield_14390": "Goals",


and then later

 "customfield_14390": [
{
"id": "ari:cloud:townsquare:nnnnnnnx-xnnn-nnxx-xnnn-nxnxxnxnxxnn:goal/xnnnnxnn-nnnn-nxnn-nnxn-nnnnxnnnxnnnnnnn"
}
],

when nx etc is a mixture of alpha and number. 

So firstly I tried just replacing Goals with "customfield_14390" and setting the value to exactly what was logged

{
    "fields": {
        "customfield_14390": "{id=ari:cloud:etc etc  etc etc}"
    }
 } - the rule ran successfully but the Goals wasn't set on the created issue

I then tried the following syntax to set the custom field  such as

{
    "fields": {
        "customfield_14390": {
            "id": "ari:cloud:townsquare:nnnnnnnx-xnnn-nnxx-xnnn-nxnxxnxnxxnn:goal/xnnnnxnn-nnnn-nxnn-nnxn-nnnnxnnnxnnnnnnn"
        }
    }
}

but I keep getting the error "Operation value must be a string (customfield_14390)"

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 7, 2025

Thanks for the additional information, and...according to these open suggestions, that field is not supported yet by automation rules: 

https://jira.atlassian.com/browse/AUTO-1683
https://jira.atlassian.com/browse/JRACLOUD-93486

I suspect there is no public "write" REST API endpoint for the field yet, and so rules cannot change it.  Here is the separate suggestion to create that REST API:

https://jira.atlassian.com/browse/ATLAS-140

Like Aaron Geister [Trundl] likes this
Rees_ Ian
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 10, 2025

Thanks Bill

Like Bill Sheboy likes this
0 votes
Aaron Geister [Trundl]
Community Champion
April 4, 2025

@Rees_ Ian 

You are almost there. In the last screen shot you have copy from current issue, you might want to change that to trigger issue and it should fix the issue for you. 

Rees_ Ian
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 6, 2025

I'm afraid not - even if you change that to triggerissue - you still get the error "We excluded the configured field from this action as it couldn't be found:"

Like Aaron Geister [Trundl] likes this
Rees_ Ian
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 6, 2025

I've tried lots of different ways but just cannot seem to set the Goal on a created issue

Like Aaron Geister [Trundl] likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events