Update User

WCF


Method
public AuthServerResponse UpdateUser(string authServerPartnerLoginName, 
                 string authServerPartnerLoginPassword, 
                 string authServerPartnerUserLoginName,
                 string firstName,
                 string lastName,
                 string mobile,
                 string email,
                 string pw, 
                 short  userStatus)

WCF parameterdata typedescription
authServerPartnerLoginNamestringSurePassID account login name
authServerPartnerLoginPasswordstringSurePassID account login key
authServerPartnerUserLoginNamestringUser account login name
firstNamestringFirst name. Empty value leaves the current value as is.
lastNamestringLast Name. Empty value leaves the current value as is.
mobilestringMobile device number. The  format is: +aaa(bbb)cccccccc where aaa is country code , bbb is area code and ccccccc is the local number. For example.  US: +1(800)200-8411 UK: +44(0)20 1234 5678. Empty value leaves the current value as is.
emailstringEmail. Empty value leaves the current value as is.
pwstringUsers new password. This can be plain text or hash. In either case, the password will be encrypted by the server. Empty value leaves the current value as is.
userStatusshort0 - user is enabled, 1 - user is disabled
Sample WCF C# Method
AuthServerResponse  resp = UpdateUser("accountLogin",             
            "accountKey", 
            "Mandy", 
             false
            );
Sample WCF C# Repsonse
 if (resp.ErrorCode != 0)  {      
       message.Text = resp.ErrorMsg;
       return false;
 }


REST


REST parameterdata typedescription
spAccountLoginNamestringSurePassID account login name
spAccountLoginKeystringSurePassID account login key
usernamestringuser account login name
typestringupdate_user
firstNamestringFirst name. If omitted, the value is not updated.
lastNamestringLast Name. If omitted, the value is not updated.
mobilestringMobile device number. The  format is: +aaa(bbb)cccccccc where aaa is country code , bbb is area code and ccccccc is the local number. For example.  US: +1(800)200-8411 UK: +44(0)20 1234 5678. If omitted, the value is not updated.
emailstringEmail. If omitted, the value is not updated.
pwstringUsers new password. This can be plain text or hash. In either case, the password will be encrypted by the server. If omitted, the value is not updated.
userStatusshort0 - user is enabled, 1 - user is disabled
Sample REST/Json Method
 {  
  "username": "Mandy",
  "spAccountLoginName": "accountLogin",
  "spAccountLoginKey": "accountKey",
  "firstName": "New First Name",
  "lastName": "New Last Name",        // do not update this leave it as it is.
  "mobile": "+1(345)123-4567",
  "email": "mandy@newco.com",
  "userStatus": 0,                    // enabled 
  "type": "update_user",


}
Sample REST/Json Response
 {
  "errorCode": 0,
  "errorMessage": "OK",
  "type": "update_user"
}