We've written a Ruby script that you can use to import users on your own: import_users.rb
You'll want to pass a full-access API v2 access token, the requester email of the user making the change, and the path to your CSV file as command line arguments; here, an example command is shown:
ruby import_users.rb -a tKvs3QDNi84Nl326Krdz -e [email protected] -f ./users.csv
The usage instructions for the tool can be found by executing the script with a
import_users.rb -h Usage: import_users.rb [options] -a, --access-token [String] Access Token -e, --requester-email [String] Requester Email -f, --csv-path [String] Path to CSV file
The CSV file can be named anything - you'll just need to make sure the path is correct.
Below is the required format for the CSV file. The email address and phone number will be set up as an immediate notification rule for the user (for both phone calls and SMS). The user's role can be
read_only_user (Full Stakeholder), or
read_only_limited_user (Limited Stakeholder) and defaults to
user if not specified. To see how these values map to values on the webpage, please refer to our section on Roles in the REST API and SAML. You can find additional information on user roles and permissions here.
The CSV file should be in format
name,email,role,title,country code,phone number,team 1;team 2;team 3. There's no need to include a header in the file and the title and teams are optional. If the user is on multiple teams, they should be separated by a semicolon. Here's a sample CSV:
Joe User,[email protected],user,Operations Engineer,1,5555555555,Engineering;Operations Bob Dobbs,[email protected],admin,Director of Engineering,86,15555555554,Engineering;Operations;Leadership
Create a spreadsheet with the following columns, in this order:
Name: Required - First and last name
Role: Required - Must be valid REST API user role (admin, user, limited_user, observer, restricted_access, read_only_user, read_only_limited_user) [* = requires stakeholder licenses]
Title: Optional - Job title
Country Code - Optional - 1-to-3 digit country calling code
Phone Number - Optional - Phone number
Teams - Optional - Teams to which user will be added, can include multiple teams separate by semicolons (;). If team does not exist, it will be created upon script execution
Team Role - Optional - User role that will be applied to the given teams, must be valid team role (responder, observer, manager)
Here are spreadsheet templates for your use:
After populating a spreadsheet in this format, export as any spreadsheet file (.CSV, .XLSX, .NUMBERS, etc) and send the file to our support team.
Updated 2 months ago