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

Misleading response when running the Rest API to get projects

    XMLWordPrintable

Details

    Description

      Issue Summary

      When running the Rest API to get projects (rest/api/3/project/search), a 200 response (Successful) is returned with a blank list if you add the incorrect username/email address in basic auth.

      Steps to Reproduce

      1. In a Jira site, run the following API with an incorrect username:
        curl --location --request GET 'https://<domain>/rest/api/3/project/search' \
        --header 'Content-Type: application/json' \
        --header 'Authorization: Basic <username:api-token>' \

      Expected Results

      The API call should fail and error 401 should be returned, informing that the username or password is invalid.

      Actual Results

      The API call returns the 200 response with a blank list.

      Workaround

      None so far.

      Attachments

        Activity

          People

            Unassigned Unassigned
            pgoncalves Petter Gonçalves
            Votes:
            2 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: