Details
-
Bug
-
Resolution: Unresolved
-
Medium
-
Minor
-
Description
Issue Summary
The REST API for updating issue link types returns the wrong self object and the previous object prior to update, rather than the newly updated one. This forces additional REST API calls to get the updated value.
Steps to Reproduce
- Create a new issue link type, e.g.
Name: New Issue Link Type Name
Inward: New Inward
Outward: New Outward
New Issue Link Type is now created with id 1052
- Run the following curl command
curl --location --request PUT 'https://your-domain.atlassian.net/rest/api/3/issueLinkType/1052' \ --header 'Accept: application/json' \ --header 'Content-Type: application/json' \ --header 'Authorization: Basic XXX' \ --header 'Cookie: atlassian.xsrf.token=xxxxxxxx' \ --data '{ "name" : "Changed Issue Link Type Name", "inward" : "Changed Inward", "outward" : "Changed Outward" }'
Expected Results
Rest call to return updated issue link type and
Self should be
"self": "https://your-domain.atlassian.net/rest/api/3/issueLinkType/1052"
Response 200: { "id": "1052", "name" : "Changed Issue Link Type Name", "inward" : "Changed Inward", "outward" : "Changed Outward" "self": "https://your-site.atlassian.net/rest/api/3/issueLinkType/10152" }
Actual Results
Response payload is the previous issue link type values and the self is incorrect:
"self": "https://your-site.atlassian.net/rest/api/3/issueLinkType/10152/10152"
ID is written twice.
Response 200: { "id": "10152", "name": "New Issue Link Type Name", "inward": "New Inward", "outward": "New Outward", "self": "https://your-site.atlassian.net/rest/api/3/issueLinkType/10152/10152" }
Workaround
Perform another Get issue link type call to get the updated values after doing the PUT call.
Attachments
Issue Links
- has a derivative of
-
ISSUE-16499 Loading...