Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

How to update issue parent in jira automation in nextgen projects?


I have the following automation in nextgen project:

* When issue is linked, assign the new linked issue to the source issue parent (epic).

However, I keep getting "invalid JSON" error.

Any idea?

Screenshot 2021-04-05 171807.pngScreenshot 2021-04-05 171823.png

4 answers

1 vote
Eric Atlassian Team Apr 06, 2021

Hi @Matan Grady ,


You should be able to select 'Epic Link' from the fields dropdown in Edit issue action.


Automation is able to figure out that the issue being acted on belongs to a next gen project and it will set the correct field (parent).



Hello @Eric

I need to update the field from advanced field editing.

This is how my JSON looks like.

Still I get an error of invalid JSON.

Screenshot 2021-04-07 084600.jpg1231321.jpg

Any ideas?

Like Sahar ben likes this
0 votes
Daniel Ebers Community Leader Apr 18, 2021

Hi @Matan Grady

looking at your requirement I was able to reproduce an automation rule which worked fine in my demo next-gen project.

Setup: I have an Epic (ACC-4) as well as a story (ACC-2) linked to the Epic.
Now I have an additional story (ACC-3) that I link to previously created Story ACC-2.
=> The Epic link (to ACC-4) is added to ACC-3

In case I got you right here is the automation rule so you can double check:


The interesting part might be "Edit issues fields" where the following JSON made it work:

"fields": {
"parent": {"key":"{{issue.issuelinks.inwardIssue.epic.key}}"}

"Add comment to issue" however was just for testing purposes - I would not put that into production.

In case you'd like to check and let us know if this is what you were looking for I'd appreciate that.


Hello @Daniel Ebers .

Still can't get it to work!

Note that I can't do the change on the branch as the item I am editing is on the main branch.


The setup I did it attached, so is the error I get ("Could not find issue by id or key. (parent)".65469879.jpg13246579.jpg132132132.jpg

Daniel Ebers Community Leader Apr 19, 2021

I am unsure if it works the way you setup the rule - probably this won't be the case.
Unfortunately, I cannot tell you anything beyond this but to confirm the rule I suggested worked in my setup.

Probably you will find other users contributing to fixing the rule you presented.

Hi @Matan Grady 

I believe you need to branch on the destination issue for that smart value to work.  Please look at this article for details:

Best regards,


Hello @Bill Sheboy , and thanks!

Actually I was managed to get the issue parent.
My problem is with updating the issue parent.

I can't understand if jira next-gen projects supports updating an issue parent.

When you edit/update an issue, that issue needs to be the focus in the rule.  For example, it needs to be the trigger issue or an issue within a branch's selection.

Although you may be able to see the key of a parent with the syntax you are showing, the rule isn't updating the parent: it is not "in scope".

Just to be clear, are you trying to update:

  1. the parent of the issue that triggered the rule, or
  2. the parent of the issue that was linked to the issue that triggered the rule?

If you want #1, as simple branch on parent should work.  If you want #2, you would need to use a branch on JQL for the key of that linked issue's parent.  They you may perform the edit within the branch.

Hi @Bill Sheboy ,


This is not my problme. My problem is how to update the issue (I am already on the right branch for it), but assign a parent to it.

For example, update issue X-123 to be a child of issue X-5.

@Matan Grady hi, I'm also trying to set a newly created initiative as parent to the triggered epic, but it's not working (JSON error).

How did you manage to set this link through JSON? 

Hi Indira -- Welcome to the Atlassian Community!

First, please consider creating a new question and linking to older threads when needed.  That will get the most visibility for people to help, as only the people currently watching this thread will see your post.

Next, for your question on automation rules, context is key.  Please post images of both your complete rule and the audit log details showing the rule execution.  That will help the community see what you are describing to offer suggestions.  Thanks!

Kind regards,

Like Indira likes this

hi @Bill Sheboy  thank you for your reply. I found the solution in the meantime (the automation created a new initiative from a triggered epic - the task was to make this created initiative the epic's parent). The parent linking is made in JSON in the following way:

"fields": {
"Parent link": "{{createdissue.key}}"

(sorry if this question is not relevant to this topic, in that case please delete my comments, since I am not able to do this). Thank you.

P.S. could you please delete my tag (surname) from your post above? Thanks in advance.

I updated it, and as an FYI...that information was coming from the name setup in your profile.  Please change that to match what you wish to display.  Thanks!

Like Indira likes this

@Sahar ben

let's see if we can find the answer here from the community.

Suggest an answer

Log in or Sign up to answer
Site Admin
Community showcase
Published in Jira Software

Upcoming changes to epic fields in company-managed projects

👋 Hi there Jira Community! A few months ago we shared with you plans around renaming epics in your company-managed projects. As part of these changes, we highlighted upcoming changes to epics on...

14,094 views 34 44
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you