{"id":28548919,"url":"https://github.com/emotality/laravel-telegram-logger","last_synced_at":"2025-07-04T04:31:55.195Z","repository":{"id":197675106,"uuid":"699093316","full_name":"emotality/laravel-telegram-logger","owner":"emotality","description":"Laravel package to report exceptions to a Telegram chat, group or channel.","archived":false,"fork":false,"pushed_at":"2025-02-24T19:44:26.000Z","size":15,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-06-08T02:22:53.801Z","etag":null,"topics":["laravel","log","logger","logging","telegram","telegram-api","telegram-bot"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/emotality.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"custom":"https://www.buymeacoffee.com/emotality"}},"created_at":"2023-10-01T22:21:02.000Z","updated_at":"2025-02-24T19:44:19.000Z","dependencies_parsed_at":"2023-10-03T02:37:08.511Z","dependency_job_id":"c53490bc-5119-4879-8d26-715ee1f15c81","html_url":"https://github.com/emotality/laravel-telegram-logger","commit_stats":null,"previous_names":["emotality/laravel-telegram-logger"],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emotality%2Flaravel-telegram-logger","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emotality%2Flaravel-telegram-logger/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emotality%2Flaravel-telegram-logger/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emotality%2Flaravel-telegram-logger/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/emotality","download_url":"https://codeload.github.com/emotality/laravel-telegram-logger/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/emotality%2Flaravel-telegram-logger/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":258988859,"owners_count":22789055,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["laravel","log","logger","logging","telegram","telegram-api","telegram-bot"],"created_at":"2025-06-10T01:35:07.147Z","updated_at":"2025-07-04T04:31:55.167Z","avatar_url":"https://github.com/emotality.png","language":"PHP","funding_links":["https://www.buymeacoffee.com/emotality"],"categories":[],"sub_categories":[],"readme":"# Telegram Logger for Laravel\n\n\u003cp\u003e\n    \u003ca href=\"https://packagist.org/packages/emotality/laravel-telegram-logger\"\u003e\u003cimg src=\"https://img.shields.io/packagist/l/emotality/laravel-telegram-logger\" alt=\"License\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://packagist.org/packages/emotality/laravel-telegram-logger\"\u003e\u003cimg src=\"https://img.shields.io/packagist/v/emotality/laravel-telegram-logger\" alt=\"Latest Version\"\u003e\u003c/a\u003e\n    \u003ca href=\"https://packagist.org/packages/emotality/laravel-telegram-logger\"\u003e\u003cimg src=\"https://img.shields.io/packagist/dt/emotality/laravel-telegram-logger\" alt=\"Total Downloads\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\nLaravel package to report exceptions to a Telegram chat, group or channel.\n\n\u003cp\u003e\n    \u003ca href=\"https://www.telegram.org\" target=\"_blank\"\u003e\n        \u003cimg src=\"https://raw.githubusercontent.com/emotality/files/master/GitHub/Telegram.png\" height=\"50\"\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n## Requirements\n\n- PHP 8.1+\n- Laravel 10\n\n## Installation\n\n1. `composer require emotality/laravel-telegram-logger`\n2. `php artisan vendor:publish --provider=\"Emotality\\Telegram\\TelegramLoggerServiceProvider\"`\n3. Add the following lines to your `.env`:\n\n```dotenv\nTELEGRAM_API_KEY=\"\u003ctelegram_api_key\u003e\"\nTELEGRAM_CHAT_ID=\"\u003ctelegram_chat_id\u003e\"\n```\n\n4. Add the `telegram` block to the `channels` array, inside your `config/logging.php` file:\n\n```php\n'channels' =\u003e [\n    ...\n    'telegram' =\u003e [\n        'driver' =\u003e 'telegram',\n        'level' =\u003e 'error',\n        'cache_ttl' =\u003e env('TELEGRAM_CACHE_TTL', 300),\n    ],\n],\n```\n###### _Note: Read more about the `cache_ttl` key below._\n\n5. Update your log stack and add `telegram` to the `channels` array in `config/logging.php`:\n\n```php\n'stack' =\u003e [\n    'driver' =\u003e 'stack',\n    'channels' =\u003e ['daily', 'telegram'],\n    ...,\n],\n```\n\nor change your `LOG_CHANNEL` in your `.env`:\n\n```dotenv\nLOG_CHANNEL=telegram\n```\n\n### Caching TTL explained:\n\nA MD5 checksum is being created for every exception, then that checksum is being cached for the `cache_ttl` seconds you provide. If checksum exists in the cache, the log will not be sent.\n\nIn other words, when the exact same exception reoccurs, only the first exception will be logged, if after 300 seconds it still occurs, it will be logged again.\u003cbr\u003e\nOnly the first occurrence of the same exception will be logged every 300 seconds to avoid flooding the Telegram API and your chat.\n\nThe `cache_ttl` key accepts `false` to disable caching, meaning, each and every exception will be logged to Telegram, even if it's 1000 of the same exception.\n\n## License\n\nlaravel-telegram-logger is released under the MIT license. See [LICENSE](https://github.com/emotality/laravel-telegram-logger/blob/master/LICENSE) for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femotality%2Flaravel-telegram-logger","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Femotality%2Flaravel-telegram-logger","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Femotality%2Flaravel-telegram-logger/lists"}