PSR compatible logger to send logs from php applications to the logbook server and client.

v0.2.1 2020-04-28 14:18 UTC

This package is auto-updated.

Last update: 2024-03-28 23:23:25 UTC


This package provides a PSR compatible Logger to send logs to the logbook server and client, The Logger provides the logger itself and some Adapter to send the logs in several ways.


You can install the php component of logbook via git or composer. For both you need composer to get the dependencies installed which are necessary.

From github

    ## Cloning git repo
    git clone /path/to/checkout
    ## cd in to path
    cd /path/to/checkout
    ## Install dependencies
    composer install --no-dev

From pakageist

    composer require axel-kummer/logbook-php


Basic usage.

First you have to setup the request instance which is used to send the logs.

//Make a request instance
$request = \AxelKummer\LogBook\LoggerUtility::setupRequest(

You can also add a unique request identifier for all logs within a request.


If it's done you can simply create logger which will have injected the request object.

//get a logger with injected request instance
$logger = \AxelKummer\LogBook\LoggerUtility::getLogger('MyLogger');

//Use the logger to send messages to the logbook server
$logger->info('My info mesage');

You can implement and use your own request class. Your Class have to extend \AxelKummer\LogBook\Request\AbstractRequest and implements the methods sendLog and getUrl