Download the PHP package ami-praha/ai-logger without Composer
On this page you can find all versions of the php package ami-praha/ai-logger. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download ami-praha/ai-logger
More information about ami-praha/ai-logger
Files in ami-praha/ai-logger
Package ai-logger
Short Description A Laravel package that provides a logging driver to send logs to a specified external webhook.
License MIT
Informations about the package ai-logger
AI Logger
Repository
ami-praha/ai-logger
Description: A Laravel package providing a logging channel that sends log messages to an external webhook.
Overview
This package adds a custom Laravel logging channel called ai-logger. When used, it sends log messages (and context data) as JSON payloads to a configured webhook URL.
Installation
Require the package via Composer:
No further configuration file publishing is necessary.
Configuration
Environment Variable
Set the webhook URL in your application's .env file:
Configuring Logging Channel
In Laravel's config/logging.php, add a new channel ai-logger. Also if you are using a stack channel and want to automatically send any logs to ai-logger (recommended), add it to stack.channels array:
Usage
To log using AI Logger, specify the ai-logger channel in your code:
This will send the log message, context data, log level, and timestamp as a JSON payload to the configured webhook URL.
Verifying Functionality
- Set up a Test Webhook: Use tools like Webhook.site or RequestBin to create a temporary webhook endpoint.
-
Trigger a Log: Execute a log statement:
- Inspect Received Payload: Confirm the JSON payload arrives at your test webhook.
Requirements
- PHP:
^7.4 | ^8.0 | ^8.1 | ^8.2 | ^8.3 - Laravel:
^8.0 | ^9.0 | ^10.0 | ^11.0 | ^12.0
Contributing
Contributions are welcome!
- Fork and create a feature branch.
- Submit your changes through a Pull Request.
- Provide a clear description of your updates.
For bugs or feature requests, please create an issue on GitHub.
License
Licensed under the MIT License.
Thank you for using AI Logger! If you have questions, open an issue on GitHub or contact the maintainer.
All versions of ai-logger with dependencies
illuminate/support Version ^8.0|^9.0|^10.0|^11.0|^12.0
monolog/monolog Version ^2.0|^3.0