User APIs

User API - Bulk - Reset password

OVERVIEW

 

NOTE : This API endpoint will be supported in version 5.0 onwards

Overview

This API call is used to reset a user password.

HTTP Request

PUT   /api/4/users?action=resetpassword

HTTP Request Object

Request xml

<users> 
    <user> 
        <userid>102</userid>
        <userid>101</userid>
    </user>
</users>

Request JSON

{
    "user": {
        "userid": [
            "102",
            "101"
        ]
    }
}

HTTP Headers
HTTP Request Header Description Example
Authorization The API Authorisation token "Bearer XXXXXXXXXXXXX"
Accept

The format of the expected response. 

  • "application/json"
  • "application/xml"

If no parameter is set, XML is the default response given.

"application/xml"
Content Type
  • application/xml
  • application/json
"application/xml"

 

HTTP Response

Success

HTTP response 200

 

Example

PUT  http://example.com/context/api/4/users?action= resetpassword

 

XML Format

<users>
    <user>
        <id>101</id>
        <resetlink>http://example.com/context/ConformUser_input.action?conformUser.passwordResetKey=Odjc3OQUHkH6wMoDW0JNh2n_DQwvwbLzdIKnCl1XxdisWR8MYEA_4NSg71WufYKlbQN3DHCqT9I=</resetlink>
    </user>
    <user>
        <id>102</id>
        <resetlink>http://example.com/context/ConformUser_input.action?conformUser.passwordResetKey=Q4k0eFeyUOuu3lsRnO0d9c2N4rJa9mNXe_HWXDgW6Aa1q3Un5lV8SOKnpHBnCbtF8TPOvFRAjPc=</resetlink>
    </user>
</users>

 

JSON Format

{
    "user": [
        {
            "id": "102",
            "resetlink": "http://example.com/context/ConformUser_input.action?conformUser.passwordResetKey=Q4k0eFeyUOuu3lsRnO0d9c2N4rJa9mNXe_HWXDgW6Aa1q3Un5lV8SAkbIuqv-XGGBtLkkapUNq8="
        },
        {
            "id": "101",
            "resetlink": "http://example.com/context/ConformUser_input.action?conformUser.passwordResetKey=Odjc3OQUHkH6wMoDW0JNh2n_DQwvwbLzdIKnCl1XxdisWR8MYEA_4KQ4v1dlYpV0mxIcll-obd0="
        }
    ]
}

Error messages

Summary Ref Code (V4) Ref Code (before V4)
A User id is required 109  
The following users do not exist within the system: 110  
The given action cannot be performed on anonymised user(s). 325  
User id is not in the proper format 113  
This url is not valid. Status and Action cannot be performed as combined 371  
This given action is invalid. Please use unlock,invite or resetpassword 367  
The following users are not active within the system: 395  

Comments


0 Comments

Last Updated: Nov 08,2024