Purpose: Create CommCare(mobile-worker) user.
Authentication: For more information, please review https://dimagi.atlassian.net/wiki/x/LwXKfw.
URL: https://www.commcarehq.org/a/[domain]/api/[version]/user/
Method: POST
Input Parameters: * means required
Name | Description | Example |
---|---|---|
username* | User name of user | jdoe |
password* | User password | qwer1234 |
first_name | First name of user | John |
last_name | Last name of user | Doe |
Email address of user | ||
phone_numbers | List of all phone numbers of the user. The first one will be set to the default number | (see examples) |
groups | List of all group ids belonging to the user | (see examples) |
user_data | Any additional custom data associated with the user | (see examples) |
language | User language | en |
Output Parameters:
Name
| Description | Example |
---|---|---|
user_id | User UUID | 3c5a623af057e23a32ae4000cf291339 |
Sample input:
JSON Format
{ "username": "jdoe", "password": "qwer1234", "first_name": "John", "last_name": "Doe", "default_phone_number": "+50253311399", "email": "jdoe@example.org", "language": "en", "phone_numbers": [ "+50253311399", "50253314588" ], "groups": [ "9a0accdba29e01a61ea099394737c4fb", "b4ccdba29e01a61ea099394737c4fbf7" ], "user_data": { "chw_id": "13/43/DFA" } }