PUT - Reset User Password

Purpose

The API is used to reset the password of a user in the organization.

OAuth Scope

Use the scope

ZohoMail.organization.accounts.ALL (or) ZohoMail.organization.accounts.UPDATE 

to generate the Authtoken.

ALL - Grants full access to accounts.

UPDATE - Grants update access to accounts.

Request URL 

Method: PUT

https://mail.zoho.com/api/organization/{zoid}/accounts/{zuid}

Path Parameters

  • zoid* long
    • This parameter denotes the unique Zoho Organization Identifier for the organization.
    • This value can be retrieved using the Get organization details API.

Request Body (JSON Object)

  • password* string
    • Provide the new password of the user which should be updated.
  • resetAuthToken boolean
    • Specifies whether the user’s auth token must be regenerated or not.
    • Possible values :
      • true - Reset the previously issued token and generate a new auth token
      • false - Do not reset the user's auth token
    • Default value : true.
  • oneTimePassword boolean
    • Specifies whether a one-time password(OTP) must be generated to reset the user password.
    • Possible values :
      • true - Generate the one-time password
      • false - Do not generate the one-time password
    • Default value : true.
  • zuid* long
    • This parameter denotes the unique identifier for each user in an organization. 
    • This value can be retrieved using the GET all org user details API.
  • mode string
    • This parameter represents the type of operation that is to be performed.
    • Provide the value as resetPassword.

 

* - Mandatory parameter

Response Codes

Refer here for the response codes and their meaning.

Sample Request

Copiedcurl "https://mail.zoho.com/api/organization/1234567890/accounts/1234" \
-X PUT \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "Authorization: Zoho-oauthtoken ****************" \
-d '{
  "password": "t*c9ma",
  "resetAuthtoken": true,
  "oneTimePassword": true,
  "zuid": 1234,
  "mode": "resetPassword"
}'

Sample Response

Copied{
  "status": {
    "code": 200,
    "description": "success"
  }
}