tests migration from Xray to Zephyr

Our company recently switched from Xray to Zephyr. I am looking to see if I can programatically migrate the test cases from Xray to Zephyr.

I have exported tests from Xray into JSON format using the Xray REST API.  My question is if ZAPI(Zephyrs REST API) would allow me to import these tests as is? Since ZAPI is an additional cost I like to know if this can indeed be achieved first before making any purchase.

Thanks for your help

3 answers

1 accepted

1 vote
Answer accepted

That's cool @Imran Ali

If you're are going to buy ZAPI, then yes, the migration could be done using ReST.

The steps would be as follows for each issue.

  1. Do a ReST call to pull the Test Case from X-Ray
  2. Do a ReST call to create a zephyr Test Case issue (IssueType = Test). The catch here is that you cannot import test steps. You can refer the tutorial here to create a JIRA issue using the JIRA ReST API
  3. Now, you can make use of the ZAPI API to add Test Steps to the create Test Issue. The API documentation for the create test step can be found here.
  4. Steps 1,2 and 3 should be repeated for each Test Case you have in X-Ray

Once you have all the test cases imported, you can now make use of the other ZAPI resources to create Test Cycles, folders etc. The complete documentation of ZAPI ReST calls can be found here.

I believe this helps. Let me know if you have any queries and I will try my best to answer it. If you think these are feasible, please mark the answer as accepted so that it will be easy for others to refer.

You can also try export the issues in CSV and try to export using a desktop tool provided by Zephyr to import the issues in CSV.

Thanks for the reply. I am not sure how I can export the issues from Xray into CSV format programmatically. I am using the REST API calls on Xray which returns a response in JSON format. 

@Arun Thundyill Saseendran hey.. can you help him out?

Thanks @Mahesh S

@Imran Ali Yes. There is no direct way to convert JSON to CSV. However, it is quite simple to extract the fields that are required into a CSV format file. And then on, importing it to Zephyr can be done using the Zephyr Import Utility.

You can get started with the Zephyr Import Utility here.

The Utility can be downloaded from here.

In this way, if you do not plan to use ZAPI for integrating with your Automation framework, you need not purchase just for the sake of migration.

Let me know if you face any issues. I can try helping you.

Thanks Arun. I am familiar with this utility already. There is a chance the team would adopt ZAPI already for CI so I like to know if what I am trying to do can be done with ZAPI without using this utility. If so I can postponed the migration till we get ZAPI

Hi @Imran Ali

I am currently looking into JIRA add-on for test management. I am inclined towards XRay over Zephyr because of the cost differences. I wanted to ask  how was your experience with Xray and why did your organisation moved from Xray to Zephyr?



Suggest an answer

Log in or Sign up to answer
Community showcase
Published Wednesday in Marketplace Apps

Marketplace Spotlight: Marketing apps for Confluence to keep your teams working on the same page


120 views 0 3
Read article

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you