Create a user
POST /v1/b2b/customer/users (Requires Admin Permissions)
Pass the email address and password in the headers as x-acme-email and x-acme-password. An email will be sent to the email address specified with a link for them to click to confirm the account.
Invite a user
POST /v1/b2b/customer/users/invite (Requires Admin Permissions)
email list is passed into a request header 'email_invites'
Get list of users by role
Query Parameters: All are optional
- pageSize: Number of entries to return
- page: Which page you are getting
- departmentId: Filter, only return users for this department
- roleId: Filter, only return users with this role
- jobTitle: Filter only return users with this title in their title.
- activeOnly: if true then will not return deactivated users.
Get a user
userId: the id of the user you are looking for.
The User Object corresponding to the user you requested.
Update a user
If you pass a password in then you must also pass in an old password to change the password.
A User Object
userId: the id of the user you are updating.
The resulting User object
Recover Password flow, call this function with an email address in the headers and an email will be sent to that address with a link that contains a token to recover the password. Pass the email address in as header x-acme-email in the request headers.
x-acme-email: (Header) the email address to recover the password for.
Finish Recovering a password
Second part of the recover password flow, after the user has typed in a new password send it to this url in the headers with the token used to recover the password. This will change the user's password to the new password and return a session that they can use. Pass token in the header as x-acme-token and the new password in the header as x-acme-password.
x-acme-token: (Header) the token that was emailed to the user.
x-acme-password: (Header) the new password.
A User Session Object
Confirm a user
Token must be passed in as x-acme-token
x-acme-token: (Header) the token that was emailed to the user to confirm their account.
A User Session Object
Resend the confirmation email to the specified user.
confirmationToken will be different than previously sent tokens.
If the user has been deactivated then this will throw an exception saying the "User is deactivated and can not be invited"
if the user has already on boarded we will throw an exception saying "User is already on boarded, please recover password if forgotten."
userId: The id of the user to resend the confirmation for.
Batch Update Departments
The body will be a list of userIds that you want assigned to that department.
A list of user ids to assign to the department
departmentId: The id of the department to assign the users to.
Batch Update Roles
The body will be a list of userIds that you want this role assigned to.
A list of user id's to assign the role to.
roleId: The id of the role you are adding to the users.
Get Existing Titles
a list of the existing titles.
Get Existing Roles
a list of the existing roles Role Objects
Admin set password
the body is simply the new password for the specified user. Changes the password for the user to that specified.
|id||The unique id of the user.|
|tenantId||The id of the tenant that the user belongs to.|
|Email address for the user.|
|firstName||First name of the user.|
|lastName||Last name, family name, of the user.|
|phoneNumber||User's phone number.|
|title||Job title for the user.|
|streetAddress1||First line in the address for the user.|
|streetAddress2||Second line in the address for the user.|
|city||The city that the user lives in.|
|state||The state that the user lives in.|
|zipCode||The user's zip code.|
|country||The country that the user lives in.|
|confirmed||True if the user has confirmed their email address.|
|onBoarded||True if the user has been on boarded.|
|department||The name of the department that the user is in.||Read Only|
|departmentId||The id of the department that the user is in.|
|userName||User name for the user.|
|active||true if the user is active, false if they've been deactivated|
|password||required for create and for changing password. If you pass this in an update user call then you must also provide an oldPassword.||Write Only|
|oldPassword||Leave empty unless you are changing the password.||Write Only|
|id||The unique id of the role.|
|name||The name of the role.|
|permissions||A list of permissions for the role.|