Creating/Updating an User

Create a new or update an existing User. These endpoints allow you to manage user accounts by creating new users or modifying existing ones. When creating a user, you'll need to provide their first name, last name, email address, and user type (Admin, Normal, or Restricted). For existing users, you can update their information using either PUT or POST requests with their User ID. Upon user creation, an automated email will be sent to the user with their password.

Creating an User
POST /api/v1/users/

Updating an User
PUT /api/v1/users/[USER ID]/ or POST /api/v1/users/[USER ID]/

Required fields:

first_nameString for first name.
last_nameString for last name.
emailString for email address (an email will be sent to the user with their password).
user_typeThe user type (Admin/Normal/Restricted). Possible values "A","N", and "R" correspondingly.

Creating a user example

curl 'https://acmeinc.datareportive.com/api/v1/users/' \
            -X POST \
            -H 'Authorization: Token [ TOKEN ]' \
            -H 'Content-Type: application/json' \
            -d '{"first_name":"John", "last_name":"Smith", "email":"john@smith.com", "user_type":"A"}'