addCommands([ new Commands\MyCommand(), new Commands\HelpCommand(), new Commands\MenuCommand(), new Commands\PingCommand(), new Commands\StartCommand(), new Commands\UnbindCommand(), new Commands\CheckinCommand(), ]); $bot->commandsHandler(true, $request); $bot->setConnectTimeOut(1); $update = $bot->getWebhookUpdate(); if ($update->has('callback_query')) { new Callback($bot, $update->getCallbackQuery()); } elseif ($update->has('message')) { new Message($bot, $update->getMessage()); } } }