Skip to content
This repository has been archived by the owner on Apr 21, 2019. It is now read-only.

vyuldashev/monolog-telegram

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Telegram handler for Monolog

Installation

$ composer require vladimir-yuldashev/monolog-telegram

Usage

<?php

use Monolog\Logger;
use VladimirYuldashev\Monolog\TelegramHandler;

$telegramToken = '';
$chatId = 1;

$handler = new TelegramHandler(
    Logger::ERROR,
    $telegramToken,
    $chatId
);

$log = new Logger('name');
$log->pushHandler($handler);

// add records to the log
$log->warning('Foo');
$log->error('Bar');

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages