Skip to content

Vendor change password Serializer

ChangePasswordSerializer

Description

Handles user password updates securely.

Fields

Field Description Required Write-only
old_password Current password for verification. Yes Yes
new_password New password to be set. Yes Yes
confirm_password Confirmation of new password. Yes Yes

Validation

  • Ensures old_password matches the user's current password.
  • Prevents setting new_password as the same as old_password.
  • Ensures new_password and confirm_password match.

Update Process

  • If validation passes, the user's password is updated securely.