/** * SlackHandler constructor. * * @param int $webhook Slack webhook url * @param string $channel Slack channel name * @param string $username Sender name * @param int $level * @param bool|true $bubble */ public function __construct($webhook, $channel, $username, $level = Logger::ERROR, $bubble = true) { $this->webhook = $webhook; $this->channel = $channel; $this->username = $username; parent::__construct($level, $bubble); }
/** * TelegramHandler constructor. * * @param int $botToken Bot token. More info: https://core.telegram.org/bots/api#authorizing-your-bot * @param bool $chatId Chat or Channel ID to send message. '@username' is possible too * @param int $level * @param bool|true $bubble */ public function __construct($botToken, $chatId, $level = Logger::ERROR, $bubble = true) { parent::__construct($level, $bubble); $this->botToken = $botToken; $this->chatId = $chatId; }