alexeevdv/yii2-log-slack

Installs: 5 286

Dependents: 0

Suggesters: 0

Security: 0

Stars: 1

Watchers: 2

Forks: 2

Open Issues: 1

Type:yii2-extension

1.0.1 2018-02-18 09:21 UTC

This package is auto-updated.

Last update: 2024-03-20 21:27:27 UTC


README

Build Status codecov

PHP 5.6 PHP 7.0 PHP 7.1 PHP 7.2 PHP 7.3 PHP 7.4

Sends log messages to Slack webhook.

Installation

The preferred way to install this extension is through composer.

Either run

$ php composer.phar require alexeevdv/yii2-log-slack "^1.0"

or add

"alexeevdv/yii2-log-slack": "^1.0"

to the require section of your composer.json file.

Configuration

Through application component

//...
'components' => [
    //...
    'log' => [
        //...
        'targets' => [
            //...
            [
                'class' => alexeevdv\log\SlackTarget::class,
                'webhook' => 'https://your_webhook_link',
                // other optional params goes here
            ],
            //...
        ],
        //..
    ],
    //...
],
//...

Supported params:

For the list of supported params please refer to https://github.com/maknz/slack