Forums

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

How to link a zephyer test case to a jira ticket

Siva Barri July 28, 2023

Hello Team,

 

How to link a exisiting zephyer test case to a jira ticket using Rest APIs. Can anyone share a sample curl, I can try.

 

Regards,

Siva

3 answers

0 votes
Jacob Saunders March 4, 2025

You can manually link a Jira issue to a Zephyr Scale test case by adding the Jira issue to the first line (or any line) of the script on the Zephyr Scale test player.

Also, if you are creating new Jira issues via CSV upload, you can link Jira issues using the "Coverage (Issues)" field under Traceability.

Finally, if you are trying to bulk edit linked Jira issues on a number of Zephyr Scale test cases, you can either add to or replace existing Jira issues under Zephyr Scale > Test Cases > More > Edit selected test cases in bulk.

Were you trying to use an API to bulk-link existing Jira issues to different Zephyr Scale test cases? E.g. you have a spreadsheet with the Zephyr Scale test case ID and associated Jira issues to be linked, and you are looking to have these linked using an API? This I have yet to attempt, lol

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.
July 31, 2023

Hi @Siva Barri 

What Zephyr app are you running?

Enterprise

Or in Jira and then Scale or Squad ?

Siva Barri July 31, 2023

Hello,

 

I am using Zephyer Scale Server. I have a solution for it. Please have a look below comments.

Like Marc - Devoteam likes this
0 votes
Benjamin
Community Champion
July 28, 2023

Hi, 

 

Welcome to the community!

 

Here's the documentation for Zephyr API

 

https://zephyrdocs.atlassian.net/wiki/spaces/ZFJCLOUD/pages/1686798372/Test+Automation+API+Documentation

 

Didn't see anything in the documentation related to linking. So looks like the Zephyr Test cases are like Jira Issues where you probably could use just the Jira Api for linking tickets. See link below:

 

https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-links/#api-group-issue-links

Siva Barri July 30, 2023

Hello,

 

Thank you for responding. Anyways, it did not worked for me. I have raised a request with my query.  If I get a answer or I will be able to solve it. I will share the solution here. 

Like Benjamin likes this
Benjamin
Community Champion
July 31, 2023

Sounds good. Hopefully, there's an API call option.

Siva Barri July 31, 2023

Hello,

 

I got the solution, Here is curl , which worked for me.

 

curl --location --request PUT 'https://<Jira URL>/rest/atm/1.0/testcase/TestCase ID' \
--header 'Authorization: Bearer <Jira Auth Token?' \
--header 'Content-Type: application/json' \
--header 'Cookie: JSESSIONID=6003A2556E0CC3112B16007259E3648C; atlassian.xsrf.token=BIZK-WQVJ-ABWK-F14N_8c880f3406bab925b6d1af83c270350db5fdbf1a_lin; AWSALB=a8zxFKxgx7NxUm7jpfAM7Yb+ZApsLLBeWfiSO9YjyTgj+US1VXfQXRgDNTEKB2OfSCAXF1zTw1hms1GyzdQ11WagWi2pG/JVPFk6a2NZL1PI66r1Dgplbhxy5YDU; AWSALBCORS=a8zxFKxgx7NxUm7jpfAM7Yb+ZApsLLBeWfiSO9YjyTgj+US1VXfQXRgDNTEKB2OfSCAXF1zTw1hms1GyzdQ11WagWi2pG/JVPFk6a2NZL1PI66r1Dgplbhxy5YDU; JSESSIONID=E011958AF61BD69E755BF30D48B0454B; atlassian.xsrf.token=BQ1N-6AO8-TUVU-90JB_27b4f4f25e46bb34d82204dd9c492f3749370a62_lin' \
--data '{
"name": "Ensure the axial-flow pump is enabled",
"status": "Approved",
"issueLinks": [
"<Jira Story Id>"
]
} '

Suggest an answer

Log in or Sign up to answer