Forums

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

Is it possible to Create/Update an X-ray test execution using an API/Python?

diego.barba1991
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 13, 2025

I've been looking into the documentation and several forums yet I haven't come across a way to:

1. Create a Test Execution using an APIs.

2. Assign a Test Execution to a Test Plan using APIs.

Any insight is greatly appreciated!!!

1 answer

1 accepted

Suggest an answer

Log in or Sign up to answer
1 vote
Answer accepted
Matteo Vecchiato
Community Champion
November 13, 2025

Hi @diego.barba1991 ,

Thank you for your question.

About the creation/import of test executions results, you can find the related docs in this page: https://docs.getxray.app/space/XRAYCLOUD/44577176/Import+Execution+Results+-+REST+v2#Importing-Execution-Results 

Hope it helps

diego.barba1991
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 17, 2025

Thank you! That's just what I needed!!

I built a new engine and now have the issue of receiving a 200 response code but no response data from Xray (In this case, the json with the execution key created with /import/execution is empty "{}", also no changes are seen on the test plan and no new test execution was created x.x)

For context, I'm trying to create an empty test execution, using all variables but the "tests" one, I tried different payload nomenclatures like using tests: [] or not using it at all yet I get the same issue...

Matteo Vecchiato
Community Champion
November 17, 2025

Hi,

Please consider to mark this response as replied.

For your second issue, I suggest to try with only one test a trying to debug adding/removing json parts.

Xray support could help also.

Regards

diego.barba1991
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
November 17, 2025

Thanks Matteo!! You've been extremely helpful! Can't thank you enough!

In case anyone comes across this issue, it is because the API is not built to create empty test executions, tests must be given in the "tests" variable!!

https://docs.getxray.app/space/XRAYCLOUD/44565311/Using+Xray+JSON+format+to+import+execution+results#test

TAGS
AUG Leaders

Atlassian Community Events