for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
namespace TelegramBotTest\Examples\EchoBot\Plugins;
use TelegramBot\Entities\Message;
class MainPlugin extends \TelegramBot\Plugin {
public function onMessage(int $updateId, Message $message): \Generator {
echo "UpdateId: " . $updateId . ", Text: " . $message->getText();
yield;
}