This project is a Node.js Telegraf (Telegram) bot to access the menu of the university canteen managed by Opera Universitaria.
This is the code powering @unimeal-bot.
Once you cloned the repository:
you need to enter into project dir: cd unimeal-bot
and type npm install
to install all dependencies.
Create a config.js
file in the root of this project with the following info:
module.exports = {
// API key for Telegram
telegraf_token:'YOUR_TELEGRAM_API_KEY',
db_connection:'your_mongodb_connection_string'
firebaseConfig : {
apiKey: 'YOUR_FIREBASE_API_KEY',
authDomain: 'unimeal-8e378.firebaseapp.com',
databaseURL: 'https://unimeal-8e378.firebaseio.com',
projectId: 'unimeal-8e378',
storageBucket: 'unimeal-8e378.appspot.com',
messagingSenderId: '648699973887'
}
};
The bot should work even without the db_connection and the firebase config
Once you've set up your API key, just type:
npm start
...done!
For easier deployment you can also use the docker image
docker pull albertoxamin/unimeal-bot
docker run -it -v /path_in_host/config.js:/usr/src/app/config.js --name unimeal albertoxamin/unimeal-bot