Change person password

POST /actions/persons/{person_id}/change-password

Allow admin to change password for given user. An admin can't change other admins password. The new password requires a confirmation to ensure that the admin didn't make a mistake by typing the new password.

Path parameters

  • person_id string(uuid) Required

    Person unique identifier

application/json

Body Required

  • password string(password) Required

    New password

  • password_2 string(password) Required

    Password confirmation

Responses

  • 200 application/json

    Password changed successfully

    Hide response attribute Show response attribute object
    • success boolean

      Success flag

  • 400 application/json

    Invalid password or inactive user

    Hide response attributes Show response attributes object
    • error boolean

      Error flag

    • message string

      Error message

POST /actions/persons/{person_id}/change-password
curl \
 --request POST 'http://api.example.com/actions/persons/a24a6ea4-ce75-4665-a070-57453082c25/change-password' \
 --header "Authorization: $API_KEY" \
 --header "Content-Type: application/json" \
 --data '{"password":"newSecurePassword123","password_2":"newSecurePassword123"}'
Request examples
{
  "password": "newSecurePassword123",
  "password_2": "newSecurePassword123"
}
Response examples (200)
{
  "success": true
}
Response examples (400)
{
  "error": true,
  "message": "Password is too short."
}