Forgot Password
Send a password reset email to the user's email address.
Interface Information
- Endpoint:
POST /api/auth/forget-password - Authentication: Not required
- Content-Type:
application/json
Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| string | Yes | User email address |
Request Example
bash
curl -X POST http://localhost:3000/api/auth/forget-password \
-H "Content-Type: application/json" \
-d '{
"email": "user@example.com"
}'Response Example
json
{
"success": true,
"message": "Password reset email has been sent"
}Error Responses
| HTTP Status Code | Description |
|---|---|
| 400 | Invalid email address |
| 404 | Email not registered |
| 500 | Server error |