This page covers two closely related flows: account verification (required after registration before first login) and password recovery (for users who have forgotten their password). Both flows rely on a 5-digit numeric code delivered to the user’s registered email address.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/fredy-rizo/Ecommerce/llms.txt
Use this file to discover all available pages before exploring further.
All verification and recovery codes are 5-digit strings where each digit is a value from 1 to 5 (generated server-side with
Math.ceil(Math.random() * 5), so 0 never appears). Codes are single-use and should be submitted promptly.Verify Account
POST /api/user/verify-account
After registering, every account starts with an Inactivo (inactive) status. This endpoint activates the account by validating the 5-digit code that was emailed at registration. No authentication token is required.
Method: POSTPath:
/api/user/verify-accountAuth required: No
Request Body
The email address used to register the account.
The 5-digit verification code that was sent to the email address at the time of registration.
Response — 200 OK
On success, the account’slogin_code_confirmed field is set to the verified code and the activation status is updated to { name: "Activado", value: "1" }. The user may now log in.
A human-readable confirmation message.
Always
true on success.Example Request
Example Response
Error Responses
| Status Code | Meaning |
|---|---|
203 | The provided code does not match the one on file for this account. |
500 | An unexpected server error occurred. |
Password Recovery Flow
Recovering a forgotten password is a two-step process: first request a recovery code, then submit that code along with the new password.Request a recovery code — POST /api/user/recovery-password
Call this endpoint with the account’s email address. The server generates a 5-digit
Path:
Auth required: No
code_newpass and sends it to that address. No authentication token is required.Method: POSTPath:
/api/user/recovery-passwordAuth required: No
Request Body
The email address associated with the account that needs password recovery.
Response — 200 OK
Returns a success message confirming that the recovery email was sent.Example Request
Error Responses
| Status Code | Meaning |
|---|---|
203 | No account was found for the provided email address. |
Set a new password — POST /api/user/update-password
Once you have the recovery code from your email, submit it together with the desired new password. The server verifies the code against
Path:
Auth required: No
code_newpass, hashes the new password with bcrypt, and clears both code_newpass and code_confirm_pass on the account. No authentication token is required.Method: POSTPath:
/api/user/update-passwordAuth required: No
Request Body
The email address of the account being recovered.
The 5-digit recovery code that was emailed in Step 1.
The new password to set for the account. Will be stored as a bcrypt hash.
Response — 200 OK
Returns a success message confirming the password has been updated. The user can now log in with the new password.Example Request
Error Responses
| Status Code | Meaning |
|---|---|
203 | The recovery code is incorrect or does not match the account. |
404 | No account was found for the provided email address. |