Create a User

Create a new User

Request

Endpoint: /api/users
Method: POST
Headers: Accept: application/vnd.cloudlx.v1+json
Authorization: Bearer <access_token>

JSON Request

                                
    {
        "customer_id": 41,
        "email": "j.smith@example.com",
        "first_name": "John",
        "last_name": "Smith",
        "phone": "+442071234567",
        "time_zone": "Europe/London"
    }
                                
                            

JSON Parameters

customer_id Description The id of the user's customer
Type Integer
Example 915
email Description The user's email
Type String
Example j.smith@example.com
first_name Description The user name
Type String
Example John
last_name Description The user's last name
Type String
Example Smith
phone Description The user's phone number
Type String
Example +442071234567
time_zone Description The user's default time_zone
Type String (any valid timezone available in the IANA timezone database).
Example Europe/London

Response

The user model is returned with a 200 HTTP response code.

Example:

                                
    {
        "id": 915,
        "email": "j.smith@example.com",
        "first_name": "John",
        "last_name": "Smith",
        "phone": "+442071234567",
        "time_zone": "Europe/London"
    }
                                
                            

Back to top