Football chat bot build with NestJS framework
- Clone repository to your local filesystem from github:
git clone https://github.com/tormozz48/football-chat-bot-2.git
- Install npm dependencies:
npm install
-
Set up all environment variables. Also you can create
.env
file and fill them with environment variables described in "Configuration" section. -
Launch application server:
npm start
Configuration is performed by modifying these environment variables:
TELEGRAM_BOT_TOKEN
- unique telegram bot token stringTELEGRAM_USE_PROXY
- true/false. If set to true then application will establish connection with telegram server via proxy.TELEGRAM_PROXY_HOST
- proxy server hostTELEGRAM_PROXY_PORT
- proxy server portTELEGRAM_PROXY_LOGIN
- proxy auth loginTELEGRAM_PROXY_PASSWORD
- proxy auth passwordVK_TOKEN
- unique vk bot token stringDATABASE_URL
- connection url fot database. Used for production environment.
Configured commands:
npm run build
- compile TypeScript source code into js distributive.npm run format
- perform code formatting via prettier tool.npm start
- run application servernpm start:dev
- run application in "watch mode". Restart after source code chages.npm start:debug
- run application in both "watch" and "debug" modes.npm start:prod
- run application in production mode.npm run lint
- perform code linting via tslint tool.npm test
- run tests.npm test:watch
- run tests in "watch mode".npm test:cov
- run tests and calculate code coverage.
- NestJS - is a framework for building efficient, scalable Node.js server-side applications.
- TypeORM - TypeORM is an ORM that can run in NodeJS, Browser, Cordova, PhoneGap, Ionic, React Native, NativeScript, Expo, and Electron platforms and can be used with TypeScript and JavaScript (ES5, ES6, ES7, ES8).
- Telegraf - modern Telegram Bot Framework for Node.js.
- Handlebars - Minimal templating on steroids.