curl -X POST "https://api.hitler.app/api/auth/register" \
-H "Content-Type: application/json" \
-d '{
"email": "newuser@company.com",
"password": "securepassword123",
"name": "Jane Smith",
"organizationId": "456e7890-e12b-34d5-a678-426614174000"
}'
const response = await api.register({
email: "newuser@company.com",
password: "securepassword123",
name: "Jane Smith",
organizationId: "456e7890-e12b-34d5-a678-426614174000",
});
{
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"expiresIn": 604800,
"user": {
"id": "789e0123-e45b-67d8-a901-426614174000",
"email": "newuser@company.com",
"name": "Jane Smith",
"role": "employee",
"organizationId": "456e7890-e12b-34d5-a678-426614174000"
}
}
{
"statusCode": 409,
"message": "Email already registered",
"error": "Conflict"
}
Auth
Register
Create a new user account
POST
/
api
/
auth
/
register
curl -X POST "https://api.hitler.app/api/auth/register" \
-H "Content-Type: application/json" \
-d '{
"email": "newuser@company.com",
"password": "securepassword123",
"name": "Jane Smith",
"organizationId": "456e7890-e12b-34d5-a678-426614174000"
}'
const response = await api.register({
email: "newuser@company.com",
password: "securepassword123",
name: "Jane Smith",
organizationId: "456e7890-e12b-34d5-a678-426614174000",
});
{
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"expiresIn": 604800,
"user": {
"id": "789e0123-e45b-67d8-a901-426614174000",
"email": "newuser@company.com",
"name": "Jane Smith",
"role": "employee",
"organizationId": "456e7890-e12b-34d5-a678-426614174000"
}
}
{
"statusCode": 409,
"message": "Email already registered",
"error": "Conflict"
}
Request
string
required
User’s email address
string
required
User’s password (minimum 8 characters)
string
required
User’s display name (max 255 characters)
string
required
UUID of the organization the user belongs to
Response
string
JWT token for authenticating subsequent requests
number
Token expiration time in seconds
object
Created user information
curl -X POST "https://api.hitler.app/api/auth/register" \
-H "Content-Type: application/json" \
-d '{
"email": "newuser@company.com",
"password": "securepassword123",
"name": "Jane Smith",
"organizationId": "456e7890-e12b-34d5-a678-426614174000"
}'
const response = await api.register({
email: "newuser@company.com",
password: "securepassword123",
name: "Jane Smith",
organizationId: "456e7890-e12b-34d5-a678-426614174000",
});
{
"accessToken": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
"expiresIn": 604800,
"user": {
"id": "789e0123-e45b-67d8-a901-426614174000",
"email": "newuser@company.com",
"name": "Jane Smith",
"role": "employee",
"organizationId": "456e7890-e12b-34d5-a678-426614174000"
}
}
{
"statusCode": 409,
"message": "Email already registered",
"error": "Conflict"
}
⌘I