mirkhamidov/yii2-telegram-notifications

This package is abandoned and no longer maintained. The author suggests using the m1roff/yii2-telegram-notifications package instead.

Telegram Notifications

Installs: 4 190

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 1

Open Issues: 0

Type:yii2-extension

2.0.0 2022-09-08 17:31 UTC

This package is auto-updated.

Last update: 2022-09-08 17:34:34 UTC


README

Installation

The preferred way to install this extension is through composer.

Either run

composer require m1roff/yii2-telegram-notifications "dev-master"

Configure

add this lines to your project config file

'components' => [
    ...,
    'telegram' => [
        'class' => \m1roff\TelegramNotifications::class,
        'token' => ***', // Token of your bot
        'chat' => ***, // Notifications chat id
        'extraTitle' => "⚠️⚠️⚠️ Some extra title added to message⚠️⚠️⚠️\n", // optional
        'proxy' => 'socks5://LOGIN:PASS@PROXY_ADDRESS:PROXY_PORT', // optional, if needed to use proxy, like in Russia
    ],
],

HOW

How to find out my user`s Id ot chat id?

  • send message to the bot
  • Look at last updates at https://api.telegram.org/bot{BOT_TOKEN}/getUpdates
  • {BOT_TOKEN} - replace with your bot token