Register
POST
/v1/auth/registerThis endpoint allows new users to create an account by providing necessary details, such as email and password and other specified data. Upon successful registration, the endpoint generates authentication tokens (e.g., access and refresh tokens) and returns user information to confirm account creation.
Request
The user's email address, which serves as their primary identifier and contact method.
A representing the user's password, required for authentication when using the "email" sign-in method.
{
"email": "user@test.com",
"password": "{{default_password}}"
}
Request samples
Responses
A numerical code representing the status of the response, typically following HTTP status conventions
A brief message describing the outcome of the request, providing additional context.
The main content of the response, which can vary depending on the endpoint. It may include:
- An object with specific properties (e.g., for single resource responses),
- An array of objects (e.g., for listing multiple resources),
- Or a string (e.g., for simple messages or confirmations).
{
"status": 201,
"message": "User created successfully",
"data": {
"user": {
"email": "Martina27@hotmail.com",
"signInMethod": "email",
"_id": "671f3afadc8c26d0095c3b9c",
"createdAt": "2024-10-28T07:19:22.436Z",
"updatedAt": "2024-10-28T07:19:22.436Z",
"__v": 0
},
"tokens": {
"accessToken": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjY3MWYzYWZhZGM4YzI2ZDAwOTVjM2I5YyIsImVtYWlsIjoiTWFydGluYTI3QGhvdG1haWwuY29tIiwiaWF0IjoxNzMwMDk5OTYyLCJleHAiOjE3MzAxODYzNjJ9.anreGdYPiN6UoygJBxtgBqqfFaVgE0zGHPI-qOI6ULkWlm8iz68HxpOeAGPzJ1l4RZiuRm9GbhROWOFSOie25X2k6zhTOXIs1SRu4s4twfLBai8njcrQv-Ni5_vJSzelCqoY154BdcHMqkExHbDIXR_np0myRSLHVA3QWJFnIGFtxcvFWAqkHM0gLOLMtsblNfsg4ZrGYeq7X3biHc6nnSrfVb4uUhA5O2BfdhukpmCdks5oI_dbUDvf3T684XMN-9ciOGJPzAFIyStqqmeg_nPcQM9CdiFJAwemVya-8lfU0w6osO9sV6pLljwYU2qLbToi-L_B6xHoZ03ejbkx4g",
"refreshToken": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjY3MWYzYWZhZGM4YzI2ZDAwOTVjM2I5YyIsImVtYWlsIjoiTWFydGluYTI3QGhvdG1haWwuY29tIiwiaWF0IjoxNzMwMDk5OTYyLCJleHAiOjE3MzA3MDQ3NjJ9.NG1-Udlv62zbwDksmTk4UICqHGIf8faJV8kXegUIpffNN4L54PGKCSjD76OFLVEyNOT35CgGTm639ENjII6yCrxgyeF3dMtn9bv5keXrqi9QRabY3wHogbHOQ5bcpeqwjTVnFYUXBdRfH-8zfeifb7ACd39Gke6kC2VZ0WIcjsgB7WsxH_2O21aR02C86mP0n-78j9Wq_HlgcPIjZ_xweYJv83rbxrfY5YKEY7AlE_afIB-hIKcTZXauSHadv2NLPt1_9-pi7LIJd5iO39hu-OoIMYf-r9vuYZbT28-I79xWbl-UALY_7dz85adGfDW7u2EGlBBr650rdT52-Bkx9A"
}
}
}