Пример отправки сообщения в чат на языке php
Отправляется приватное сообщение от имени встроенного бота (UIN 0) для пользователя с UIN = 1. Можно для удобства вместо UIN использовать ники или email.
$host = '192.168.10.100';
$portWEB = '80';
$typeOfConnection = 'http';
$integrationAPIKey = 'iddqd';
$cmd = '0002';
$userTo = '1';
$userFrom = '0';
$msg = 'hello';
$toolName = 'php';
$json = json_encode(array('cmd'=>$cmd, 'UserTo' =>$userTo, 'UserFrom' =>$userFrom, 'Msg'=>$msg, 'APIStype'=>$toolName, 'ServerKey'=>$integrationAPIKey));
$json = urlencode($json);
$URL = $typeOfConnection.'://'.$host.':'.$portWEB.'/API/?data=' . $json;
file_get_contents($URL);
Подставляю свои host, portWeb, integrationAPIKey
при вызове скрипта ошибка Sorry, path /API/ not found :(
в логе
[err 24:01:2017 16:41:19]: SendFile Error:ENOENT, stat 'C:\Program Files (x86)\MyChat Server\node\server\www\chat\API\undefined'