First iteration

This commit is contained in:
2022-09-30 01:46:02 +00:00
parent b290f82dc5
commit e3cf8ddca4
7 changed files with 1021 additions and 0 deletions

13
set_web_hook.php Normal file
View File

@@ -0,0 +1,13 @@
<?php
require __DIR__ . '/vendor/autoload.php';
require __DIR__ . '/env.php';
try {
$telegram = new Longman\TelegramBot\Telegram($bot_api_key, $bot_username);
$result = $telegram->setWebhook($hook_url);
if ($result->isOk()) {
echo $result->getDescription();
}
} catch (Longman\TelegramBot\Exception\TelegramException $e) {
echo $e->getMessage();
}