Does anyone have an example editMessageText in Telegram?

A novice programmer. Want to make the change messages when you click on the button. A simple change bot.sendMessage on the bot.editMessageText not successful...

bot.sendMessage(, `Test `, {
reply_markup: {inline_keyboard:[[{text:' test', callback_data:'01', url:''}]]}
June 8th 19 at 17:04
1 answer
June 8th 19 at 17:06
wrong message edit
$update = $this->getUpdate();
 $callback_query = $update->getCallbackQuery();
 $message_id = $callback_query->getMessage()->getMessageId();
 $chat_id = $callback_query->getMessage()->getChat()->getId();
 'chat_id' => $chat_id,
 'message_id' => $message_id,
 'text' => 'new text'
You node.js write ?

then, by analogy, should be so
bot.editMessageText('new text',{,});

query.calback_query - maybe a little not so is called. - Thomas.Swi commented on June 8th 19 at 17:09

Find more questions by tags Telegram