Create users in Atlassian Cloud using Postman and REST APIs
Platform Notice: Cloud Only - This article only applies to Atlassian products on the cloud platform.
When to use this article
This article may be used any time there is a need to create users in bulk in Atlassian Cloud (Jira or Confluence).
When not to use this article
For organizations with users and groups provisioned with Atlassian Guard SCIM, use the Atlassian Access User Provisioning REST API.
Prepare data
- Use a text editor to prepare a text document listing the email address of all users to be created.
All users must have valid email addresses (with a mailbox attached) to later receive an email to reset their password upon first sign in. - Ensure the first row has a header row labelled
emailAddress
. - Save the file as a csv, now containing a list of email addresses with users to be created.
- Add a column labelled
products
for the default membership of the users
Sample file
emailAddress,products
dgrechen@bancly.com,jira-software
khaulkham-fraben@bancly.com,jira-software
igunston2@bancly.com,jira-software
pmaynell3@bancly.com,jira-software
Set up Postman
This section may be skipped if:
a collection named "Atlassian Cloud User Management" has previously been set up, and
an environment named "Atlassian Cloud" has previously been set up
Set up REST API call
Click New, or type
Ctrl
+N
(Windows/Linux) orCmd
+N
(MacOS).Select "HTTP".
Name the request "Create User in Atlassian Cloud".
Change the method from
GET
toPOST
.In the URL, paste:
{{cloudUrl}}/rest/api/2/user
Click the "Authorization" tab.
Ensure Type is "Inherit auth from parent".
- Click the "Body" tab.
Click "raw".
Change the content type to "JSON".
Paste the following block in payload area:
{ "emailAddress": "{{emailAddress}}", "products": [ "{{products}}" ] }
noting the {{emailAddress}} and {{products}} matches the csv header (case-sensitive).
Click Save, saving into the "Atlassian Cloud User Management" collection.
Execute runner
Change the environment using the environment selector at the top right of Postman, selecting "Atlassian Cloud".
Select Collections in the sidebar.
Select the "Atlassian Cloud User Management" collection.
On the Overview tab, select ▶️ Run towards the top right corner.
Under Run order, ensure there is one and only REST API call - "Create User in Atlassian Cloud".
On the Functional tab, select Run manually.
Click Data.
Navigate to and select the previously prepared csv file.
Reduce the number of "Iterations" under Run configuration to 1.
Leave Advanced settings as is.
Click Run Atlassian Cloud User Management.
Check Postman to ensure the runner collection has passed all tests. The run results should show:
"Iterations" and "All tests" to be equivalent in count
Passed (n) where n is the number of iterations
Failed (0)
Skipped (0)
Check admin.atlassian.com to ensure the user count has been increased by one. Check the user's access permissions. They will inherit default access permissions.
Rerun Postman Runner following the previous steps, with the number of "Iterations" set to the number of rows in the csv file.
References