> ## Documentation Index
> Fetch the complete documentation index at: https://developers.thareja.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Forgot Password

> Request a password reset link to be sent via email. Generates a token and invalidates all active sessions.

## Overview

Request a password reset link to be sent via email. This endpoint generates a password reset token and sends it to the user's registered email address. The user can then use this token to reset their password.

## Request Body

<ParamField body="email" type="string" required>
  The email address of the user who forgot their password.

  **Format:** Valid email address

  **Example:** `"user@example.com"`
</ParamField>

## Response

<ResponseField name="success" type="boolean">
  Whether the request was successful.
</ResponseField>

<ResponseField name="msg" type="string">
  Success message confirming the reset link was sent.
</ResponseField>

## Example Request

```bash theme={null}
```


## OpenAPI

````yaml POST /api/v3/user/resetpassword
openapi: 3.1.0
info:
  title: Thareja API Documentation
  description: A comprehensive API for team and task management
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://app.thareja.ai
security:
  - bearerAuth: []
tags:
  - name: Teams
    description: Team management endpoints
  - name: Tasks
    description: Task management endpoints
  - name: Projects
    description: Project management endpoints
  - name: Comments
    description: Comment management endpoints
paths:
  /api/v3/user/resetpassword:
    post:
      tags:
        - Authentication
      summary: Forgot password - Request reset link
      description: >-
        Request a password reset link to be sent via email. Generates a token
        and invalidates all active sessions.
      operationId: forgotPassword
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ForgotPasswordRequest'
        required: true
      responses:
        '200':
          description: Reset link sent successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    example: true
                  msg:
                    type: string
                    example: Reset password link is sent successfully!
        '400':
          description: Bad request - Missing or invalid email
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: User not found - Invalid email
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Invalid Email!
        '500':
          description: Server error - Failed to send email
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Failed to send email
      security: []
components:
  schemas:
    ForgotPasswordRequest:
      required:
        - email
      type: object
      properties:
        email:
          description: The email address of the user who forgot their password
          type: string
          format: email
          example: user@example.com
    Error:
      required:
        - error
        - message
      type: object
      properties:
        error:
          type: integer
          format: int32
          example: 400
        message:
          type: string
          example: Invalid request parameters
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````