How to fetch all users via user provisioning SCIM API

Still need help?

The Atlassian Community is here for you.

Ask the community


Platform Notice: Cloud Only - This article only applies to Atlassian products on the cloud platform.

Summary

Fetch all users from the provisioning directory using SCIM REST API.

Environment

User provisioning integration with Atlassian organization.

Solution

Run the Get users SCIM REST API to fetch all users from the user provisioning directory at the Atlassian organization.

Example:

curl --request GET \ --url 'https://api.atlassian.com/scim/directory/{directoryId}/
Users
' \
--header 'Authorization: Bearer <access_token>' \
--header 'Accept: application/json'

(info) In this example, 

  • directoryID: This is the ID of the user provisioning directory created at Atlassian organization.
  • access_token: This is the API token generated for the user provisioning directory.

This will provide a list of the first max 100 users in the provisioning directory at once. To fetch more than 100 users one can use the startIndex parameter in API.

Example: To fetch User 101 to 200

curl --request GET \
--url 'https://api.atlassian.com/scim/directory/{directoryID}/Users?startIndex=101' \
--header 'Authorization: Bearer <API KEY>'

Or 

curl --request GET \
--url 'https://api.atlassian.com/scim/directory/{directoryID}/Users?startIndex=101&count=200' \
--header 'Authorization: Bearer <API KEY>'

Example: To fetch User 201 to 300

curl --request GET \
--url 'https://api.atlassian.com/scim/directory/{directoryID}/Users?startIndex=201' \
--header 'Authorization: Bearer <API KEY>'

or

curl --request GET \
--url 'https://api.atlassian.com/scim/directory/{directoryID}/Users?startIndex=201&count=300' \
--header 'Authorization: Bearer <API KEY>'



Last modified on Feb 1, 2022

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.