This repository is not being maintained anymore. The bot will probably not work as the mLab add-on Heroku has been shut down and I haven't gotten a chance to migrate.
Simple telegram bot for creating and sharing Hastebin snippets. Give it a spin
-
Install dependencies
$ npm install
-
Create a file named .env in the project root with content:
TELEGRAM_TOKEN=<your-unique-token> BOT_URL=https://b2c4a7b6.ngrok.io # replace this with your own URL MONGODB_URI=mongodb://localhost:27017/hastebot # replace this with your local mongodb URI
-
Use ngrok for testing on local server and set its url as BOT_URL
-
You can also specify a port. Default is 5000
PORT=3000
-
$ npm start
-
Deployed on Heroku
-
Set environment variables on Heroku
Variable Value TELEGRAM_TOKEN <Your unique telegram token> BOT_URL <server root> (e.g. https://hastebot.herokuapp.com)