REST API v3 call to transitions endpoint doesn't work

XMLWordPrintable

    • 1
    • Minor

      Issue Summary

      The REST API call to /rest/api/3/issue/<issue-key>/transitions for API v3 doesn't work and outputs an error of "invalid comment body".

      Steps to Reproduce

      1. Create a project e.g. ABC
      2. Create an Issue
      3. Add a Screen to the workflow for the Issue Type you want to use
      4. Then use the transitions endpoint. an example would be curl.
      curl -X POST \ 
      --url 'https://<your-instance>.atlassian.net/rest/api/3/issue/AT2-76346/transitions' \          
      --user 'user@example.com:ojFZqrykxxXXXXXX' \
      --header 'Accept: application/json' \
      --header 'Content-Type: application/json' \
      -d '{                             
        "update": {       
          "comment": [  
            {         
          "add": {                      
            "body": {     
                "type": "doc",
                "version": 1,
                "content": [
                  {
                    "type": "paragraph",
                    "content": [
                      {
                        "text": "Let's think it in another way should work Prince Nyeche",                                                                         
                         "type" : "text"
                         }
                       ]      
                     }       
                   ]        
                }  
              }                         
            }                   
          ]            
        },              
      "transition": {
             "id":"31"  
        }
      }'
      

      Expected Results

      The transition is suppose to work and a comment should be updated

      Actual Results

      There's an error of "invalid comment body"

      Workaround

      Use the API v2 for the same endpoint instead.

            Assignee:
            Unassigned
            Reporter:
            Prince N (Inactive)
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: