myopensoft / laravel-kepoh-webapi
To send error that been triggered by exception to WebAPI channels for internal error logging purpose.
1.0.3
2024-03-12 01:18 UTC
Requires
- php: ^7.4|^8.0
- ext-json: *
- illuminate/contracts: ^7.0|^8.0|^9.0|^10.0|^11.0
- spatie/laravel-package-tools: ^1.4.3
Requires (Dev)
- orchestra/testbench: ^6.13
- phpunit/phpunit: ^9.3|^10.0
- spatie/laravel-ray: ^1.9
- vimeo/psalm: ^4.4
This package is auto-updated.
Last update: 2024-09-12 02:20:53 UTC
README
To send error that been triggered by exception to WebAPI channels for internal error logging purpose.
Installation
You can install the package via composer:
composer require myopensoft/laravel-kepoh-webapi
You can publish the config file with:
php artisan vendor:publish --provider="Myopensoft\KepohTelegram\KepohWebapiServiceProvider" --tag="kepoh-webapi-config"
This is the contents of the published config file:
return [
'webapi' => [
'enable' => env('KEPOH_WEBAPI_ENABLE', false),
'access_token' => env('KEPOH_WEBAPI_ACCESS_TOKEN'),
'server_token' => env('KEPOH_WEBAPI_SERVER_TOKEN'),
'dont_report' => [
\Illuminate\Auth\AuthenticationException::class,
\Illuminate\Auth\Access\AuthorizationException::class,
\Illuminate\Session\TokenMismatchException::class,
\Illuminate\Validation\ValidationException::class,
]
]
];
Usage
Put into Handler.php
public function report(Throwable $exception)
{
// ...
KepohWebapi::report($exception);
parent::report($exception);
}
Changelog
Please see CHANGELOG for more information on what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
Credits
License
The MIT License (MIT). Please see License File for more information.