huyct / log-helper
Log Helper Package
v2.0.0
2025-02-25 10:36 UTC
Requires
- php: >8.0
- ext-json: *
- guzzlehttp/guzzle: ^7.2
- laravel/framework: ^8.75|^9.0.0|^10.0.0|^11.0.0|^12.0.0
README
- This package help us send log to Telegram channel through a bot chat and it runs with Job in Laravel framework.
1. Requirement and install
- PHP >=7.0
composer require huyct/log-helper
- Add this line to
bootstrap/providers.php
in laravel >=11.0 and inconfig/app.php
in lower version.
\Huyct\TelegramHelper\providers\LogHelperProvider::class,
- Publish config
php artisan vendor:publish --tag=loghelper
# Position of file config: config/loghelper.php
- Add these lines to
.env
TELEGRAM_BOT_TOKEN= TELEGRAM_CHANNEL_LOG_ID= TELEGRAM_CHANNEL_ERROR_ID= // these lines if you lack HELPER_LOG_DRIVER=telegram HELPER_LOG_ENABLE=true HELPER_LOG_QUEUE_NAME=send-log