POST /auth/forgot-password
Forgot password
Forgot password
/auth/forgot-passwordRequest body
NestAuthForgotPasswordRequestDto
| Field | Type | Required | Description |
|---|---|---|---|
email | string | optional | User email address (required if phone not provided) Example: user@example.com |
phone | string | optional | User phone number (required if email not provided) Example: +1234567890 |
tenantId | string | optional | Tenant ID for multi-tenant applications Example: 123e4567-e89b-12d3-a456-426614174000 |
Examples
Example
{
"email": "user@example.com",
"phone": "+1234567890",
"tenantId": "123e4567-e89b-12d3-a456-426614174000"
}Responses
200
NestAuthPasswordResetLinkSentResponseDto
| Field | Type | Required | Description |
|---|---|---|---|
message | string | required | Response message Example: If your email is registered, you will receive a password reset link |
Example response
{
"message": "If your email is registered, you will receive a password reset link"
}Try it
curl -X POST 'https://api.example.com/auth/forgot-password' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer YOUR_ACCESS_TOKEN' \
-d '{"email":"user@example.com","phone":"+1234567890","tenantId":"123e4567-e89b-12d3-a456-426614174000"}'