Register new user
curl --request POST \
--url https://app.thareja.ai/api/v3/user/register \
--header 'Content-Type: application/json' \
--data '
{
"name": "John Doe",
"email": "john.doe@example.com",
"password": "SecurePassword123!",
"c_password": "SecurePassword123!",
"team": {
"name": "Acme Corporation",
"description": "Leading software development company"
},
"timezone": "America/New_York",
"phone": "+1-555-123-4567"
}
'import requests
url = "https://app.thareja.ai/api/v3/user/register"
payload = {
"name": "John Doe",
"email": "john.doe@example.com",
"password": "SecurePassword123!",
"c_password": "SecurePassword123!",
"team": {
"name": "Acme Corporation",
"description": "Leading software development company"
},
"timezone": "America/New_York",
"phone": "+1-555-123-4567"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'John Doe',
email: 'john.doe@example.com',
password: 'SecurePassword123!',
c_password: 'SecurePassword123!',
team: {name: 'Acme Corporation', description: 'Leading software development company'},
timezone: 'America/New_York',
phone: '+1-555-123-4567'
})
};
fetch('https://app.thareja.ai/api/v3/user/register', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.thareja.ai/api/v3/user/register",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'John Doe',
'email' => 'john.doe@example.com',
'password' => 'SecurePassword123!',
'c_password' => 'SecurePassword123!',
'team' => [
'name' => 'Acme Corporation',
'description' => 'Leading software development company'
],
'timezone' => 'America/New_York',
'phone' => '+1-555-123-4567'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.thareja.ai/api/v3/user/register"
payload := strings.NewReader("{\n \"name\": \"John Doe\",\n \"email\": \"john.doe@example.com\",\n \"password\": \"SecurePassword123!\",\n \"c_password\": \"SecurePassword123!\",\n \"team\": {\n \"name\": \"Acme Corporation\",\n \"description\": \"Leading software development company\"\n },\n \"timezone\": \"America/New_York\",\n \"phone\": \"+1-555-123-4567\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.thareja.ai/api/v3/user/register")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"John Doe\",\n \"email\": \"john.doe@example.com\",\n \"password\": \"SecurePassword123!\",\n \"c_password\": \"SecurePassword123!\",\n \"team\": {\n \"name\": \"Acme Corporation\",\n \"description\": \"Leading software development company\"\n },\n \"timezone\": \"America/New_York\",\n \"phone\": \"+1-555-123-4567\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.thareja.ai/api/v3/user/register")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"John Doe\",\n \"email\": \"john.doe@example.com\",\n \"password\": \"SecurePassword123!\",\n \"c_password\": \"SecurePassword123!\",\n \"team\": {\n \"name\": \"Acme Corporation\",\n \"description\": \"Leading software development company\"\n },\n \"timezone\": \"America/New_York\",\n \"phone\": \"+1-555-123-4567\"\n}"
response = http.request(request)
puts response.read_body{
"id": 1,
"name": "John Doe",
"email": "john.doe@example.com",
"profile_photo_url": "https://s3.amazonaws.com/bucket/profiles/user-1.jpg",
"current_team_id": 5,
"token": "1|Ab3dEfGh1Jk2Lm3No4Pq5Rs6Tt7Uv8Wx9Yz0",
"role": "owner",
"isAdmin": "yes",
"contact_count": 15,
"is_first_project_added": 1,
"is_first_task_added": 1,
"is_first_member_invited": 1,
"timezone": "America/New_York",
"two_factor_confirmed_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": {
"email": [
"The email has already been taken."
]
}
}Authentication
Register User
Create a new user account with automatic organization setup and email verification
POST
/
api
/
v3
/
user
/
register
Register new user
curl --request POST \
--url https://app.thareja.ai/api/v3/user/register \
--header 'Content-Type: application/json' \
--data '
{
"name": "John Doe",
"email": "john.doe@example.com",
"password": "SecurePassword123!",
"c_password": "SecurePassword123!",
"team": {
"name": "Acme Corporation",
"description": "Leading software development company"
},
"timezone": "America/New_York",
"phone": "+1-555-123-4567"
}
'import requests
url = "https://app.thareja.ai/api/v3/user/register"
payload = {
"name": "John Doe",
"email": "john.doe@example.com",
"password": "SecurePassword123!",
"c_password": "SecurePassword123!",
"team": {
"name": "Acme Corporation",
"description": "Leading software development company"
},
"timezone": "America/New_York",
"phone": "+1-555-123-4567"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'John Doe',
email: 'john.doe@example.com',
password: 'SecurePassword123!',
c_password: 'SecurePassword123!',
team: {name: 'Acme Corporation', description: 'Leading software development company'},
timezone: 'America/New_York',
phone: '+1-555-123-4567'
})
};
fetch('https://app.thareja.ai/api/v3/user/register', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.thareja.ai/api/v3/user/register",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'John Doe',
'email' => 'john.doe@example.com',
'password' => 'SecurePassword123!',
'c_password' => 'SecurePassword123!',
'team' => [
'name' => 'Acme Corporation',
'description' => 'Leading software development company'
],
'timezone' => 'America/New_York',
'phone' => '+1-555-123-4567'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.thareja.ai/api/v3/user/register"
payload := strings.NewReader("{\n \"name\": \"John Doe\",\n \"email\": \"john.doe@example.com\",\n \"password\": \"SecurePassword123!\",\n \"c_password\": \"SecurePassword123!\",\n \"team\": {\n \"name\": \"Acme Corporation\",\n \"description\": \"Leading software development company\"\n },\n \"timezone\": \"America/New_York\",\n \"phone\": \"+1-555-123-4567\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.thareja.ai/api/v3/user/register")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"John Doe\",\n \"email\": \"john.doe@example.com\",\n \"password\": \"SecurePassword123!\",\n \"c_password\": \"SecurePassword123!\",\n \"team\": {\n \"name\": \"Acme Corporation\",\n \"description\": \"Leading software development company\"\n },\n \"timezone\": \"America/New_York\",\n \"phone\": \"+1-555-123-4567\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.thareja.ai/api/v3/user/register")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"John Doe\",\n \"email\": \"john.doe@example.com\",\n \"password\": \"SecurePassword123!\",\n \"c_password\": \"SecurePassword123!\",\n \"team\": {\n \"name\": \"Acme Corporation\",\n \"description\": \"Leading software development company\"\n },\n \"timezone\": \"America/New_York\",\n \"phone\": \"+1-555-123-4567\"\n}"
response = http.request(request)
puts response.read_body{
"id": 1,
"name": "John Doe",
"email": "john.doe@example.com",
"profile_photo_url": "https://s3.amazonaws.com/bucket/profiles/user-1.jpg",
"current_team_id": 5,
"token": "1|Ab3dEfGh1Jk2Lm3No4Pq5Rs6Tt7Uv8Wx9Yz0",
"role": "owner",
"isAdmin": "yes",
"contact_count": 15,
"is_first_project_added": 1,
"is_first_task_added": 1,
"is_first_member_invited": 1,
"timezone": "America/New_York",
"two_factor_confirmed_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": {
"email": [
"The email has already been taken."
]
}
}Overview
Create a new user account and automatically set up their organization. After registration, a verification email is sent, and the user is automatically logged in with an authentication token.Request Body
string
required
User’s full name. Also used to generate a default organization name.Example:
"John Doe"string
required
User’s email address. Must be unique in the system.Format: Valid email addressExample:
"john.doe@example.com"string
required
User’s password. Should be strong and secure.Example:
"SecurePassword123!"string
required
Password confirmation. Must match the password field.Example:
"SecurePassword123!"object
string
User’s timezone.Example:
"America/New_York"string
User’s phone number.Example:
"+1-555-123-4567"Response
The response is identical to the login endpoint, containing user details and authentication token.integer
User’s unique identifier.
string
User’s full name.
string
User’s email address.
string
Automatically generated unique username.
string
URL to user’s profile picture (default avatar).
integer
ID of the newly created organization/team.
string
Authentication token for API requests. Use this in the
Authorization: Bearer {token} header.string
User’s role (always
"owner" for new registrations).string
Admin status (always
"yes" for new registrations).integer
Number of contacts (0 for new users).
integer
Onboarding flag: Whether the first project has been added (0 for new users).
integer
Onboarding flag: Whether the first task has been added (0 for new users).
integer
Onboarding flag: Whether the first team member has been invited (0 for new users).
string
App identifier (set to “tracker”).
integer
Maximum speed limit setting (80).
string
Email verification timestamp (null until verified).
string
Timestamp when the user account was created.
string
Timestamp when the user account was last updated.
Example Request - Basic Registration
Body
application/json
User's full name
Example:
"John Doe"
User's email address (must be unique)
Example:
"john.doe@example.com"
User's password
Example:
"SecurePassword123!"
Password confirmation (must match password)
Example:
"SecurePassword123!"
Optional custom organization details
Show child attributes
Show child attributes
User's timezone
Example:
"America/New_York"
User's phone number
Example:
"+1-555-123-4567"
Response
Registration successful
Example:
1
Example:
"John Doe"
Example:
"john.doe@example.com"
Example:
"https://s3.amazonaws.com/bucket/profiles/user-1.jpg"
Example:
5
Bearer token for API authentication
Example:
"1|Ab3dEfGh1Jk2Lm3No4Pq5Rs6Tt7Uv8Wx9Yz0"
Available options:
owner, manager, member, client Example:
"owner"
Available options:
yes, no Example:
"yes"
Example:
15
0 = not added, 1 = added
Available options:
0, 1 Example:
1
0 = not added, 1 = added
Available options:
0, 1 Example:
1
0 = not invited, 1 = invited
Available options:
0, 1 Example:
1
Example:
"America/New_York"