/** * Bot install action * * @param Bot $bot */ public function install(Bot $bot) { $result = $this->call('imbot.register', $bot->getData(), $this->auth); $appsConfig = []; $appsConfig[$_REQUEST['auth']['application_token']] = array('BOT_ID' => $result['result'], 'LANGUAGE_ID' => $_REQUEST['data']['LANGUAGE_ID']); $this->saveParams($appsConfig); }