nfacha/dicord-log-target

该包最新版本(dev-master)没有可用的许可证信息。

Discord WebHook 日志目标库 for Yii2

安装: 3

依赖: 0

建议者: 0

安全: 0

星标: 0

关注者: 1

分支: 0

开放问题: 1

类型:yii2-extension

dev-master 2020-05-15 09:09 UTC

This package is auto-updated.

Last update: 2024-09-16 05:16:47 UTC


README

将以下内容添加到您的应用程序组件中

'log'                  => [
            'traceLevel' => YII_DEBUG ? 3 : 0,
            'targets'    => [
                [
                    'class'          => DiscordLogTarget::class,
                    'webhookUrl'     => 'https://discordapp.com/api/webhooks/<WebhookURL>>',
                    'levels'         => [ 'error' ],
                    'exportInterval' => 1,
                    'maskVars'       => [ '_SERVER', '_COOKIE' ],
                    'except'         => [
                        'yii\web\HttpException:404',
                        'yii\web\HttpException:400',
                        'yii\web\HttpException:403',
                        'yii\i18n\*',
                    ],
                ],
            ],