Enable conversion of issue to subtask via REST

XMLWordPrintable

    • 83
    • 7

      NOTE: This suggestion is for JIRA Cloud. Using JIRA Server? See the corresponding suggestion.

      As a REST caller, I want to be able to convert an issue to a subtask.

      In the UI, this is always done as a specific action, instead of via an "edit" of the issue type in an edit or transition. This would need to be the case in REST, as well.

      We need an endpoint like /rest/api/2/issue/idOrKey/convertToSubtask that performs this operation (and a companion that converts a subtask to an issue). We also need to provide the "editmeta" for the conversion, as the user may need to enter required fields (and/or there may be other new fields that the user should get an opportunity to fill, like in the UI).


      Original description
      I can't find a way to convert an issue into a subtask.

      Here is my json:

      {
          "fields": {
             "parent": {
                      "key": "TESTUN-3464"
              },
              "issuetype": {
                      "id": "5"
              }
           }
      }
      

      Answer:

      {"errorMessages":[],"errors":{"issuetype":"Issue type is a sub-task but parent issue key or id not specified."}}
      

      Am I doing something wrong ?

      Thanks for your help.

        1. screenshot-1.png
          185 kB
          Anusha Rutnam

            Assignee:
            Unassigned
            Reporter:
            Cyril RICHARD
            Votes:
            79 Vote for this issue
            Watchers:
            41 Start watching this issue

              Created:
              Updated: