I`m doing registration in my telegram bot.
For example i have "check_me" comand. When user enter this comand, user should enter email and password to bot and write this datas to php variables.
[User: enter "/check_me"]
[Bot: "Enter email"]
[User entered email]
[Bot: "Enter pass"]
[User Entered pass]
$bot->command('check_me', function ($message) use ($bot,$TOKEN_DEV) {
$range = 'regisrtation!A2:D';
$users = getdata($range);
$id = $message->getChat()->getId();
$bot = new \TelegramBot\Api\BotApi($TOKENDEV);
$update = new \TelegramBot\Api\Types\Update;
$checkmail = '';
$bot->sendMessage($id, 'Enter email');
$message = $update->getMessage();
$check_mail = $message->getText();
$bot->sendMessage($id, 'Your email '.$check_mail);
}
I`m doing registration in my telegram bot. For example i have "check_me" comand. When user enter this comand, user should enter email and password to bot and write this datas to php variables. [User: enter "/check_me"] [Bot: "Enter email"] [User entered email] [Bot: "Enter pass"] [User Entered pass]
$bot->command('check_me', function ($message) use ($bot,$TOKEN_DEV) { $range = 'regisrtation!A2:D'; $users = getdata($range); $id = $message->getChat()->getId(); $bot = new \TelegramBot\Api\BotApi($TOKENDEV); $update = new \TelegramBot\Api\Types\Update; $checkmail = ''; $bot->sendMessage($id, 'Enter email'); $message = $update->getMessage(); $check_mail = $message->getText(); $bot->sendMessage($id, 'Your email '.$check_mail); }