Uploaded image for project: 'Jira Align'
  1. Jira Align
  2. JIRAALIGN-3998

RestAPI: Add Patch request for Epic links doesn't work as expected

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Low Low
    • 10.107.0
    • 10.105.3
    • REST API
    • 1
    • Severity 3 - Minor
    • No

      Issue Summary

      Doing a Patch request to rest/align/api/2/Epics/EpicId endpoint with Add operation returns error "Cannot update epic with id EpicId. Cannot update links. Id shouldn't be empty."

      When ID is added to the request, 204 success status is returned, but a link is not added.

      Steps to Reproduce

      Make a PATCH request to rest/align/api/2/Epics/EpicId endpoint with the following body:

      [
        {
          "op": "add",
          "path": "/links/0",
          "value": {
             "name": "linkymclinkface",
             "link": "somelink.com"
          }
        }
      ] 

      Returns "Cannot update epic with id EpicId. Cannot update links. Id shouldn't be empty."

      Or when adding a new id that's not in DB:

      [
        {
          "op": "add",
          "path": "/links/0",
          "value": {
             "id": 57,
             "name": "linkymclinkface",
             "link": "somelink.com"
          }
        }
      ] 

      Returns 204, but a link is never added. Can send the same request with the same id multiple times.

      Expected Results

      Add operation should create a new link or return a valid error.

      Actual Results

      The returned error doesn't make sense when adding a new link, and status 204 success doesn't create a new link.

      Workaround

      Currently, there is no known workaround for this behavior. A workaround will be added here when available.

            njones3@atlassian.com Nathan Jones (Inactive)
            c7f2a2ebc58e Kirill Duplyakin
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: