MyChat 2023.5 — Integration API update

  1. New Integration API
  2. New logging system
  3. Various improvements
  4. Full list of changes + development history
  5. How to update to the latest version?

1. New Integration API


This technology works in MyChat for a long time. It used for sending messages from console utility, bindings with various systems via REST, phpBB, etc.

We updated the documentation very thoroughly by adding new helpful parameters to commands.

Each command now can use an optional textual parameter "context", to analyze responses to commands in asynchronous queries. Error messages are supplied with links that forward to the Help page (directly in JSON responses).

Also, we added a couple of new commands in Integration API: MCIAPI_CS_SetUserInfoByUIN, MCIAPI_CS_SetChannelTopic, MCIAPI_CS_GetChannelInfo, and MCIAPI_CS_GetChannelUIDByName.


2. New logging system


We redesigned the logging system for MyChat Client to be compatible with the SysLog standard.

All events are divided into 6 categories:

[FATAL] = 1

any error that causes the application or service to shut down to prevent data loss (or possible data loss). These are the hardest errors and situations when data loss or corruption is guaranteed.

[ERROR] = 2

any error that is considered fatal for an operation but not for the service or application (can't open a file, no data, incorrect password, etc.) These errors require administrator supervision but do not cause fatal errors.

[WARN] = 3

anything that can possibly cause weird behavior of the application, but which the program removes automatically or continues working without fatal errors (for example, switching from a main to a reserved server, repeat operation attempt, absence of additional data, etc.).

[INFO] = 4

helpful information for work. Information that is very handful but considered as not worthy of attention in regular conditions. This is the default level of logging.

[DEBUG] = 5

extended diagnosis (IT personnel, system administrators, etc.).

[TRACE] = 6

"tracing", for detailed and deep troubleshooting that produces a lot of logs.

To change the logging level, use a console command loglevel.

We have also started to implement this system on the server. In the next versions, it will extend on a constant basis.


3. Various Improvements


In MyChat Client for Windows, we have added the setting that allows editing own sent messages in dialogues with the symbol "*", and an option to enter the account manager after exiting the program manually (Alt+X).

When you switch to the console (Ctrl+`), the program changes the input method to English language for convenient command writing.

Some minor improvements for the filter of IP addresses on the server: client errors about IP addresses are more informative with data about an IP being seen on the server side for convenient troubleshooting of incorrect filtering conditions on the server.

If you scroll up through the messages in conferences or private dialogues, and then receive a message, then the history does not scroll down automatically as during sending your own messages. Now reading became convenient.


4. Full list of changes + development history


Development history with developers' comments

MyChat Client

[+] (integration api) command MCIAPI_CS_SetChannelTopic for changing the topic of the conference;
[+] (win32) settings for extended editing of sent messages with the "*" symbol;
[+] (win32) settings for opening the account manager after manually exiting the program (Alt+X);

[*] (win32) newline characters (CR/LF) in a conference topic are ignored automatically;
[*] redesigned system for logs for compatibility with the SysLog standard;
[*] client errors regarding IP address blocking are supplemented with information about IP that "sees" the server from its side which helps to identify issues with incorrect filter conditions on the server;
[*] (win32) when scrolling up message history in a conference or private dialogue, and then receive an incoming message, then history no longer scroll down automatically like when you send a message;

[-] (win32) changing a conference topic does not work in MyChat Client;
[-] (win32) when using Integration API for changing the topic of the conference to empty, then MyChat Client ignores it until reconnection. Fixed;
[-] (win32) when a new client connects to an outdated server, it displays an incorrect error message. Fixed;
[-] (android) in Android 13, permission request does not display when attempting to send a file or photo. Fixed;
[-] (win32) error #0103 when processing lists of allowed/forbidden plugins. It occurs when the list of forbidden plugins is empty. Fixed;

MyChat Server

[+] (integration api) command MCIAPI_CS_GetChannelUIDByName for getting a conference UID by its name;
[+] (integration api) command MCIAPI_CS_GetChannelInfo for getting a name and topic of the conference by its UID;
s [+] (integration api) added optional parameter "Context" for all Integration API commands;
[+] (integration api) the command MCIAPI_CS_AddBBSMessage, added the field Expired for getting announcement expiration date/time;
[+] (integration api) the function MCIAPI_CS_SetUserInfoByUIN for editing fields of a user by their UIN;
[+] (msl) the script function mGetUserDataAsJSON is supplied with the parameter BirthdayISO in the ISO 8601 format;

[*] (integration api) parameter Type in the function MCIAPI_CS_MediaCall is renamed to CallType;
[*] (integration api) the function MCIAPI_CS_MediaCall, added fields UINFrom, UINTo, and CallType;
[*] (integration api) the function MCIAPI_CS_AddUserToCommonContacts, added fields GroupID and UIN;
[*] (integration api) the function MCIAPI_CS_CommonContactsRebuild is removed, the cache of the common contact list updates automatically;
[*] (integration api) significant control enhancements for cata correctness check to reduce possible server crashes during accidental or intentional incorrect data in requests;
[*] (integration api) updated Help page, added about 2 dozen new errors;
[*] (integration api) the command MCIAPI_CS_GetLoginToken, added the parameter UIN;
[*] (integration api) the command MCIAPI_CS_GetLoginToken, the parameter Style is replaced with AuthType;
[*] (integration api) added the field ID in the function MCIAPI_CS_GetWebSupportGroupUsersList;
[*] (integration api) added the field ActualTo in the function MCIAPI_CS_SendBroadcastMessage;
[*] (integration api) the command MCIAPI_CS_AddBBSMessage, added the field Expired for getting expiration date/time of an announcement (integration API); you can specify a domain user (domain\login) in the parameter UserFrom of the command MCIAPI_CS_AddBBSMessage;
[*] (integration api) parameter Expired in the command MCIAPI_CS_AddBBSMessage is now specified in UTC;
[*] (integration api) the command MCIAPI_CS_RegisterNewUser, removed parameters IP, NetName, and ClientType; added control for nicknames and emails duplicates, processing of reserved nicknames;
[*] (integration api) parameter "Started" in the command MCIAPI_CS_GetServerInfo now contains the date and time in ISO format (yyyy-mm-dd hh:nn:ss);
[*] (integration api) re-made command MCIAPI_CS_GetUINByEmail, removed parameters Domain and AuthType;
[*] (integration api) re-made command MCIAPI_CS_GetUINByNick, removed parameters Domain and AuthType, a domain can be specified in the filed Nick ("domain\login");

[-] when changing the topic of the conference with an obscene words filter on, then conference topic check flag processes incorrectly;
[-] (integration api) the command MCIAPI_CS_SendBroadcastMessage does not return ID;
[-] "Wake up a user" (F8 in a private dialogue) causes the application to disconnect from the server. Fixed;
[-] (support) website support chat does not work in a browser during incognito mode. Fixed;
[-] an error when changing the cache size settings of the built-in WEB server;
[-] error when changing settings of the URL page of the built-in ad, if it is on.

5. How to update to the latest version?


Both commercial and free versions are updated in the same way. The server is updated first, then the clients. In general, this process is performed automatically.

Instruction for updating MyChat

Служба поддержки