Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/eggarcia98/auth-backend/llms.txt

Use this file to discover all available pages before exploring further.

Set a new password for the authenticated user. You must pass the reset token from the password reset email as a Bearer token in the Authorization header.

Request

POST /api/v1/auth/reset-password Requires the reset token from the password reset email as a Bearer token.

Headers

Authorization
string
required
Bearer token from the password reset email link. Format: Bearer <resetToken>. The middleware uses this to authenticate the request.

Body

token
string
required
The reset token from the password reset email link. This is validated by the request body schema in addition to the Authorization header.
password
string
required
The new password for the account. Must meet all of the following requirements:
  • At least 8 characters
  • At least one uppercase letter (A–Z)
  • At least one lowercase letter (a–z)
  • At least one number (0–9)

Response

success
boolean
required
Indicates whether the request succeeded. Always true on success.
data
object

Examples

curl --request POST \
  --url https://your-api.com/api/v1/auth/reset-password \
  --header 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...' \
  --header 'Content-Type: application/json' \
  --data '{
    "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...",
    "password": "NewSecureP4ss"
  }'

Success response

200
{
  "success": true,
  "data": {
    "message": "Password reset successfully"
  }
}

Error responses

400
{
  "success": false,
  "error": {
    "code": "VALIDATION_ERROR",
    "message": "Password must be at least 8 characters"
  }
}
401
{
  "success": false,
  "error": {
    "code": "UNAUTHORIZED",
    "message": "Invalid or expired token"
  }
}

Build docs developers (and LLMs) love