PHP code example of hadi-aj / intellisense-telegram-bot

1. Go to this page and download the library: Download hadi-aj/intellisense-telegram-bot library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

hadi-aj / intellisense-telegram-bot example snippets



HadiAj\IntelliSenseTelegramBot\Telegram;

// Now you can instantiate new Telegram(...) and enjoy full IntelliSense support.


use HadiAj\IntelliSenseTelegramBot\Telegram;

$bot = new Telegram('TELEGRAM_BOT_TOKEN');

$response = $bot->sendMessage([
  'chat_id' => 12345678,
  'text'    => 'Hello from IntelliSense-enabled Telegram Bot!'
]);

echo $response->message_id;