Create user - Research Service Workbench on AWS

Create user

Creates a user in the Cognito User Pool. Only users who are IT Admins can access this API. The route to invoke is POST /users.

Request parameters

There are no request parameters for this API.

Request body

The following body elements are for this specific action:

First Name

The first name of the user to add.

Type: String

Length Constraints: Minimum length of 1.

Required: Yes

Last Name

The last name of the user to add.

Type: String

Length Constraints: Minimum length of 1.

Required: Yes

Email

The email of the user to add. This will be used as their username to login. This must be unique for each user added.

Type: String

Length Constraints: Minimum length of 1.

Required: Yes

Response elements

The following elements are returned by the API. A 201 HTTP Status Code indicates success.

ID

The UUID of the newly created user.

Type: String

First Name

The first name of the newly created user.

Type: String

Last Name

The last name of the newly created user.

Type: String

Email

The email of the newly created user. This will be used as their username to login. This is unique to this user.

Type: String

Status

1 if the user is active and 0 if the user is inactive.

Type: Number

Valid Values: 0 | 1

Roles

List of the current roles the newly created user is assigned to. On creation, this value will be empty. You can add a user to roles by using the Update User API or Add User to Project API.

Type: Array of strings