Server Side API

Create New User

Available For: Enterprise Plans

Allows you to create a new user.

Only call the API from your secure backend server environment.
Never call this from a client such as Web or Mobile.
URL
https://www.justsignin.com/api/v1/server/createUser
Protocol
HTTPS
Method
POST
Header
Content-Type: application/json; charset=utf-8

Request Body

The request body is a JSON object sent as the body of the HTTPS POST. The request body should include the following pramaters.

appId
String
Required
The ID of your Just Sign In website configured in the dashboard.
appSecret
String
Required
One of the App Secrets you created for the website referenced by the appId.
email
String
Required
The new user's email addres.
firstName
String
Required
The new user's first name. Maximum length of 25 characters.
lastName
String
Required
The new user's last name. Maximum length of 25 characters.
password
String
Required

The new user's password. The password must conform to the password complexity setting in your User Pool.

The complexity of a password is simply calculated by how many password standard practices it complies with.

  • Very Strong complies with 5 standard practices
  • Strong complies with 4 standard practices
  • Average complies with 3 standard practices
  • Weak complies with 2 standard practices
  • Very Weak complies with 1 standard practice

Password standard practices...

  • Contains at least 8 characters
  • Contains an Upper Case letter
  • Contains a Lower Case letter
  • Contains a Number
  • Contains a Special Character !@#$%^&*
Example JSON POST Body (with pretend example values)
{
  "appId": "131889432817531002",
  "appSecret": "FCGAYPQP73U47ASKOWRPIOP7DPIY",
  "email": "johnnylingo@gqmail.com",
  "firstName": "Johnny",
  "lastName": "Lingo",
  "password": "I've heard phrases make the best passwords.  Have you?"
}

Responses

200 - Success

A successful call will return an HTTP 200 status code.

HTTP 200 JSON Response
{
  "user": {
    "id": "111770523408422991",
    "email": "johnnylingo@gqmail.com",
    "firstName": "Johnny",
    "lastName": "Lingo",
    "fullName": "Johnny Lingo",
  },
}

400 - User Already Exists

A user with this email address already exists within the User Pool.

HTTP 400 JSON Response
{ 
  "error": "USER_ALREADY_EXISTS", 
  "message": "User with email already exists" 
}

400 - Password Too Weak

The password did not meet the complexity setting of the User Pool.

HTTP 400 JSON Response
{
  "error": "PASSWORD_TOO_WEAK",
  "message": "Password is too weak.",
}