The manage-users.sh
script helps on performing basic tasks to manage users using CartoDB Enterprise API. Actions available are:
- List users of an organization
- Create new users
- Delete users
- Update existing users (password and data quota)
- Retrieve users info (in JSON format)
You need to adapt the script for your environment, the variables are at the beginning of the script as follow:
BASE_URL="cartodb.lan"
ORG_NAME="organization"
ORG_OWNER="org-admin"
So the script is executed at organization level. Then, with the API key, run the script to perform any operation like:
API_KEY=you_api_key ./manage-users.sh list sample-users.csv
The CSV file needs to have columns on this form:
username,email,password,quota
Where quota needs to be expresed in megabytes (MB). For example:
bob,[email protected],bobsecret!,100
alice,[email protected],alicesecret!,100
There's a sample CSV file next to the management script.