Bulk set issue property is returning 401 for no reason

When using postman to make the api call using basic auth everything works as expected, but when making the api call from within the addon it returns 401. It’s a problem only with this api call where it returns unauthorized even though I’m authenticating my call via Atlassian Host using atlassianHostRestClients class.
i changed the api call worked but when using the Bulk PUT api call it’s returning a 401.

String apiEndPoint="/rest/api/2/issue/properties/{propertyKey}"
atlassianHostRestClients.authenticatedAsAddon(atlassianHost).put(apiEndpoint, data);

I have all the needed Scopes from withing the addon (read, write, act_as_user, admin) tried them all but same result.

Any error with the authentication from within the addon concerning this api call ?

Hi @mohamadjawadAlHajjar. Two questions. First, are you certain that when you try to make a call with authenticatedAsAddon on a different method it works fine? Second, in addition to the required write scope for Connect apps, the docs state these permissions requirements as well:

That being said, if the projects permission schemes do not include atlassian-addons-project-access project role in both Browse projects and Edit issues, this may be the source of the problem. If you’re testing on your own instance, can you check on the permissions?

Hello @nmansilla ,
Thanks for your time to help me solve this issue.
Yes i’ve tried other api calls and they’re all authenticated, i even tried the set issue property (put) and it worked like a charm and it requires the same authentication as the bulk put.
I tried this api call on the same instance same issues same bulk api but from outside the addon and using basic authentication and it worked like a charm.
I believe this is a weird behavior, it’s giving me 401 only from the addon while using bulk set issue property.

@mohamadjawadAlHajjar and what about the atlassian-addons-project-access project role in the project(s) permissions?

@nmansilla ,

here as you can see the permissions are given but there’s an issue with the api, because like I said the single put (set issue property) is working from within the addon, but the bulk one is giving me a 401.

@mohamadjawadAlHajjar can you please file a bug report with complete details? Jira Service Management

@nmansilla ,
Yes i already did that through the rest api documentation, i reported a bug and mentioned the case. But didn’t get any response back yet!