403 Forbidden Error: JIRA Cloud REST API projectCategory

Hi,

We’re currently getting a 403 Forbidden error when calling the the JIRA Cloud Rest API for projectCategory from an Atlassian Connect Express app. In our development instance the app is provided all scopes in the atlassian-connect.json, as follows:

"scopes": [ 
  "READ",
  "WRITE",
  "DELETE",
  "PROJECT_ADMIN",
  "ADMIN",
  "ACT_AS_USER" 
]

Interestingly as an authenticated JIRA admin user in the browser we can hit “https://ourinstance.atlassian.net/rest/api/2/projectCategory” and the anticipated JSON object is returned containing a test project category which was created manually through the JIRA instance administration.

The simplified request code within our application is as follows:

AP.request({
   url: '/rest/api/2/projectCategory',
   type: 'GET',
   contentType: 'application/json',
   success: function(response) { 
       console.log(response);
   },
   error: function(response){
     console.log(response);
   }
});

Other REST API calls (e.g. issueTypes) are working as anticipated from the Connect Express app. Is there something we’re doing incorrectly with authentication? We have “JWT” listed a the authentication type in the atlassian-connect.json.

We’ve only recently started JIRA app development so any input, suggestions or help would be much appreciated.

Thanks.

1 Like

Hi @CallamPorch,

Same issue here (on setting user properties, but seems same symptoms). I talk about it here, but did you finally find out what’s the problem about? I would appreciate any help on that,

Cheers,

Fred

Hi @frederictardieu,

It was a while ago now, but given the complications we moved away from the idea of app specific projects for our customers. I sounds like from other discussions around the community that this might be an option in the future (see [comments], (Issue type schemes via REST), JRACLOUD-40141 & ACJIRA-440).

At the time I didn’t understand that apps can not access all REST resources. The latest documentation seems to call out more clearly that apps cannot access project category.

Hope this helps.

Cheers,

Callam

1 Like