Get all user endoint returns only 1000 records at a time.

uttam kachhad May 12, 2021

I am using the REST API V2 version and want to get all JIRA users. 

I am using GET rest/api/2/users?maxResults=2000 Endpoint for getting all JIRA users but It will return 1000 instead of 2000 users. 

Can anyone please help me out with this issue?

1 answer

0 votes
Warren
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.
May 12, 2021

Hi @uttam kachhad 

All other API calls only return 100 results.

What you'll need to do is to page through all the results using the startAt parameter, so you can either set maxResults to 1000 or leaving it off. 

The first call will have startAt=0, then the next one will be startAt=1000 etc. until you have all the results.

I've just looked at the documentation here which states that only 50 results are returned at a time, so I'm not sure how you are getting 1000.

uttam kachhad May 12, 2021

If we set maxResults=1000 then it will return 1000 user's data at a time. If we don't pass maxResults then it will return default as 50 records.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events