Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Jira API returns 401 when fetching (some) project assignees

Artiom Petrov
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 4, 2019

Hello,

I'm trying to perform integration with Jira API (using basic authentication) to get all project assignees.

I'm addressing the following URL:

https://<jira_url>/rest/api/2/user/assignable/search?project={PROJECT_KEY}

For most of the projects I do get the assignees, but for some, for an unknown reason, I'm getting 401 unauthorized.

My guess is that the credentials I'm using don't have enough permissions for all projects.

So my questions are:

1. Is the permissions issue can possibly happen?

2. If yes, how can I reproduce this in my Jira account (how can I give permissions to some users for certain Projects)?

Thanks in advance!

1 answer

1 accepted

0 votes
Answer accepted
Jobin Kuruvilla [Adaptavist]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 4, 2019

1. Yes, it could be the permission issue

2. Login to the box, using the same credentials, and check if you have "Create" and "Assign" permissions in the projects where it is failing. If not, you will have to work with those project admins to grant you the access.

Artiom Petrov
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
February 5, 2019

Thanks!

I think It has something to do with the permissions of "Assign Issues". I removed my user's permission to assign issues, then got 401 for this project.

Jobin Kuruvilla [Adaptavist]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 5, 2019

Correct. You need the 'Assign' issue permission to retrieve the list of potential assignees.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events