MyChat Integration API: MCIAPI_CS_SetUserInfoByUIN, modify properties of a user's account by their UIN
Edit account properties by using a user's UIN.
Syntax
{
"cmd" : "001E",
"ServerKey" : "iddqd",
"APIStype" : "mydata",
"UIN" : 23,
"What" : "Email,AuthType,Active,Pass,RoleName,WorkDept,DomainName,Nick",
"Email" : "john.smith@fbi.com",
"AuthType" : 1,
"Active" : true,
"Pass" : "NewSecretPass",
"RoleName" : "Guests",
"WorkDept" : "AI engineers",
"DomainName" : "fbi.com",
"Nick" : "john.smith"
}
Parameters
|
Parameter |
Type |
Value |
|
cmd |
string |
"001E", MCIAPI_CS_SetUserInfoByUIN command number; |
|
ServerKey |
string |
Integration API key (set in the server's settings); |
|
APIStype |
string |
integration type. Specify any string; |
|
UIN |
integer |
user account ID, a number grater than 0; |
|
What |
string |
what data is required; A string with parameters separated by commas, no spaces, letter case matters. |
List of available parameters
|
Name |
Type |
Description |
|
Pass |
string |
user's new password; |
|
Tag |
string |
text tag, special field, can be edited and read via MSL; |
|
DomainName |
string |
user's domain name; |
|
Nick |
string |
user's nickname. If it is a domain user then it is his domain name; |
|
DisplayName |
string |
user's display name. The style is configured on the server; |
|
Active |
boolean |
active or blocked user's account; |
|
FirstName |
string |
user's real name; |
|
MiddleName |
string |
user's middle name; |
|
LastName |
string |
user's last name; |
|
Registered |
double |
date and time of the account creation; |
|
Role |
integer |
user's role (the number of the rights group); |
|
RoleName |
string |
name of the user's rights group; |
|
MaritalStatus |
integer |
marital status: -1 — unspecified; 0 — in a relationship; 1 — widowed; 2 — married; 3 — engaged; 4 — divorced; 5 — separated; 6 — unmarried; |
|
HomePhone |
string |
home phone number; |
|
HomeFax |
string |
home fax; |
|
Birthday |
double |
date of birth; |
|
BirthdayISO |
string |
birth day in the format ISO 8601 (yyy-mm-dd) |
|
|
string |
main email address; |
|
HomeCellular |
string |
personal mobile phone; |
|
HomeStreetAddress |
string |
home address; |
|
HomeCity |
string |
home city; |
|
HomeState |
string |
state/province/region/district; |
|
HomeZIP |
string |
home ZIP code; |
|
HomeCountry |
integer |
home country; |
|
HomeWWW |
string |
personal WEB page; |
|
WorkDept |
string |
work department; |
|
WorkDeptIdx |
integer |
internal index of the work department (number); |
|
WorkPosition |
string |
work position; |
|
WorkPositionIdx |
integer |
internal index of the work position (number); |
|
WorkCompanyName |
string |
company name; |
|
WorkOffice |
string |
work office; |
|
WorkPhone |
string |
work phone number; |
|
WorkFax |
string |
work fax; |
|
WorkPager |
string |
work pager or messenger number; |
|
WorkStreetAddress |
string |
work address; |
|
WorkCity |
string |
work city; |
|
WorkState |
string |
work state/province/region/district; |
|
WorkZIP |
string |
work ZIP code; |
|
WorkCountry |
integer |
work country; |
|
WorkWWW |
string |
work WEB page; |
|
SpokenLang1 |
integer |
language spoken, number 1; |
|
SpokenLang2 |
integer |
language spoken, number 2; |
|
SpokenLang3 |
integer |
language spoken, number3; |
|
Interests1 |
integer |
interests section, number 1; |
|
InterestsWords1 |
string |
interests section, key words, number 1; |
|
Interests2 |
integer |
interests section, number 2; |
|
InterestsWords2 |
string |
interests section, key words, number 2; |
|
Interests3 |
integer |
interests section, number 3; |
|
InterestsWords3 |
string |
interests section, key words, number 3; |
|
Interests4 |
integer |
interests section, number 4; |
|
InterestsWords4 |
string |
interests section, key words, number 4; |
|
Past1 |
integer |
type of former employment or study, number 1; |
|
PastWords1 |
string |
type of former employment or study, key words number 1; |
|
Past2 |
integer |
type of former employment or study, number 2; |
|
PastWords2 |
string |
type of former employment or study, key words number 2; |
|
Past3 |
integer |
type of former employment or study, number 3; |
|
PastWords3 |
string |
type of former employment or study, key words number 3; |
|
PastOrg1 |
integer |
organization type, former employment, number 1; |
|
PastOrgWords1 |
string |
organization type, former employment, key words number 1; |
|
PastOrg2 |
integer |
organization type, former employment, number 2; |
|
PastOrgWords2 |
string |
organization type, former employment, key words number 2; |
|
PastOrg3 |
integer |
organization type, former employment, number 3; |
|
PastOrgWords3 |
string |
organization type, former employment, key words number 3; |
|
Sex |
integer |
user's gender: 0 — unspecified, 1 — male, 2 — female; |
|
AuthType |
integer |
type of client authentication: 0 — default, 1 — Active Directory, 2 — without a password, 3 — Transparent AD; |
|
FotoCRC32 |
integer |
user's CRC32 photos; |
|
LastAccess |
double |
date and time of the last access to the server; |
|
LastSpeakTime |
double |
date and time of the last sent message; |
|
State |
integer |
current user's network status; |
|
FavoriteChannelsExists |
boolean |
check user's list of favorite text conferences; |
|
UnreadedBroadcastsExists |
boolean |
availability of unread notifications; |
|
OfflineMessagesExists |
boolean |
availability of the offline messages that were not received; |
|
HelloMessage |
string |
greeting message, if available. Displays to all users, who opened the private chat with this person; |
|
AutoreplayMessage |
string |
auto-reply message; |
|
Autoreplay |
boolean |
enabled or disabled answerphone; |
|
Reputation |
integer |
user's reputation, number; |
|
About |
string |
information field "About user"; |
The example of the GET request in the browser address bar
http://192.168.10.1:8080/API/?data={"cmd":"001E","ServerKey":"iddqd","APIStype":"mydata","UIN":23,"What":"Email,AuthType,Active,Pass,RoleName,WorkDept,DomainName,Nick","Email":"john.smith@fbi.com","AuthType":1,"Active":true,"Pass":"NewSecretPass","RoleName":"Guests","WorkDept":"AI engineers","DomainName":"fbi.com","Nick":"john.smith"}
Work result
{
"cmd" : "001E",
"UIN" : 23
}
|
Parameter |
Type |
Value |
|
cmd |
string |
HEX number of successfully executed command; |
|
UIN |
integer |
user's unique identifier; |
Possible errors
#5, MCIAPI_Error_WrongIntegrationKey
#20, MCIAPI_Error_EmailNotFound
#23: MCIAPI_Error_EmailIsNotDefined
See also