A lightweight Flutter package for logging messages directly to a Telegram bot. Easily send logs, debug information, or notifications to your Telegram chats with minimal setup. Ideal for monitoring apps or debugging in real-time.
If Telegram is practically your second home, why not make it your logging hub too? This package lets you send logs and updates directly to your Telegram chat, so you can stay on top of your app's performance while pretending you're just checking messages. Productivity has never been so convenient—or so sneaky.
First , you need to create a bot using this bot and get your api token.
then for every user you need to be notified when a new message sent , you need to use this bot to get the user id
First of all you need to initialize the logger instance
Telelog.instance.init(
apiToken: 'your api token',
usersIds: ['your chat id']
);
and then you can use this function to send messages to users
Telelog.instance.i(message: 'Hello World', parameters: {
'app name': 'my cool app',
});
the package has several logging levels to helps you differentiate the log type
Level | Method | Alternative |
---|---|---|
Debug | Telelog.instance.d |
Telelog.instance.debug |
Info | Telelog.instance.i |
Telelog.instance.info |
Warning | Telelog.instance.w |
Telelog.instance.warning |
Error | Telelog.instance.e |
Telelog.instance.error |
Fatal | Telelog.instance.f |
Telelog.instance.fatal |