Forums

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

XRAY-Plugin: Teststeps creation via API

Martin Pohmer August 5, 2025

Hello community,

I have problems to create teststeps via the API - interface.

I am using the XRAY plugin, is the API different to the cloud solution?

Btw. I get an 404 error message.

I am very thankful for every hint

Martin

4 answers

Suggest an answer

Log in or Sign up to answer
0 votes
Martin Pohmer August 7, 2025

Hi, 
we couldnt manage it.
So I think we migrate to the cloud solution.

0 votes
Stefan Salzl
Community Champion
August 6, 2025

Hi @Martin Pohmer 

neither the native Jira RestAPI nor the XRAY RestAPI are capable of adding test steps.

 

But:

with XRAY comes another API - the graphQL API 

https://docs.getxray.app/space/XRAYCLOUD/44565894/GraphQL+API

 

This API consists of a manipulation method that can add test steps to existing test items. see the documentation in the link below:

https://us.xray.cloud.getxray.app/doc/graphql/addteststep.doc.html

 

Best
Stefan

Stefan Salzl
Community Champion
August 7, 2025

Hi @Martin Pohmer 

Please stick to answer within already open threads and not creating new answers everytime you answer.

Please give more details in order to be able to help you. 

What exactly did you try? what was the result? show your calls.

Furthermore:

what do you mean with „migrating to cloud solution“? In your original post you said you are running on cloud already. the solution i suggest is on cloud too. I tested the graphQL method and it does exactly that job.

If you give us more details about where you got stuck we might get this running.

Best
Stefan

Stefan Salzl
Community Champion
August 12, 2025

Hi @Martin Pohmer 

any further information?

Best
Stefan

0 votes
Martin Pohmer August 5, 2025

Primary: Jira Cloud with Xray Plugin
Endpoint: https://acialqcentris.atlassian.net
API Path: /rest/api/2/ (Standard Jira REST API)
Type: Jira Cloud (not Data Center)
Endpoint: https://xray.cloud.getxray.app/api/v1

I cannot use the import function cause we want to automate the workflow coming from the user story

0 votes
Marc - Devoteam
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.
August 5, 2025

Hi @Martin Pohmer 

Welcome to the community.

Which API endpoint are you using and are you on Cloud or DC?

To import test with test steps via Xray, you need to use the following API endpoint or the Test Case importer.

Importing+Tests+-+REST+v2 for API, check the correct URL REST+API and Authentication.

Importing+Tests+using+Test+Case+Importer 

 

Marc - Devoteam
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.
August 5, 2025

What is you goal.

You can add test steps to a Story.

You need to create a Test work item with test steps, and link this to the Story.

Like Martin Pohmer likes this
Martin Pohmer August 5, 2025

@Marc - Devoteam 

I want to create a test case from an existing user story with python using the API
and want to add test steps into the test case with API not with import.

Creating a testcase already is working and I can add a description
but I cannot create test steps in test details

for 
Action
Data
Expected result

Marc - Devoteam
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.
August 5, 2025

HI @Martin Pohmer 

Use the https://docs.getxray.app/space/XRAYCLOUD/44577092/Importing+Tests+-+REST+v2 

See structure on the example and make sure to use the correct API endpoint, see https://docs.getxray.app/space/XRAYCLOUD/44565892/REST+API 

DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events