Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Jira Automation - Adding Value in a Xray field using JSON

We're using the Xray tool for QA. I've created an automation task for the "Test Execution" issue using the Jira Automation add-on. It triggers base on text in a "Story". I mean when a story issue gets created and has some certain texts then it creates the Test Execution issue. That part is working well.

I would like to have a "Test" attached to a "Test Execution" whenever it gets created. The "Test" issue will be the same all-time for this project. The "Test Execution" Issue type has two tabs "General" and "Test Execution Details" in it's create issue screen. In "Test Execution Details" tab there is a field "Tests" where you can attach Test issues. I can't find that field from the Automation where I created the task. This is a built-in field from the Xray tool since I can't find it from the custom field list. I clicked on inspect and found the field id from the source code and tried to use the JSON option to adds the value "DP-17" in that field but it is not adding it. I tried multiple options nothing worked.

Any idea how I can make it works? Attaching screenshots that may help.

Option one

{"update": {
"customfield_13115": [
{ "add": {
"key": "DP-17" }
} ]
} }

Option 2

"customfield_13115": "DP-17"


Thank you


1 answer

0 votes
John Atlassian Team Oct 04, 2021

Hey @Shah Baloch,

This post sounds like it's related to the issue you're facing:



I viewed the other post and linked provided there, it is complicated. I couldn't understand. Thank you for sharing though.

Hi @Shah Baloch 

Since Jira Automation can execute Web Requests, please try the idea of using Xray REST API to add a Test to a Test Execution.

Please use the POST method described in this documentation page:

Thank you.

Kind regards,
Rogério Paiva [Xray Support Team]

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bitbucket

📣 Calling Bitbucket Data Center customers to participate in research

Hi everyone, Are you Bitbucket DC customer? If so, we'd love to talk to you! Our team wants to dive deep to understand your long-term plans regarding Bitbucket DC and Atlassian Cloud. Do you plan...

173 views 2 4
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