Skip to content

Account Users

How to administer your accounts users

Let’s start by creating a new user:

POST /users

Loading...

Output:

User Creation Fields

When creating a user, you can specify the following fields:

FieldTypeRequiredDescription
emailstringYesThe user’s email address (must be valid)
namestringNoThe user’s full name
teamIdnumberNoID of the team the user belongs to
phonestringNoThe user’s phone number
imgSrcstringNoURL to the user’s profile image
notificationPreferencesobjectNoUser’s notification preferences
rolesarrayNoArray of role names to assign to the user

Assigning Roles During User Creation

You can now assign roles to a user directly during creation by including a roles array in the request body. This simplifies user setup by eliminating the need for a separate role assignment request.

The roles array should contain the names of the roles you want to assign to the user. These roles must already exist in your account.

{
"email": "newuser@test.com",
"name": "John Doe",
"roles": ["user", "agent"]
}

Listing all users

GET /users

Loading...

Output:

Impersonating Users

POST /users/{email}/impersonate

Loading...

Output:

Setting Passwords

You can set passwords for your users manually if necessary, although its recommended to send them a password reset… or users can request a password reset themselves.

POST /auth/admin-force-set-password

Loading...

Output:

Delete a User

DELETE /users/{email}

Loading...

Output:

References

For more info see the API Reference section on these items:

POST /users

GET /users

POST /users/{email}/impersonate

POST /auth/admin-force-set-password

DELETE /users/{email}