Setting up Telegram Bot / DONE
Setting up Telegram Bot
In your account you need to write to the contact @BotFather
Click the Start button if the bot has not been launched yet.
Write the command
/newbot
and follow the instructions in the bot to get the token
Install the received token
Connect to your server via SSH or FTP
Initiate a project
You need to configure token and username in the file
/var/www/exchanger-bot/config/app_config.json
username is the name of the bot in the Telegram system, please specify the bot name without @
4. Set up the domain in the configuration /var/www/exchanger-bot/config/app_config.json
Domain: www.exchanger.domain
s provided as an example, please replace it with the domain of your site! If you have the exchanger installed on thewww
please specify the domain with www
baseUrl: is formed according to the principle https://your_domain**/tg**
Example of how to fill out the config:
5. MongoDB Access:
Requires MongoDB on the server. If you install the bot on the same server where you have exchanger-api installed, take mongo:uri from the file exchanger-api/config/app_config.json
Specify in the configuration file/var/www/exchanger-bot/config/app_config.json
MongoDB database accesses
6. Apply configuration changes (restart the service)
The PM2 Process Manager is required. You can install it with the command
npm install pm2 -g
Last updated