Better error code and message when using REST API to retrieve Org's directories and missing scope read:directories:admin

XMLWordPrintable

    • 1

      When calling the following REST API endpoint to retrieve directories of an org, using API key with scope but missing read:directories:permission, it will return 404 Not Found rather than 401 or 403 which caused confusion.

      For example:

      {    
          "timestamp": "2026-03-12T23:56:28.289+00:00",    
          "path": "/api/admin/v2/orgs/<org_id>/directories",    
          "status": 404,    
          "error": "Not Found",    
          "requestId": "41ee559d-716390",    
          "message": "Not Found"
      } 

      Customer suggests to return 401 or 403, and error message.

              Assignee:
              Unassigned
              Reporter:
              Emily Q.
              Votes:
              2 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated: