Skip to main content
POST
Register
Register a new user account and receive an access token for immediate authentication.

Endpoint

Request Body

string
required
The user’s full name. Must be between 1 and 100 characters.Example: "John Doe"
string
required
The user’s email address. Must be a valid email format and unique. Maximum 255 characters.Example: "john.doe@example.com"
string
required
The user’s password. Must meet the following requirements:
  • At least 8 characters long
  • Contains at least one uppercase letter
  • Contains at least one lowercase letter
  • Contains at least one number
Example: "SecurePass123"

Response

string
JWT access token for authentication. Include this in the Authorization header for subsequent requests.Example: "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJqb2huLmRvZUBleGFtcGxlLmNvbSIsImV4cCI6MTcwOTU1MTIwMH0.abc123"
string
The type of token. Always returns "bearer".
object
The created user object.

Example Request

cURL
JavaScript
Python

Example Response

201 Created

Error Responses

400 Bad Request - Email Already Registered
422 Unprocessable Entity - Invalid Password
422 Unprocessable Entity - Password Missing Uppercase
422 Unprocessable Entity - Password Missing Number
422 Unprocessable Entity - Invalid Email
500 Internal Server Error

Password Requirements

Passwords must meet all of the following requirements:
  • Minimum 8 characters
  • At least one uppercase letter (A-Z)
  • At least one lowercase letter (a-z)
  • At least one number (0-9)

Notes

  • Email addresses are automatically converted to lowercase and trimmed
  • Each email can only be registered once
  • Upon successful registration, the user is automatically logged in (access token is returned)
  • The password is securely hashed using bcrypt before storage
  • Store the returned access token securely for subsequent API requests