php - Telegram bot Send message -
i using irazasyed.github.io telegram sdk sending message here code when send message bot nothing happen , no reply receives problem ?
my_bot_token replaced
<?php require 'vendor/autoload.php'; use telegram\bot\api; $telegram = new api('my_bot_token'); $update = json_decode( file_get_contents( 'php://input' ) ); $chat_id = $update->getmessage()->getchat()->getid(); $response = $telegram->sendmessage([ 'chat_id' => $chat_id; 'text' => 'hello world' ]); $response->getmessageid(); ?>
Comments
Post a Comment