Awesome
<h1 align="center">🤖 Scan Tool Bot</h1> <img align="right" width="35%" src="https://github.com/bot-base/scan-tool-bot/assets/26162440/92e1e035-a3d7-4f0f-b5f8-0c40f96a60ec"> <p align="center"> <a href="https://t.me/ScanToolBot">Open in Telegram</a> <br/> or <br/> just type <code>@ScanToolBot</code> in message input field </p>Features
- Scan QR codes with a camera
- Generate QR codes
- Works in any chat via inline mode
Launch
- Close repository:
git clone git@github.com:bot-base/scan-tool-bot.git
- Create an environment variables file:
cp .env.example .env
-
Launch web app following the instructions in webapp/README.md.
-
Set BOT_TOKEN, WEBAPP_URL, API_URL environment variables in
.env
file. -
Launch bot
Development mode:
# 1. Install dependencies npm i # 2. Set BOT_SERVER_HOST to localhost # Set BOT_SERVER_PORT to any available port # 2. Run bot (in watch mode) npm run dev
Production mode:
# 1. Install dependencies npm i --only=prod # 2. Set NODE_ENV to production # Change BOT_WEBHOOK to the actual URL to receive updates # 3. Run bot npm start # or npm run start:force # if you want to skip type checking
List of available commands
npm run lint
— Lint source code.npm run format
— Format source code.npm run typecheck
— Runs type checking.npm run dev
— Starts the bot in development mode.npm run start
— Starts the bot.npm run start:force
— Starts the bot without type checking.