Uploaded image for project: 'Jira Platform Cloud'
  1. Jira Platform Cloud
  2. JRACLOUD-67725

Misleading error while creating issue using REST API

XMLWordPrintable

      Summary

      Creating an issue through REST API without setting required fields throws a misleading error.

      Steps to Reproduce

      1. Set Description field to "required"
      2. run
        curl -vvv -u email@email.com -k -X POST -H "Accept: application/json" -H "Content-Type: application/json" -d '{"fields": { "reporter":{ "name": "test" }, "issuetype":{ "name": "Cloud Support" }, "project":{ "key": "XXX" }, "summary": "Testing"} }' "https://instance.atlassian.net/rest/api/2/issue"
        

      Expected Results

      It should throw an error informing that Description field is required

      Actual Results

      It throws

      {"errorMessages":[],"errors":{"summary":"Field 'summary' cannot be set. It is not on the appropriate screen, or unknown.","reporter":"Field 'reporter' cannot be set. It is not on the appropriate screen, or unknown."}}
      

      Application logs:

      Notes

      Workaround

      None

              Unassigned Unassigned
              aradmann aradmann (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:
                Resolved: