Timekit developers

/users

Create user

Create a new user..

The api_token in the response is your user credentials that you must save and use for future API requests. See authentication for more info.

Do also note that this endpoint simply creates a plain Timekit user. If you want to create a user based on a Google account, please see [GET] /accounts/google/signup

Endpoint

POST https://api.timekit.io/v2/users

Parameters

Name In Type Required Default Description
email body string yes Email of the user
timezone body string yes Timezone of the user
first_name body string yes First name of the user
last_name body string Last name of the user
password body string Password of the user (if not set, a random password will be assigned - can be reset subsequently)

Request examples

curl
curl -X POST \
		 -H 'Timekit-App: back-to-the-future' \
     -d '{
           "email": "doc.brown:::at:::timekit.io",
           "timezone": "America/Los_Angeles",
           "first_name": "Emmet",
           "last_name": "Brown",
    			 "password": "FluxCapacitator"
       }' \
  https://api.timekit.io/v2/users 
json
{
    "email": "doc.brown@timekit.io",
    "timezone": "America/Los_Angeles",
    "first_name": "Emmet",
    "last_name": "Brown",
    "password": "FluxCapacitator"
}

Response examples

201

json
{
  "data": {
    "id": "d187d6e0-d6cb-409a-ae60-45a8fd0ec879",
    "first_name": "Emmet",
    "last_name": "Brown",
    "name": "Emmet Brown",
    "email": "doc.brown@timekit.io",
    "image": "http://www.link-to-img.com/image.png",
    "activated": false,
    "timezone": "America/Los_Angeles",
    "last_sync": null,
    "api_token": "nvHfRSlhvsnlg4rS7Wt28Ty47qdgegwSu3YK7hPW"
  }
}

422

json
{
  "errors": {
    "first_name": [
    	"The first name field is required."
    ],
    "email": [
    	"The email field is required."
    ],
    "timezone": [
    	"The timezone field is required."
    ]
  }
}