[WIP] Events Arranger & Tracker Bot for Telegram
Add me to your Telegram: https://t.me/eant_bot
Clone this repository and run
composer install
Setup the following environment variables:
TELEGRAM_APIKEY
DATABASE_URL
, e.g. mysql://<login>:<password>@<host>/<database>
Read and edit config/app.php
and setup the 'Datasources'
and any other
configuration relevant for your application.
Register the bot in Telegram:
$ TELEGRAM_APIKEY=<api-key> ./bin/cake setup webhook_register <domain> <ssl-certificate> <max-requests>
Unregister the bot:
$ TELEGRAM_APIKEY=<api-key> ./bin/cake setup webhook_unregister
Send a message to all chats:
$ TELEGRAM_APIKEY=<api-key> DATABASE_URL=<database-url> ./bin/cake multicast_message "<message>"
Clean a database (when switching between different bots accounts):
$ TELEGRAM_APIKEY=<api-key> DATABASE_URL=<database-url> ./bin/cake setup clean_db